On Tue, Apr 10, 2001 at 11:20:24PM +0000, Miquel van Smoorenburg wrote:
> In article <20010405000215.A599@bug.ucw.cz>,
> Pavel Machek <pavel@suse.cz> wrote:
> >Init should get to know that user pressed power button (so it can do
> >shutdown and poweroff). Plus, it is nice to let user know that we can
>
> Not so hasty ;)
>
> >+ printk ("acpi: Power button pressed!\n");
> >+ kill_proc (1, SIGTERM, 1);
[reasons deleted]
Is using a signal the appropriate thing to do anyway?
Wouldn't there be better solutions?
Perhaps a mechanism a user space program can use to communicate to the kernel
(ala arpd/kerneld message queues, or something like klogd). Then a more
general user space tool could be used that would do policy appropriate
stuff, ending with init 0.
mrc
-- Mike Castle Life is like a clock: You can work constantly dalgoda@ix.netcom.com and be right all the time, or not work at all www.netcom.com/~dalgoda/ and be right at least twice a day. -- mrc We are all of us living in the shadow of Manhattan. -- Watchmen - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Sun Apr 15 2001 - 21:00:14 EST