Subject: Re: The right place for doshutdownhooks()
To: Greg Hudson <ghudson@MIT.EDU>
From: Matt Thomas <matt@lkg.dec.com>
List: tech-kern
Date: 11/20/1995 15:00:55
In  <199511200549.AAA12394@glacier.MIT.EDU> , you wrote:


> We obviously have a different conception of what shutdown hooks are to
> be used for.  In the i386 port, the (only) use we've had for shutdown
> hooks is to turn off interrupt handling on devices which cause the
> machine to fail to reboot properly if they're left on.

Shutdown hooks are absolutely required for PCI device drivers since
    1) the devices would keep running if not shutdown,
    2) the devices only reset on a hard reset (ie. reset button), 
    3) PCI contains no device-independent way to reset devices
    4) PCI BIOS'es don't disable the master enable bit

This can cause the system to fail to reboot if PCI activity
(like received ethernet packets) overwritew some critical part of
the system).  Hence, if you have a PCI device driver then that
driver *must* shutdown the device before the system reboots.

Matt Thomas               Internet:   matt@lkg.dec.com
3am Software Foundry      WWW URL:    <currently homeless>
Westford, MA              Disclaimer: Digital disavows all knowledge
                                      of this message