Skip to contentSkip to conversation

enable_irq/disable_irq

DISCUSSION Christoph Hellwig 1 participant 1 message Oct 26, 2004 5 messages not in the archive Generic include/asm header files

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

#5 lore raw
Quoted 21 lines · Andrew Morton
Quoted 8 lines · Christoph Hellwig
Quoted 3 lines · Andrew Morton

As all platforms must provide enable_irq() and disable_irq() we should put the declarations in a generic header. Why not put them in linux/interrupt.h?

I looked into that a few days ago, but unfortunately a few architectures have inlined variants.

So where's the official declaration of enable_irq()? For some architectures, linux/interrupt.h. For others, asm/irq.h. That's screwed.

I suggest that we move this:

#ifdef CONFIG_GENERIC_HARDIRQS
extern void disable_irq_nosync(unsigned int irq);
extern void disable_irq(unsigned int irq);
extern void enable_irq(unsigned int irq);
#endif

Quoted 3 lines

out of interrupt.h and into each relevant asm/irq.h.

Maybe. It still sucks.

Well, ingo just moved it from <asm/irq.h> to <linux/interrupt.h> protected by CONFIG_GENERIC_HARDIRQS, but maybe we should move it back. Or say that performance doesn't matter so much for these and they should be out of line for all architectures.

What do the architecture maintainers think about this?