[Bug 827854] New: System freezes when running on battery with SATA ALPM enabled
https://bugzilla.novell.com/show_bug.cgi?id=827854 https://bugzilla.novell.com/show_bug.cgi?id=827854#c0 Summary: System freezes when running on battery with SATA ALPM enabled Classification: openSUSE Product: openSUSE 12.3 Version: Final Platform: x86-64 OS/Version: openSUSE 12.3 Status: NEW Severity: Critical Priority: P5 - None Component: Basesystem AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: tobiaspotocek@gmail.com QAContact: qa-bugs@suse.de Found By: --- Blocker: --- Created an attachment (id=546545) --> (http://bugzilla.novell.com/attachment.cgi?id=546545) Output of dmesg after freeze passes User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:21.0) Gecko/20100101 Firefox/21.0 When AC is unplugged, several power saving tweaks are applied. Among others there is the script /usr/lib/pm-utils/power.d/alpm which will activate SATA link power management. This will lead to frequent system freezes. Reproducible: Always Steps to Reproduce: 1. Buy Asus Zenbook UX32VD (or similar, hardware details are provided later) 2. Install OpenSuse 12.3 3. Unplug the power source 4. Wait ;-) Actual Results: The system freezes randomly, approximately every 5 minutes. However it seems that it can be triggered by heavy disk load. One freeze lasts approximately from 30 to 60 seconds. During the freeze the system is in some cases completely unresponsive (even the cursor is frozen), in other you can use "what is on the screen", but is is impossible to run anything new (even ls in the command line). The diod indicating disc activity is constantly on during the freeze. After the freezes passes, everything returns to normal. There are no freezes what so ever when running on AC. There are a lot of errors in /var/log/messages after the freezes. Few examples (see attachments for whole log): 3-07-02T19:11:54.480614+02:00 zenbook kernel: [34448.565112] ata1.00: exception Emask 0x40 SAct 0xf SErr 0x50800 action 0x6 frozen 2013-07-02T19:11:54.480629+02:00 zenbook kernel: [34448.565118] ata1: SError: { HostInt PHYRdyChg CommWake } 2013-07-02T19:11:54.480631+02:00 zenbook kernel: [34448.565121] ata1.00: failed command: READ FPDMA QUEUED 2013-07-02T19:11:54.480632+02:00 zenbook kernel: [34448.565146] ata1.00: cmd 60/08:00:98:28:5a/00:00:07:00:00/40 tag 0 ncq 4096 in 2013-07-02T19:11:54.480633+02:00 zenbook kernel: [34448.565146] res 40/00:00:00:4f:c2/00:00:00:00:00/00 Emask 0x44 (timeout) 2013-07-02T19:11:54.480634+02:00 zenbook kernel: [34448.565156] ata1.00: status: { DRDY } 2013-07-02T19:11:54.480635+02:00 zenbook kernel: [34448.565162] ata1.00: failed command: READ FPDMA QUEUED 2013-07-02T19:11:54.480636+02:00 zenbook kernel: [34448.565173] ata1.00: cmd 60/d8:08:a8:28:5a/00:00:07:00:00/40 tag 1 ncq 110592 in 2013-07-02T19:11:54.480637+02:00 zenbook kernel: [34448.565173] res 40/00:00:00:00:00/00:00:00:00:00/00 Emask 0x44 (timeout) 2013-07-02T19:11:54.785597+02:00 zenbook kernel: [34448.870195] ata1.00: ACPI cmd f5/00:00:00:00:00:a0 (SECURITY FREEZE LOCK) filtered out 2013-07-02T19:11:54.785599+02:00 zenbook kernel: [34448.870247] ata1.00: ACPI cmd ef/10:06:00:00:00:a0 (SET FEATURES) succeeded 2013-07-02T19:11:54.785601+02:00 zenbook kernel: [34448.870253] ata1.00: ACPI cmd ef/10:03:00:00:00:a0 (SET FEATURES) filtered out 2013-07-02T19:11:54.789572+02:00 zenbook kernel: [34448.873982] ata1.00: ACPI cmd f5/00:00:00:00:00:a0 (SECURITY FREEZE LOCK) filtered out 2013-07-02T19:11:54.789595+02:00 zenbook kernel: [34448.874114] ata1.00: ACPI cmd ef/10:06:00:00:00:a0 (SET FEATURES) succeeded 2013-07-02T19:11:54.789597+02:00 zenbook kernel: [34448.874125] ata1.00: ACPI cmd ef/10:03:00:00:00:a0 (SET FEATURES) filtered out 2013-07-02T19:11:54.790576+02:00 zenbook kernel: [34448.874817] ata1.00: device reported invalid CHS sector 0 Expected Results: This shouldn't be happening. This problem seems to be similar to this one: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/610055 Luckily, it's quite simple to fix it. Simply disable /usr/lib/pm-utils/power.d/sata_alpm. You can do it by creating a new conf file in /etc/pm/config.d/ and putting "SATA_ALPM_ENABLE=false" in it. This will immediately prevent freezes from happening (simply plug/unplug AC to active new settings). I have several times tried to disable and enable this tweak and I can confirm that it really works. You can check your /var/log/pm-powersave.log to see if the tweak is applied. There _should not_ be any messages like "Setting SATA APLM on host0 to min_performance...Done." Hardware info: My laptop is Asus Zenbook UX32VD. See https://www.asus.com/Notebooks_Ultrabooks/ASUS_ZENBOOK_UX32VD/#specification... for full specs. It's the i7 version, with two SSDs in RAID 0. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c1
--- Comment #1 from Tobiáš Potoček
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c2
--- Comment #2 from Tobiáš Potoček
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c
Tobiáš Potoček
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c
Ye Yuan
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c3
Wojtek Dziewięcki
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c4
--- Comment #4 from Tobiáš Potoček
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c5
--- Comment #5 from Bernhard Wiedemann
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c6
--- Comment #6 from Wojtek Dziewięcki
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c7
--- Comment #7 from Wojtek Dziewięcki
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c8
--- Comment #8 from Benjamin Brunner
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c9
--- Comment #9 from Wojtek Dziewięcki
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c10
--- Comment #10 from Swamp Workflow Management
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c11
Jan Ritzerfeld
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c12
--- Comment #12 from Tobiáš Potoček
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c13
Wojtek Dziewięcki
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c14
--- Comment #14 from Jan Ritzerfeld
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c15
Cristian Rodríguez
Cristian: can you think of a way to save some power on alpm and wireless, without using pm-utils?
No, because what we are seeing here is clearly a kernel bug. if enabling SATA ALPM results in machine hang, then IMHO the kernel must refuse to enable it on this particular machine/controller/whatever. With regards to wireless, enabling or disabling power saving on an particular wireless interface should be done in networkmanager and kick in only when ON_BATTERY. doing it in pm-utils looks absolutely wrong. (imagine drop and down menu, "enable power saving: with options "always", "on battery", "on low battery"...) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c16
--- Comment #16 from Cristian Rodríguez
(In reply to comment #13)
Cristian: can you think of a way to save some power on alpm and wireless, without using pm-utils?
No, because what we are seeing here is clearly a kernel bug.
OR a bug in the SSD firmware, not sure if the kernel has hooks to disable SATA ALPM on particular drives/firmware versions. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c17
--- Comment #17 from Tobiáš Potoček
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c18
--- Comment #18 from Jan Ritzerfeld
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c19
--- Comment #19 from Wojtek Dziewięcki
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c20
--- Comment #20 from Jan Ritzerfeld
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c21
--- Comment #21 from Cristian Rodríguez
@Jan The exact model is SanDisk SD5SF2256G1002E. I have two of those in RAID 0 in my laptop. I don't know if that's relevant. The firmware might be out-of-date but at this point the battery life is not an issue for me. Stability and reliability are more important. So I'm not going to change something that works fine :)
I *strongly* suggest you to upgrade the disk firmware if possible, SSDs have very unnerving bugs, once I spent a full week "debugging" a misterious hang like this. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c22
Wojtek Dziewięcki
https://bugzilla.novell.com/show_bug.cgi?id=827854
https://bugzilla.novell.com/show_bug.cgi?id=827854#c23
--- Comment #23 from Cristian Rodríguez
Where should we implement activating sata alpm power management? My guess is laptop-mode-tools.
Nope, Probably in upower or whatever backend that controls the "power management" applets on the relevant DE. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com