grub-devel.gnu.org archive mirror
 help / color / mirror / Atom feed
From: Andrei Borzenkov <arvidjaar@gmail.com>
To: grub-devel@gnu.org
Subject: Re: `halt` doesn’t work on Lenovo T60 with coreboot and GRUB payload
Date: Sat, 15 Apr 2017 19:52:50 +0300	[thread overview]
Message-ID: <4ffa9a9b-0234-9ac2-a8ec-d5dfd72855ac@gmail.com> (raw)
In-Reply-To: <1492273973.2222.113.camel@users.sourceforge.net>


[-- Attachment #1.1: Type: text/plain, Size: 2352 bytes --]

15.04.2017 19:32, Paul Menzel пишет:
> Dear GRUB folks,
> 
> 
> On a Lenovo T60 with coreboot and the GRUB payload, version 2.02-rc1,
> entering `halt` in the GRUB command line, nothing happens. The cursor
> goes one line below, and everything stays that way. After that, the
> system can only be powered off by pressing the power button for ten
> seconds.
> 
> Setting `debug=all` before that – `debug=halt` didn’t work – the last
> lines are below.
> 
> ```
> […]
> commands/acpihalt.c:107: data type = 0x12
> commands/acpihalt.c:241: Opcode 0x8
> commands/acpihalt.c:242: Tell 2dbd
> commands/acpihalt.c:107: data type = 0x12
> commands/acpihalt.c:241: Opcode 0x8
> commands/acpihalt.c:242: Tell 2dcd
> commands/acpihalt.c:269: S5 found
> commands/acpihalt.c:444: SLP_TYP = 7, port = 0x504
> ```
> 

So grub found how to power off system from ACPI table. Next it attempts
to do it. If it fails, you should see at least error message "ACPI
shutdown failed". If you do not see it, it looks like it is stuck
somewhere in firmware. It is quite possible that firmware expects us to
do something else before actually entering S5 state. In particular,
there are several ACPI methods that are expected be executed by OS
before actually performing state transition.

Could you make available ACPI tables (/sys/firmware/acpi/tables/* on
modern Linux kernel)?

> I would have expected at least the monitor to go dark, and maybe also
> the system to power off as there is no specific command `poweroff`
> [1]. 
> 
>> The command halts the computer. If the --no-apm option is specified,
>> no APM BIOS call is performed. Otherwise, the computer is shut down
>> using APM.
> 
> I heard, that SysV implemented `halt` “incorrectly”, so that it also

It is irrelevant here. GRUB halt attempts to call ACPI to initiate S5
(power off) transition.

> powered off the system. Only `halt -p` or `poweroff` was supposed to
> that. so I don’t know, how GRUB’s implementation of `halt` is supposed
> to work.
> 
> 
> Kind regards,
> 
> Paul
> 
> 
> [1] https://www.gnu.org/software/grub/manual/html_node/halt.html#halt
> 
> 
> 
> _______________________________________________
> Grub-devel mailing list
> Grub-devel@gnu.org
> https://lists.gnu.org/mailman/listinfo/grub-devel
> 



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

  reply	other threads:[~2017-04-15 16:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-15 16:32 `halt` doesn’t work on Lenovo T60 with coreboot and GRUB payload Paul Menzel
2017-04-15 16:52 ` Andrei Borzenkov [this message]
2017-04-16 19:34   ` Paul Menzel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4ffa9a9b-0234-9ac2-a8ec-d5dfd72855ac@gmail.com \
    --to=arvidjaar@gmail.com \
    --cc=grub-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).