Bug 12633

Summary: IDE Hard disk spins down twice during suspend to ram
Product: Power Management Reporter: Heiner (mephisto)
Component: Hibernation/SuspendAssignee: Tejun Heo (tj)
Status: REJECTED INSUFFICIENT_DATA    
Severity: normal CC: rjw, rui.zhang, tj, yakui.zhao
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 2.6.26-1-686 Subsystem:
Regression: No Bisected commit-id:
Bug Depends on:    
Bug Blocks: 7216    
Attachments: output of dmesg after boot
additional dmesg output after suspend-resume cycle
lspci -nn output

Description Heiner 2009-02-04 11:21:08 UTC
Latest working kernel version:
Earliest failing kernel version:
Distribution: Debian testing
Hardware Environment: Asus A6Jc Laptop
Software Environment:
Problem Description:
When the system is put to suspend to ram mode, the message "suspending consoles" appears, then, the hard drive spins down. Instead of switching the pc to suspend however, the disk spins up, immediately afterwards spins down again and then the system enters suspend mode.
Everything else works as expected.
smartctl -A /dev/hda | grep Start_Stop_Count
confirms this behaviour by showing an increase of the raw value by two after one suspend-resume cycle.
I am running kernel 2.6.26-1-686 from debian testing archives currently, I experienced the same behaviour with 2.6.28-1-686 from debian kernel trunk archives.

Steps to reproduce:
Put system to suspend to ram with either s2ram or "echo mem > /sys/power/state". Watch raw value of smartctls Start_Stop_Count to verify that two start-stop-cycles occur (can also be noted acoustically on my system).
Comment 1 Tejun Heo 2009-02-04 18:46:30 UTC
Can you please try libata drivers?
Comment 2 Tejun Heo 2009-02-04 18:47:00 UTC
Also, please post the kernel boot log and the output of dmesg after suspend/resume.
Comment 3 Heiner 2009-02-09 09:13:21 UTC
Created attachment 20169 [details]
output of dmesg after boot
Comment 4 Heiner 2009-02-09 09:14:01 UTC
Created attachment 20170 [details]
additional dmesg output after suspend-resume cycle
Comment 5 Heiner 2009-02-09 09:17:46 UTC
Hello,

the attachments above contain the kernels boot messages and the dmesg output after one suspend-resume-cycle.
Unfortunately I did not manage to successfully boot the machine using libata. I tried to recompile the kernel without IDE support but with libata for intel piix enabled, resulting in a kernel panic during boot stating that no device containing the root was found (or similar). This also appears after adjusting the root=XXX option on the kernel command line.
Do you have a howto for enabling libata on a Debian lenny system?

Regards
Heiner
Comment 6 Tejun Heo 2009-02-09 20:55:01 UTC
Please post the output "lspci -nn" too.  To use libata without initrd, you need to build in libata, ata_piix, SCSI and SCSI disk support.
Comment 7 Heiner 2009-02-10 10:03:23 UTC
Created attachment 20181 [details]
lspci -nn output
Comment 8 Heiner 2009-02-10 10:06:13 UTC
I did enable libata, ata_piix, SCSI support and SCSI cdrom as well as disk support. However, the kernel did not boot successfully. I compiled the kernel from clean sources several times and checked the above options carefully, unfortunately without success.

Regards
Heiner
Comment 9 Tejun Heo 2009-02-10 17:08:20 UTC
Any chance you can grab the failing boot log?  Serial console or netconsole should do.
Comment 10 Heiner 2009-06-02 07:17:18 UTC
Unfortunetly I never used serial- or netconsole before and did not find out how to set it up. Is there any quick howto available?
Comment 11 Tejun Heo 2009-06-03 02:59:20 UTC
Yeap, in the kernel source tree,

  Documentation/serial-console.txt
  Documentation/networking/netconsole.txt
Comment 12 ykzhao 2009-07-14 02:38:36 UTC
Hi, Heiner
    Will you please try to use ata driver on the latest upstream kernel and see whether the issue still exists?
    Will you please also attach the output of acpidump, lspci -vxxx?
    Thanks.
Comment 13 Zhang Rui 2009-10-15 08:22:38 UTC
Heiner, please verify if this is a duplicate of bug #8855.
i.e. please try a kernel later than 2.6.29-rc3 and see if the problem still exist.
Comment 14 Zhang Rui 2009-12-28 08:20:06 UTC
please re-open it if the problem still exists in 2.6.32