Skip to contentSkip to conversation

parisc: make NO_IRQ 0 as it should be

PATCH In review Alan Cox 2 participants 2 messages Dec 6, 2011 – Dec 7, 2011 PA-RISC architecture

lore
Share & tools
lore

Alan Cox

author
#0 lore raw

PATCH 1/1 parisc: make NO_IRQ 0 as it should be

From: Alan Cox <[email protected]>

PA-RISC doesn't use a real IRQ 0 and James says

"To be honest, we don't care very much. Parisc interrupts are cascading and mostly software assigned (except our EIEM which we keep internal). We use a base offset at 16 or 64 (depending on GSC presence or not) so IRQs 0-15 aren't legal on parisc either (we frob some of the hard coded ISA interrupts on the WAX eisa bus).

We use NO_IRQ as an IRQ assignment error return and that's about it (and that error shouldn't ever really occur)."

---

 arch/parisc/include/asm/irq.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
arch/parisc/include/asm/irq.h +1 -1
index 1073599..fcf6edd 100644
@@ -10,7 +10,7 @@
 #include <linux/cpumask.h>
 #include <asm/types.h>
 
-#define NO_IRQ		(-1)
+#define NO_IRQ		0
 
 #ifdef CONFIG_GSC
 #define GSC_IRQ_BASE	16
maintainer
#1 lore raw
Quoted 25 lines · Alan Cox

From: Alan Cox <[email protected]>

PA-RISC doesn't use a real IRQ 0 and James says

"To be honest, we don't care very much. Parisc interrupts are cascading and mostly software assigned (except our EIEM which we keep internal). We use a base offset at 16 or 64 (depending on GSC presence or not) so IRQs 0-15 aren't legal on parisc either (we frob some of the hard coded ISA interrupts on the WAX eisa bus).

We use NO_IRQ as an IRQ assignment error return and that's about it (and that error shouldn't ever really occur)."

---

 arch/parisc/include/asm/irq.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
arch/parisc/include/asm/irq.h +0 -0
index 1073599..fcf6edd 100644

arch/parisc/include/asm/irq.h line 13

Quoted 5 lines
arch/parisc/include/asm/irq.h +1 -1
@@ -10,7 +10,7 @@
 #include <linux/cpumask.h>
 #include <asm/types.h>
 
-#define NO_IRQ		(-1)
+#define NO_IRQ		0

Unfortunately, it's not quite as simple as this. There's one use of NO_IRQ as an error return in the EIEM code, which returns the internal line number (which run 0-32/64 ... I'll have to fix those before this can be done.

James