Re: [PATCH][2.4] acpi S5 poweroff fix

Derek Broughton
2003-04-30T12:09:19Z

From: "willy tarreau" <wtarreau-Qt13gs6zZMY@public.gmane.org>

> Although I'm not sure that the second case affects everybody, because it might
> be caused by side-effects, but from what I've understood from the code, I'm
> pretty sure that nobody can power off by echoing 5 to /proc/acpi/sleep !

Mostly we wouldn't want to. iirc, there was some discussion here about not even
permitting "echo 5 >/proc/acpi/sleep". If I am forced to recover from the (too
frequent) situation where my laptop freezes and ignores the keyboard, I have to
hold down the power button for 4 or 5 seconds, as you mention. But that, like
S5, is an abrupt power-off. Generally, I'd want to go through init and do it
gracefully. Pushing the power button once is enough to generate a power button
event in acpi, and then acpid shuts the machine down using '/sbin/init 0'