[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
shutdown hooks at panic (was Re: CVS commit: src/sys/kern)
[I'm copying this from source-changes because I believe the discussion
deserves a wider audience, and a better subject heading. :-)]
On Fri, Jan 18, 2008 at 04:09:24PM +0100, Joerg Sonnenberger wrote:
> On Thu, Jan 17, 2008 at 07:55:09PM -0600, David Young wrote:
> > NetBSD has run the pre-PMF shutdown hooks after panic for years. I have
> > not heard anyone complaining about them. Is there a particular bug you
> > fix by skipping them at panic?
> What shutdown hooks should be run at panic time? The good example I can
> think of that had shutdown hooks before were the disk drivers. But
> exactly those have proven to bee unstable with various controllers.
> Unstable in the sense that the drivers don't implement polling correctly
> and therefore hang.
Do the legacy shutdown hooks hang, or do the PMF suspend routines hang?
I thought that it was the latter. That is why I suggest the more
conservative change: skip PMF suspension if there was a panic, but let
the shutdown hooks run.
Will you give examples of the drivers that do not implement polling
correctly, so that people can fix them? You have also expressed the
desire that shutdown does not run at splhigh(); perhaps it will be easier
to fix the MD cpu_reboot() routines than to fix the drivers? Do the
drivers need to be fixed, regardless, so that kernel dumps will work?
NetBSD should not reboot the system until it is in a state where the
BIOS can bootstrap it without interference from bus masters, memory
write-protect units, or device interrupts. (What else?) The reason being
that, if the BIOS will test RAM, you do not want for write-protection
to stop it; if the BIOS uses some RAM to store its text/data, you do not
want for a bus master to clobber that RAM; and if the BIOS will activate
interrupts, you do not want for there to be an interrupt storm.
David Young OJC Technologies
dyoung%ojctech.com@localhost Urbana, IL * (217) 278-3933 ext 24
Main Index |
Thread Index |