LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Laptop and Netbook (https://www.linuxquestions.org/questions/linux-laptop-and-netbook-25/)
-   -   Lenovo Thinkpad T61p - Takes a long time to resume from suspend (https://www.linuxquestions.org/questions/linux-laptop-and-netbook-25/lenovo-thinkpad-t61p-takes-a-long-time-to-resume-from-suspend-654916/)

kwesadilo 07-10-2008 01:49 PM

Lenovo Thinkpad T61p - Takes a long time to resume from suspend
 
I am running Ubuntu 8.04 Hardy Heron on a Thinkpad T61p model 6459CTO. I am able to suspend the system to RAM, and it takes a few seconds longer than I might like, but not much longer than I would expect. When I attempt to resume, the monitor lights up and blinks a cursor in the upper left-hand corner. This takes between 5 and 20 seconds (approximately). Then the screen will turn off and on again, and it will briefly flash several messages, the most eye-catching of which contains "COMRESET failed." (I do not get these messages every single time I resume, only most of the time.) After half a second, X will start, and I will get the GNOME password prompt to unlock the computer. This prompt appears in a rough and incomplete form for up to 5 seconds before fully rendering and letting me enter my password and start working again. The entire resume process is unpleasantly long, and I think that it is due to some software problem, because resume is much faster in Windows XP Professional SP2 on the same computer.

I have spent the last several days Googling and searching forums for the solution to this problem. The only useful thing I found was here. That post suggests that I change the power management policy for my hard drive to "max_performance." I was confused, however, because my /sys/class/scsi_host/ directory contains not only host0 but host1 through host4. Only host0, host1, and host2 contain "link_power_management_policy" files, and all of these files are already set to "max_performance." I was unable to find out more about the purpose or use of these files, and I did not want to risk the stability of my system by messing with important system files that I did not understand. So I have not actually done anything to my system in an effort to fix this problem.

Here is the relevant portion of my /var/log/syslog, which contains the messages that appear during resume:
Code:

Jul  9 11:29:58 deimos gnome-power-manager: (abe) Resuming computer
Jul  9 11:29:58 deimos kernel: [    0.856635] PCI: Setting latency timer of device 0000:00:1d.7 to 64
Jul  9 11:29:58 deimos kernel: [    0.856725] PM: Writing back config space on device 0000:00:1e.0 at offset 1 (was 100005, writing 100007)
Jul  9 11:29:58 deimos kernel: [    0.856753] PCI: Setting latency timer of device 0000:00:1e.0 to 64
Jul  9 11:29:58 deimos kernel: [    0.856853] PM: Writing back config space on device 0000:00:1f.1 at offset 1 (was 2800005, writing 2880005)
Jul  9 11:29:58 deimos kernel: [    0.856867] ACPI: PCI Interrupt 0000:00:1f.1[C] -> GSI 16 (level, low) -> IRQ 16
Jul  9 11:29:58 deimos kernel: [    0.856871] PCI: Setting latency timer of device 0000:00:1f.1 to 64
Jul  9 11:29:58 deimos kernel: [    0.856945] ata5: port disabled. ignoring.
Jul  9 11:29:58 deimos kernel: [    0.872514] PM: Writing back config space on device 0000:00:1f.2 at offset 1 (was 2b00007, writing 2b00407)
Jul  9 11:29:58 deimos kernel: [    0.872560] PCI: Setting latency timer of device 0000:00:1f.2 to 64
Jul  9 11:29:58 deimos kernel: [    1.175904] ata4.00: ACPI cmd ef/03:42:00:00:00:a0 filtered out
Jul  9 11:29:58 deimos kernel: [    1.175906] ata4.00: ACPI cmd ef/03:0c:00:00:00:a0 filtered out
Jul  9 11:29:58 deimos kernel: [    1.177055] ata4.00: ACPI cmd e3/00:1f:00:00:00:a0 succeeded
Jul  9 11:29:58 deimos kernel: [    1.178537] ata4.00: ACPI cmd e3/00:02:00:00:00:a0 succeeded
Jul  9 11:29:58 deimos kernel: [    1.511247] ata4.00: configured for UDMA/33
Jul  9 11:29:58 deimos kernel: [    1.875031] NVRM: RmPowerManagement: 5
Jul  9 11:29:58 deimos kernel: [    2.189896] ata2: SATA link down (SStatus 0 SControl 0)
Jul  9 11:29:58 deimos kernel: [    2.189953] ata3: SATA link down (SStatus 0 SControl 300)
Jul  9 11:29:58 deimos kernel: [    3.175511] PM: Writing back config space on device 0000:03:00.0 at offset 1 (was 100107, writing 100103)
Jul  9 11:29:58 deimos kernel: [    3.188849] PM: Writing back config space on device 0000:15:00.1 at offset 4 (was 0, writing f8101000)
Jul  9 11:29:58 deimos kernel: [    3.188856] PM: Writing back config space on device 0000:15:00.1 at offset 3 (was 800000, writing 804000)
Jul  9 11:29:58 deimos kernel: [    3.188865] PM: Writing back config space on device 0000:15:00.1 at offset 1 (was 2100000, writing 2100006)
Jul  9 11:29:58 deimos kernel: [    3.241831] ohci1394: fw-host0: OHCI-1394 1.1 (PCI): IRQ=[17]  MMIO=[f8101000-f81017ff]  Max Packet=[2048]  IR/IT contexts=[4/4]
Jul  9 11:29:58 deimos kernel: [    3.260727] PM: Writing back config space on device 0000:15:00.2 at offset 4 (was 0, writing f8101800)
Jul  9 11:29:58 deimos kernel: [    3.260731] PM: Writing back config space on device 0000:15:00.2 at offset 3 (was 800000, writing 804000)
Jul  9 11:29:58 deimos kernel: [    3.260740] PM: Writing back config space on device 0000:15:00.2 at offset 1 (was 2100000, writing 2100006)
Jul  9 11:29:58 deimos kernel: [    3.260764] ACPI: PCI Interrupt 0000:15:00.2[C] -> GSI 18 (level, low) -> IRQ 18
Jul  9 11:29:58 deimos kernel: [    3.835606] sd 0:0:0:0: [sda] Starting disk
Jul  9 11:29:58 deimos kernel: [    3.921764] ata1: port is slow to respond, please be patient (Status 0x80)
Jul  9 11:29:58 deimos kernel: [    4.015247] ata1: softreset failed (device not ready)
Jul  9 11:29:58 deimos kernel: [    4.122002] ata1: port is slow to respond, please be patient (Status 0x80)
Jul  9 11:29:58 deimos kernel: [    4.215128] ata1: COMRESET failed (errno=-16)
Jul  9 11:29:58 deimos kernel: [    4.231223] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 300)
Jul  9 11:29:58 deimos kernel: [    4.231669] ata1.00: ACPI cmd ef/02:00:00:00:00:a0 succeeded
Jul  9 11:29:58 deimos kernel: [    4.231671] ata1.00: ACPI cmd f5/00:00:00:00:00:a0 filtered out
Jul  9 11:29:58 deimos kernel: [    4.231773] ata1.00: ACPI cmd ef/5f:00:00:00:00:a0 succeeded
Jul  9 11:29:58 deimos kernel: [    4.231890] ata1.00: ACPI cmd ef/10:03:00:00:00:a0 succeeded
Jul  9 11:29:58 deimos kernel: [    4.232741] ata1.00: ACPI cmd ef/02:00:00:00:00:a0 succeeded
Jul  9 11:29:58 deimos kernel: [    4.232743] ata1.00: ACPI cmd f5/00:00:00:00:00:a0 filtered out
Jul  9 11:29:58 deimos kernel: [    4.232854] ata1.00: ACPI cmd ef/5f:00:00:00:00:a0 succeeded
Jul  9 11:29:58 deimos kernel: [    4.232956] ata1.00: ACPI cmd ef/10:03:00:00:00:a0 succeeded
Jul  9 11:29:58 deimos kernel: [    4.233338] ata1.00: configured for UDMA/133
Jul  9 11:29:58 deimos kernel: [    4.234993] ata1.00: configured for UDMA/133
Jul  9 11:29:58 deimos kernel: [    4.234994] ata1: EH complete
Jul  9 11:29:58 deimos kernel: [    4.235022] sd 0:0:0:0: [sda] 488397168 512-byte hardware sectors (250059 MB)
Jul  9 11:29:58 deimos kernel: [    4.235030] sd 0:0:0:0: [sda] Write Protect is off
Jul  9 11:29:58 deimos kernel: [    4.235031] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
Jul  9 11:29:58 deimos kernel: [    4.235042] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
Jul  9 11:29:58 deimos kernel: [    4.235052] sd 0:0:0:0: [sda] 488397168 512-byte hardware sectors (250059 MB)
Jul  9 11:29:58 deimos kernel: [    4.235058] sd 0:0:0:0: [sda] Write Protect is off
Jul  9 11:29:58 deimos kernel: [    4.235059] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
Jul  9 11:29:58 deimos kernel: [    4.235069] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
Jul  9 11:29:58 deimos kernel: [    4.433215] PM: Finishing wakeup.
Jul  9 11:29:58 deimos kernel: [    4.433216] Restarting tasks ... <6>usb 3-1: USB disconnect, address 2
Jul  9 11:29:58 deimos kernel: [    4.436503] done.

I can post stuff from before or after that too if you need it.

Is the problem my hard drive power management or something else? How do I go about correcting this problem?

biophysics 07-11-2008 10:53 AM

did you look at this, seems to be fine.
http://thinkwiki.org/wiki/Install_Ub...a_T61p#Suspend

kwesadilo 07-16-2008 09:19 AM

Thanks
 
Sorry for not responding sooner. I'll be out of state this whole week, and I don't have that computer with me. But I'll try that when I get back and tell you how it went. Thanks for the link.

kwesadilo 07-21-2008 03:22 PM

Ubuntu Lenovo power quirks
 
I went to this page, on which the link you gave was based, because the article on Thinkwiki was about a T61p type 6460, and mine is a 6459. A user commenting on that bug report page submitted a patch to use for a 6459. It just comments out the 6459 section of /usr/share/hal/fdi/information/10freedesktop/20-video-quirk-pm-lenovo.fdi. After doing that, my resume time is about 10 seconds consistently. The same process takes about 5 seconds in Windows XP on the same machine, so I'm not sure I would say that the problem is solved, but it is better now than it was before. Thanks for your help.

biophysics 07-22-2008 05:27 AM

Quote:

The same process takes about 5 seconds in Windows XP on the same machine, so I'm not sure I would say that the problem is solved, but it is better now than it was before.
What you can try to increase the speed of suspend and resume is use tuxonice. http://wiki.tuxonice.net Although you have a recompile the kernel it is fairly easy process and the advantage being you will have the buffers and caches _saved_ so the machine is more responsive.

kwesadilo 07-26-2008 12:53 PM

It's back from the dead
 
So my computer was working better for about a day. Then, without me making any changes, it just went back to not working. Sort of.

Now it usually takes between 22 and 24 seconds to resume from suspend-to-RAM. The only exception seems to be when it has been sleeping for a fairly short period. When the suspend is less than about 1.5 minutes (I haven't tested longer than that yet), the resume process takes between 7 and 12 seconds. In the tests that I did where it took a long time to wake up, I left it suspended for approximately half an hour.

It seems like, instead of just commenting out the entry for my type of computer in /usr/share/hal/fdi/information/10freedesktop/20-video-quirk-pm-lenovo.fdi, I should be able to edit it so that it says the right thing. Does anyone know how to do that?

Edit: One other thing I should mention. Sometimes, when the computer is waking up, it emits several (probably 5 or 6) system beeps in quick succession just before it finishes waking up. This has been happening since before I started trying to fix this problem.


All times are GMT -5. The time now is 08:30 PM.