Re: 2.6.26.[1-3] + x61 tablet + x6ultrabase: no resume after undocking

Tomas Carnecky
2008-09-01T10:59:05Z

[-- Attachment #1: Type: text/plain, Size: 2571 bytes --]

Zhang Rui wrote:
> On Sat, 2008-08-30 at 15:35 -0700, Steven King wrote:
>> While 2.6.26 made my x61t work with the x6ultrabase, I find that once I have
>> docked the x61t, I can only resume after a suspend2ram if the x61t is docked.
>> That is:
>>
>> Never have been docked: suspend & resume works fine.
>> Docked: suspend & resume works fine.
>> Docked, undocked, re-docked: suspend & resume works fine.
>>
>> Docked, then undocked: never finishes resuming (the disk seems to spin up and
>> the sleep led goes off, but the system doesnt seem to get any further).
>>
>> Any suggestions?
>>
> I have an acpidump of a X61, and it may also send notifications in _STA
> method.
> Please please try the following patch and see if it helps.
> and it would be great if you can attach the acpidump of your laptop.

It has always been a mystery to me how the docking station works. It
never worked for me correctly, in some situations, depending on how I
docked/undocked the notebook, it would hang during resume. I brought the
problem up in linux-acpi after I bought my X61 and the X6 UltraBase, but
no patch resulted so I simply got used to shutting down my notebook
instead of putting it to sleep.
There is one question though that was never answered: Is there any
interaction needed from the userspace when docking/undocking? Something
that the acpi daemon would have to do in response to a dock/undock
event? I'm thinking about
$ echo 1 > /sys/bus/scsi/devices/3\:0\:0\:0/rescan
or something like that. To tell the kernel that some devices may have
disappeared and that it shouldn't try to bring them up when resuming
from sleep. I would expect that ACPI would take care of that (it
certainly removes all USB devices and detaches ata4 (which is the bay in
the docking station).

Anyway, I tried your patch (on top of 2.6.26.3). If I start up the
notebook in the dock, take it out, put it to sleep, then it hangs during
resume (all I see on the screen is the cursor in the top left corner).

That behavior is consistent with my earlier experience, that is: If the
notebook was _ever_ running in the docking station, it won't resume
outside of it. No matter whether I start it outside the dock and then
put it into the dock, or start it up in the dock - once the notebook has
been docked, suspend/resume outside of the dock won't work anymore.
My wild uneducated guess is that the kernel doesn't remove/disable some
devices when undocking (the bay device?) and when it tries to resume
without them present it will hang.

Attached is my acpidump, I hope it helps.

tom

[-- Attachment #2: acpi-dump --]
[-- Type: application/octet-stream, Size: 63905 bytes --]