Created attachment 58292 [details] DSDT of Toshiba C670D-10C Toshiba C670D-10C restarts instead of powering off when on AC. It shuts down correctly when on battery. I tried booting with: acpi_osi="Linux" acpi=copy_dsdt (even though it should be the default on all Toshiba hardware now) acpi_os_name="Windows 2009" acpi_os_name="Windows 2001" Works under Windows 7, and in LILO/grub. No BIOS update available from vendor ATM. Attaching DSDT.
Created attachment 58302 [details] dmesg
I have the same problem with Fedora 15 (version 2.6.38 of the kernel). My computer is an Asus PRO50N. See this bug report: https://bugzilla.redhat.com/show_bug.cgi?id=710532
Ah, I didn't try on battery. On AC, sometimes it's OK, sometimes not (for the Asus PRO50N).
Same here. It's Fedora 15 on a desktop machine with Asus mainboard, so it does not seem to be just notebook related. With Fedora 14, the system always shut down reliably.
Did a few more tests: I tested with 2.6.33 and 2.6.35, and it's not working either, so this does not seem to be a (recent) regression. Tried disabling enabled GPE interrupts before shutting down, in /sys/firmware/acpi/interrupts/, it didn't have any effect. Finally, I tried disabling wakeup sources in /proc/acpi/wakeup, and I found the culprit: the "LID" wakeup source. So running: echo " LID" > /proc/acpi/wakeup before shutting down, will have the laptop halt without rebooting whether it's plugged or not. I checked in the BIOS, and there's an option "Panel Open - Power On", and it wasn't enabled. I tried enabling/disabling it, and the problem is reproduced whether it's on or off. Also, the problem is reproduced whether the lid is open or closed. And the problem is fixed with echo " LID" > /proc/acpi/wakeup whether the lid is open or closed. I don't know yet how to solve this at the kernel level.
The echo " LID" fixes this issue even on my desktop machine. :)
Richard, Sébastien : what BIOS does your computer have ? The Toshiba laptop has an AMI (American Megatrends Inc) Aptio bios.
Created attachment 67032 [details] Patch to disable ACPI LID wakeup at shutdown Attached patch should do the same as the echo " LID" thing, but in kernel.
Anisse, my BIOS is an AMI v02.59 (for the Asus PRO50N). But now I've installed Gentoo, and I don't have the problem anymore. So it was maybe the fault of systemd in Fedora 15 or another module, since I used the same kernel version (2.6.38).
It's a Phoenix AwardBIOS here.
It's great that the kernel bugzilla is back. Can you please verify if the problem still exists in the latest upstream kernel?
For me, the bug also exist in the latest kernel (3.4-rc3). Applying the patch posted above fixes it for me (Asus EEE PC r252b). If you want: Tested-by: Adrian Batzill <linux@batzill.com>
Thanks Adrian for the Tested-by, but I don't think this patch will be accepted as-is, it's just a hack. That's why I didn't sign it off. I stopped working on this hardware, but if anyone wants to implement a proper fix for this they should probably look at the acpi "button" driver.
Hey, Thanks for responding anyway. I'd love to work on a proper patch, but I'm pretty new to kernel development (especially on ACPI). Could you give a few hints on where/how I could start on this, if you have time? That would be really awesome. (If not, I'll just try a few days until I have figured it out myself :/) Thanks
This bug also impacts the Toshiba Satellite C870-16F. I think we can label that as a generic Linux bug, something that is done differently from windows and impacts different hardware and BIOS.
anisse, you patch disables the Lid Wake GPE when shutdown, right? IMO, a proper fix would be disabling unused GPEs before shutdown, and we should do it in ACPI general code instead. what do you think?
Zhang Rui, Yes, that would be the best course of action. I didn't look much at the details, but how would you know if a GPE is unused ? Plus, I thought this was already done, see drivers/acpi/sleep.c acpi_power_off_prepare calls acpi_disable_all_gpes(), so I might be missing something here, but maybe it's related to the order in which the actions are done ?
then the difference would be: Method (_PSW, 1, NotSerialized) // _PSW: Power State Wake { Store (Arg0, LDST) } you patch disables _PSW, while acpi_disable_all_gpes does not. this also make sens. I'll cook up a patch to disable _PRW before shutdown.
Created attachment 87911 [details] patch: do not use Lid and sleep button for S5 wakeup please try this patch to see if it helps.
Created attachment 88431 [details] patch: do not use Lid and sleep button for S5 wakeup please try this patch instead.
Patch has been sent out and queued for 3.8
A patch referencing this bug report has been merged in Linux v3.8-rc1: commit b7e383046c2c7c13ad928cd7407eafff758ddd4b Author: Zhang Rui <rui.zhang@intel.com> Date: Tue Dec 4 23:23:16 2012 +0100 ACPI : do not use Lid and Sleep button for S5 wakeup