pmac_halt() bug

7 messages, 4 authors, 2003-11-11 · open the first message on its own page

pmac_halt() bug

From: Tim Seufert <hidden>
Date: 2002-11-20 21:03:12

In platforms/pmac_setup.c, pmac_halt() is defined as follows:

pmac_halt(void)
{
     pmac_power_off();
}

Arguably, this is a bug because there should be a distinction between
halt and poweroff.  I've seen posts on user mailing lists from at least
two different people who want to halt without actually powering off,
but cannot do so because of this bug.  (I think the reasons have
something to do with attempting to get their machines to turn back on
automatically when power is restored after a UPS-initiated shutdown.)


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: pmac_halt() bug

From: Igal Baevsky <hidden>
Date: 2003-11-10 16:33:09

Tim Seufert wrote:
In platforms/pmac_setup.c, pmac_halt() is defined as follows:

pmac_halt(void)
{
    pmac_power_off();
}

Arguably, this is a bug because there should be a distinction between
halt and poweroff.  I've seen posts on user mailing lists from at least
two different people who want to halt without actually powering off,
but cannot do so because of this bug.  (I think the reasons have
something to do with attempting to get their machines to turn back on
automatically when power is restored after a UPS-initiated shutdown.)


Tim,
Is there any way to halt PMAC machine with no powering it off ?
I will realy appretiate your answer - the problem you mentioned above is
the exact problem I'm dealing with .
Thanks.
Igal


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: pmac_halt() bug

From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date: 2003-11-10 23:59:50

On Tue, 2003-11-11 at 03:33, Igal Baevsky wrote:
Tim,
Is there any way to halt PMAC machine with no powering it off ?
I will realy appretiate your answer - the problem you mentioned above is
the exact problem I'm dealing with .
Thanks.
Igal
I see no good reason why you want to do such a halt that just spins and
do nothing but suck power...

If the problem is to have the machine turn back on, I fail to see how
halting it this way would help. The only thing I can imagine is enabling
the server mode option. I added that feature to my very latest trees
for Core99 machines and later (AGP machines), and there used to be a
tool doing that for CUDA based machines.

Ben.


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: pmac_halt() bug

From: Tim Seufert <hidden>
Date: 2003-11-11 07:28:17

On Nov 10, 2003, at 8:33 AM, Igal Baevsky wrote:
Tim Seufert wrote:
quoted
In platforms/pmac_setup.c, pmac_halt() is defined as follows:

pmac_halt(void)
{
    pmac_power_off();
}
Tim,
Is there any way to halt PMAC machine with no powering it off ?
I will realy appretiate your answer - the problem you mentioned above
is
the exact problem I'm dealing with .
Assuming the above is still the implementation of pmac_halt(), there's
no way, short of modifying the kernel.


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: pmac_halt() bug

From: Tim Seufert <hidden>
Date: 2003-11-11 07:37:40

On Nov 10, 2003, at 3:59 PM, Benjamin Herrenschmidt wrote:
On Tue, 2003-11-11 at 03:33, Igal Baevsky wrote:
quoted
Tim,
Is there any way to halt PMAC machine with no powering it off ?
I will realy appretiate your answer - the problem you mentioned above
is
the exact problem I'm dealing with .
Thanks.
Igal
I see no good reason why you want to do such a halt that just spins and
do nothing but suck power...

If the problem is to have the machine turn back on, I fail to see how
halting it this way would help. The only thing I can imagine is
enabling
the server mode option.
That's precisely it.  Some (all?) pmacs with server mode don't
automatically turn on after an intentional shutdown, only after power
is lost.  So the idea is to have the UPS signal the computer to halt,
and then have the UPS cut power once it's safe.  Later the UPS switches
power back on and the computer will automatically boot.


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: pmac_halt() bug

From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date: 2003-11-11 08:25:25

That's precisely it.  Some (all?) pmacs with server mode don't
automatically turn on after an intentional shutdown, only after power
is lost.  So the idea is to have the UPS signal the computer to halt,
and then have the UPS cut power once it's safe.  Later the UPS switches
power back on and the computer will automatically boot.
Ok, 2 things:

- How does the UPS knows it's "safe" ?
- And right, I need to disable server mode to be able to shut down :) So
I indeed to that on those machines

Ben.


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: pmac_halt() bug

From: Ethan Benson <hidden>
Date: 2003-11-11 08:53:55

On Tue, Nov 11, 2003 at 07:25:25PM +1100, Benjamin Herrenschmidt wrote:
quoted
That's precisely it.  Some (all?) pmacs with server mode don't
automatically turn on after an intentional shutdown, only after power
is lost.  So the idea is to have the UPS signal the computer to halt,
and then have the UPS cut power once it's safe.  Later the UPS switches
power back on and the computer will automatically boot.
Ok, 2 things:

- How does the UPS knows it's "safe" ?
varies, the UPS i have has a smart monitoring program run over a
serial line, the UPS informs the daemon when it believes there is only
5 minutes of power remaining, and the daemon initiates a halt, the UPS
shuts down when there is only 2 minutes of power remaining, so your
shutdown process better not take longer then 3 minutes.
- And right, I need to disable server mode to be able to shut down :) So
I indeed to that on those machines
and there is the problem. on x86 many bioses provide an option which
lets you choose behavior post powerfail, on an x86 i have one option
is to bootup whenever AC power is lost and then restored, regardless
of previous shutdown state, for others the only way is to just halt
the machine without a powerdown.

pmac seems to have no way to accomplish either atm.

--
Ethan Benson
http://www.alaska.net/~erbenson/

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help