How do external irq's get mapped?
Charles Krinke
ckrinke at istor.com
Thu May 3 08:11:27 EST 2007
> The new problem is that if I set the irq to 112, when it is
> insmodded, I
> get an error from open_pic.c of the form:
>
> Open_pic.c:720 invalid irq 112
>
> This seems to be coming from the macro at line 144 in open_pic.c
>
> #define check_arg_irq(irq) \
> if (irq < open_pic_irq_offset || irq >=
> NumSources+open_pic_irq_offset \
> || ISR[irq - open_pic_irq_offset] == 0) { \
> printk("open_pic.c:%d: invalid irq %d\n", __LINE__, irq); \
> dump_stack(); }
Any chance you can identify:
1) Where this macro is being called from when it fails
2) Which of the 3 conditions above are actually true
Andy
Dear Andy:
In our system, open_pic_irq_offset=80, numSources=60, *but* ISR[irq -
open_pic_irq_offset]=NULL when irq 112 is enabled.
It looks to me like each call to openpic_set_sources inits ISR[]
elements according to the first two arguments. We have two calls to
openpic_set_sources.
Internal irqs 00..31, 1st openpic_set_sources(0, 32) -- ISR[0..32]
External irqs 48..60, 2nd openpic_set_sources(48, 12) -- ISR[48..60]
But ISR[112] is never initialized in the source base.
I tried the cheap shot of adding a third openpic_set_sources(112, 12),
but I suspect the real answer is a bit more complicated then that.
Again, I thank you for your kind words while I struggle through this
external interrupt initalization for the PPC8541 in the Linux-2.6.17.11
kernel.
Charles Krinke
More information about the Linuxppc-embedded
mailing list