Bug 49701

Summary: Slow Resume with SSD
Product: ACPI Reporter: Carlos (carlos.moffat)
Component: BIOSAssignee: acpi_bios
Status: CLOSED DOCUMENTED    
Severity: normal CC: aaron.lu, alan, jgarzik, lenb, rui.zhang
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 3.6.2 Subsystem:
Regression: No Bisected commit-id:

Description Carlos 2012-10-28 20:34:06 UTC
Hi,

(please let me know if this is the wrong list to ask this)

I have a Crucial M4 512 GB SSD installed on my Thinkpad X220 (Ubuntu 
Precise). Overall this runs very nicely, but it takes 10+ seconds to 
resume from suspend, apparently because some issue with the hardrive. 
The only message I see while resuming is "COMRESET failed (errno=-16)".

[52483.228615] ata1: link is slow to respond, please be patient (ready=0)
[52487.870616] ata1: COMRESET failed (errno=-16)
[52488.190222] ata1: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
[52488.190752] ata1.00: ACPI cmd ef/02:00:00:00:00:a0 (SET FEATURES) 
succeeded
[52488.190754] ata1.00: ACPI cmd f5/00:00:00:00:00:a0 (SECURITY FREEZE 
LOCK) filtered out
[52488.190755] ata1.00: ACPI cmd ef/10:03:00:00:00:a0 (SET FEATURES) 
filtered out
[52488.191849] ata1.00: ACPI cmd ef/02:00:00:00:00:a0 (SET FEATURES) 
succeeded
[52488.191855] ata1.00: ACPI cmd f5/00:00:00:00:00:a0 (SECURITY FREEZE 
LOCK) filtered out
[52488.191860] ata1.00: ACPI cmd ef/10:03:00:00:00:a0 (SET FEATURES) 
filtered out
[52488.192406] ata1.00: configured for UDMA/100
[52488.206298] sd 0:0:0:0: [sda] Starting disk
[52488.207334] Extended CMOS year: 2000
[52488.208335] PM: resume of devices complete after 10376.896 msecs
[52488.208552] PM: resume devices took 10.376 seconds

The only relevant post I've found was in the crucial support site:

http://forums.crucial.com/t5/Solid-State-Drives-SSD/SOLVED-M4-CT512M4SSD1-7mm-512Gb-SSD-too-slow-when-laptop-wakes/td-p/102666

which suggested adding libata.force=nohrst as a boot option to get rid 
of the problem.

I tried that, but the laptop wouldn't suspend.

I have been using most recent kernels from:

http://kernel.ubuntu.com/~kernel-ppa/mainline/

Currently 3.6.2, but the problem persists.

Best regards.
Comment 1 Aaron Lu 2012-11-15 08:30:58 UTC
Hello Carlos,

Can you please attach the dmesg when your laptop failed to suspend after you added the libata.force=nohrst kernel parameter?
Thanks.
Comment 2 Carlos 2012-11-17 19:20:55 UTC
Hi Aaron,

Actually, putting that parameter back created all sorts of problems. My Unity session would crash, and got a bunch of ext4 errors in dmesg. I had to revert the change to get a usable machine again.

Carlos
Comment 3 Aaron Lu 2012-11-19 02:01:47 UTC
Hello Carlos,

Does 3.5 kernel work for you?
Comment 4 Carlos 2012-11-20 22:02:48 UTC
Hi Aaron,

I tried both (3.5 and 3.6). Somewhat different ways to crash, but a mess nonetheless. Maybe because I have dm-crypt volume?
Comment 5 Aaron Lu 2012-11-21 01:26:46 UTC
Hi Carlos,

Can you please post your lspci and full dmesg after a suspend/resume cycle?
Thanks.
Comment 6 Carlos 2012-11-28 02:15:32 UTC
Hi Aaron,

I looked a bit further into this. It turns out Crucial released a firmware upgrade for this drive which, when applied, solved the problem of the slow resume for me. 

For the record, the firmware is:

ata1.00: ATA-9: M4-CT512M4SSD1, 010G, max UDMA/100

(version 010G), and can be found here:

http://www.crucial.com/support/firmware.aspx

The easiest way to upgrade is to download the mac version, get the .iso from the zip file and 'burn it' to a USB stick using your favorite tool.

Thanks for your efforts on this, this bug can now be closed.
Comment 7 Aaron Lu 2012-11-28 02:27:14 UTC
Hello Carlos,

Glad to know this, and it doesn't seem I've done anything :-)
Comment 8 Carlos 2012-11-28 02:28:01 UTC
Aaron,

Effort counts! Thanks again.