Subject: port-sparc64/11939: interrupts without handlers crash the kernel
To: None <firstname.lastname@example.org>
From: Martin Husemann <email@example.com>
Date: 01/11/2001 14:54:14
>Synopsis: interrupts without established handler cause kernel traps
>Arrival-Date: Thu Jan 11 14:54:00 PST 2001
>Originator: Martin Husemann
>Release: 1.5Q as of Jan 8, 2001
System: NetBSD night-porter.duskware.de 1.5Q NetBSD 1.5Q (PORTER) #0: Fri Jan 5 15:25:38 MET 2001 firstname.lastname@example.org:/usr/src/sys/arch/i386/compile/PORTER i386
When initializing some hardware that will cause interrupts before establishing
an interrupt handler for this cause kernel faults in setup_sparcintr/
interrupt_vector in locore.s.
In the typical autoconfig attach sequence:
(probe some info and print it)
(establish interrupt handler)
do something in the "init card" section, that will cause the card to interrupt.
At this point, the interrupt handler is not yet established.
Workaround is to move the interrupt establish call in the attach routine
in front of the card initialization. BUT: this does not keep random (bogus)
interrupts from happeneing and renders a lot of drivers working on all other
archs (where usually interrupts are globaly disabled at this stage) useless
Proper fix would be to install a dummy handler for every interrupt or globaly