Re: APM & Linux 2.2.1

Stephen.Rothwell@canb.auug.org.au
Sun, 21 Feb 1999 00:42:27 +1100


Hi all,

Bernd Broermann <info@broermann.com> writes:
> kuko@calvo.teleco.ulpgc.es wrote:
> >
> > Since I upgraded my Asustek Laptop to Linux 2.2.1 (from 2.0.36), poweroff
> > on shutdown doesn't work (Yes, I use the -p option). Suspend/Resume
> > still works...
>
> In /usr/src/linux/arch/i386/kernel/process.c, copy the routine in
> void machine_power_off(void) into void machine_halt(void). That
> fixed the power off at shutdown.

Do NOT do this. The fact that this works should tell you something ..
that Linux is being told to "halt" not "power off"!

To fix this, you need to edit your shutdown script (/etc/init.d/halt
on Debian, /etc/rc.d/init.d/halt (?) on RedHat, similar on others)
and make sure that the "halt" in there has the "-p" switch.

Calling "halt" with -p from any run level except 0 (and 6?) will
just run shutdown (and the -p switch is not propogated).

By the way Debian (what I use) already has the -p switch in its
halt script - so I have not problem.

Cheers,
Stephen

--
Stephen Rothwell                    Stephen.Rothwell@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/