Cascaded interrupts on PPC405 (Virtex-II Pro)
Joshua Lamorie
jpl at xiphos.ca
Wed Mar 16 16:45:53 CET 2005
Gidday there,
Yes, I see this behaviour. When I first boot and load all the modules
and run my test it appears to work. But when I unload everything and
start it back up again, I get this problem. Unfortunately, your
suggestion to clear the IRQ_DISABLED flag in __rt_umount_rtai doesn't
improve things. My system doesn't have syslog running but I do see
/proc/interrupts displaying a BAD interrupt.
Shouldn't I be doing this in __rt_mount_rtai() ?
Joshua
Wolfgang Grandegger wrote:
>Normally it gets disabled, when the Linux interrupt displatcher detects
>an unregistered interrupt:
>
> $ cat <kernel-path>
> ..
> void ppc_irq_dispatch_handler(struct pt_regs *regs, int irq)
> {
> ...
> if (!action || !action->handler) {
>
> ppc_spurious_interrupts++;
> printk(KERN_DEBUG "Unhandled interrupt %x, disabled\n",
> irq);
> /* We can't call disable_irq here, it would deadlock */
> ++desc->depth;
> desc->status |= IRQ_DISABLED;
> ...
>
>If this is the case you should realize the above printk message as well.
>The question then is: why is it enabled. To fix this problem you may
>clear the status when RTAI takes over the interrupt handling e.g. in
>rtai.c or hal.c:
>
> void __rt_umount_rtai(void)
> {
> ...
> for (i = 0; i < NR_IRQS; i++) {
> IRQ_DESC[i].status &= ~IRQ_DISABLED;
> IRQ_DESC[i].handler = linux_irq_desc_handler[i];
> }
>
>Does it work?
>
>Wolfgang.
>
>
>
More information about the Rtai
mailing list