Subject: adding a shutdown hook
To: None <port-i386@netbsd.org>
From: Dan J Fraser <dfraser@mother.com>
List: port-i386
Date: 07/22/1999 15:54:56
I've got some custom code I need to run at shutdown in certain situations,
namely to raise DTR on my serial port to tell my UPS to shut off.

It seems that the best way to do this would be through shutdownhook
interface.  I've already got code working in machdep.c that does
what I want, but I don't want to be manually editing and patching my kernel
every time I upgrade.

It sounds like I want to add a new module to the kernel, and have it call
shutdownhook_establish() somewhere, but how, and where? :)

-- 
Dan J. Fraser <dfraser@mother.com> -- <URL:http://www.mother.com/~dfraser/>
Finger me for Geek Code/PGP public key.  IRC (irc.warped.net) nick: Optic
"'Apescent' is an anagram for 'Netscape'"