Laptop lid close event is not always detected on MSI S250

Bug #43391 reported by Mikko Saarinen
6
Affects Status Importance Assigned to Milestone
acpi (Ubuntu)
Invalid
Medium
Unassigned

Bug Description

I installed Dapper Flight 6 to my MSI S250 laptop and it was working ok.

When the bug 35213 got fixed there soon was another one concerning the laptop lid close detection system. Seems like the lid close event, which can be set to either suspend or hibernate the system, is noticed only the first time after a reboot. The second time the lid gets closed dmesg says nothing of the event.

I tested this as best as I could and noticed that it doesn't matter how many times I suspend or hibernate from the menu, this always works the first time I close the lid, but never again until I have rebooted my machine.

On my machine this event is seemingly detected as "pccard: card ejected from slot 0". This message is the first message that appears in dmesg when I close the lid.

This is the dmesg notifying about the first lid close (and hibernation and resume events that follow). After this no matter how many times I close the lid there are no more messages:

[4294771.910000] pcmcia: Detected deprecated PCMCIA ioctl usage.
[4294771.910000] pcmcia: This interface will soon be removed from the kernel; please expect breakage unless you upgrade to new tools.
[4294771.910000] pcmcia: see http://www.kernel.org/pub/linux/utils/kernel/pcmcia/pcmcia.html for details.
[4294771.910000] pccard: card ejected from slot 0
[4294773.180000] ACPI: PCI interrupt for device 0000:00:0e.0 disabled
[4294776.577000] Freezing cpus ...
[4294776.578000] Stopping tasks: ========================================================================================|
[4294776.579000] Shrinking memory... done (28768 pages freed)
[4294776.757000] ACPI: PCI interrupt for device 0000:00:09.1 disabled
[4294776.757000] ACPI: PCI interrupt for device 0000:00:09.0 disabled
[4294776.757000] ACPI: PCI interrupt for device 0000:00:03.3 disabled
[4294776.768000] ACPI: PCI interrupt for device 0000:00:03.1 disabled
[4294776.768000] ACPI: PCI interrupt for device 0000:00:03.0 disabled
[4294776.768000] ACPI: PCI interrupt for device 0000:00:02.7 disabled
[4294776.768000] swsusp: Need to copy 51409 pages
[4294776.768000] swsusp: Restoring Highmem
[4294840.768000] **** SET: Misaligned resource pointer: d75bc702 Type 07 Len 0
[4294840.768000] **** SET: Misaligned resource pointer: d75bc702 Type 07 Len 0
[4294840.768000] **** SET: Misaligned resource pointer: d75bc702 Type 07 Len 0
[4294840.768000] **** SET: Misaligned resource pointer: d75bc702 Type 07 Len 0
[4294840.768000] **** SET: Misaligned resource pointer: d75bc702 Type 07 Len 0
[4294840.768000] **** SET: Misaligned resource pointer: d75bc702 Type 07 Len 0
[4294840.768000] **** SET: Misaligned resource pointer: d75bc702 Type 07 Len 0
[4294840.786000] ACPI: PCI Interrupt 0000:00:02.7[C] -> Link [LNKC] -> GSI 10 (level, low) -> IRQ 10
[4294841.038000] ACPI: PCI Interrupt 0000:00:03.0[A] -> Link [LNKE] -> GSI 5 (level, low) -> IRQ 5
[4294841.039000] ACPI: PCI Interrupt 0000:00:03.1[B] -> Link [LNKF] -> GSI 7 (level, low) -> IRQ 7
[4294841.050000] ACPI: PCI Interrupt 0000:00:03.3[D] -> Link [LNKH] -> GSI 5 (level, low) -> IRQ 5
[4294841.050000] ACPI: PCI Interrupt 0000:00:04.0[A] -> Link [LNKD] -> GSI 10 (level, low) -> IRQ 10
[4294841.050000] ACPI: PCI Interrupt 0000:00:09.0[A] -> Link [LNKA] -> GSI 11 (level, low) -> IRQ 11
[4294841.050000] ACPI: PCI Interrupt 0000:00:09.1[B] -> Link [LNKB] -> GSI 5 (level, low) -> IRQ 5
[4294841.050000] ACPI: PCI Interrupt 0000:00:09.2[C] -> Link [LNKC] -> GSI 10 (level, low) -> IRQ 10
[4294841.688000] ACPI-0517: *** Error: Method parse/execution failed [\_SB_.PCI0.IDEC.IDE0._STM] (Node ddfb8aa0), AE_AML_PACKAGE_LIMIT
[4294841.970000] ACPI-0517: *** Error: Method parse/execution failed [\_SB_.PCI0.IDEC.IDE1._STM] (Node ddfb8960), AE_AML_PACKAGE_LIMIT
[4294842.127000] Restarting tasks... done
[4294842.143000] Thawing cpus ...
[4294845.330000] sis900.c: v1.08.09 Sep. 19 2005
[4294845.331000] ACPI: PCI Interrupt 0000:00:04.0[A] -> Link [LNKD] -> GSI 10 (level, low) -> IRQ 10
[4294845.332000] 0000:00:04.0: ICS LAN PHY transceiver found at address 1.
[4294845.344000] 0000:00:04.0: Using transceiver found at address 1 as default
[4294845.346000] eth0: SiS 900 PCI Fast Ethernet at 0xd800, IRQ 10, 00:11:09:ab:ee:18.
[4294845.399000] ACPI: PCI Interrupt 0000:00:0e.0[A] -> Link [LNKB] -> GSI 5 (level, low) -> IRQ 5
[4294845.399000] rt2500 1.1.0 BETA3 2005/07/31 http://rt2x00.serialmonkey.com
[4294846.044000] pccard: PCMCIA card inserted into slot 0
[4294846.044000] pcmcia: registering new device pcmcia0.0
[4294847.709000] ACPI: Power Button (FF) [PWRF]
[4294847.709000] ACPI: Lid Switch [LID0]
[4294847.709000] ACPI: Sleep Button (CM) [SLPB]
[4294847.709000] ACPI: Power Button (CM) [PWRB]
[4294848.800000] ACPI: CPU0 (power states: C1[C1] C2[C2] C3[C3])
[4294848.801000] ACPI: Processor [CPU1] (supports 8 throttling states)
[4294848.810000] ACPI: Thermal Zone [THRM] (51 C)
[4294848.878000] ACPI: AC Adapter [ADP1] (on-line)
[4294848.925000] ACPI: Battery Slot [BAT1] (battery present)
[4294856.852000] ra0: no IPv6 routers present

Revision history for this message
Mikko Saarinen (mikk0) wrote :

After todays updates this problem still exists.

I thought that some process got killed during the process and tested by running "ps -A" before and after the suspend (by closing the lid). After stripping all buth the process names and sorting them I ran "diff before after" and this is what it printed:

51a52,53
> kacpid-work-0
> kacpid-work-1
78d79
< shpchpd_event

The same output came by running the same test with suspending from the menu, so I guess it's irrelevant.

Next I'll do a re-install with Beta2. My previous install wasn't a very succesful one, so let's hope this will fix things.

Revision history for this message
Mikko Saarinen (mikk0) wrote :

Now after a clean Beta2 install (from the desktop CD) lid close is detected and suspend works. Hibernate doesn't however work, but I believe it might be caused by the bug #35213 (not sure if that was already fixed in Beta2).

Currently I'm updating all the packages that have changed since Beta2. If this problem resurfaces, then we know it is caused by something that has changed in that period.

I'll let you know when the updates are ready.

Revision history for this message
Mikko Saarinen (mikk0) wrote :

You might set this as confirmed because after the fresh install with desktop CD and latest updates, this stopped working again.

I even downloaded the Install CD and installed the whole system again (had other problems with the express installer). The same story continues. After installation this event worked, but again when I updated to latest packages, this is not functioning anymore. I am sure that I did not touch any configuration files in either of these installations.

I have more info of this problem. Seems like the system really detects the lid close, but somehow nothing happens. This is the output of my /var/log/acpid:

[Sun May 14 13:16:33 2006] received event "button/lid LID0 00000080 00000006"
[Sun May 14 13:16:33 2006] notifying client 4342[108:108]
[Sun May 14 13:16:33 2006] executing action "/etc/acpi/lid.sh"
[Sun May 14 13:16:33 2006] BEGIN HANDLER MESSAGES
[Sun May 14 13:16:33 2006] END HANDLER MESSAGES
[Sun May 14 13:16:33 2006] action exited with status 0
[Sun May 14 13:16:33 2006] completed event "button/lid LID0 00000080 00000006"
[Sun May 14 13:16:46 2006] received event "button/lid LID0 00000080 00000007"
[Sun May 14 13:16:46 2006] notifying client 4342[108:108]
[Sun May 14 13:16:46 2006] executing action "/etc/acpi/lid.sh"
[Sun May 14 13:16:46 2006] BEGIN HANDLER MESSAGES
[Sun May 14 13:16:46 2006] END HANDLER MESSAGES
[Sun May 14 13:16:46 2006] action exited with status 0
[Sun May 14 13:16:46 2006] completed event "button/lid LID0 00000080 00000007"
[Sun May 14 13:16:56 2006] received event "button/lid LID0 00000080 00000008"
[Sun May 14 13:16:56 2006] notifying client 4342[108:108]
[Sun May 14 13:16:56 2006] executing action "/etc/acpi/lid.sh"
[Sun May 14 13:16:56 2006] BEGIN HANDLER MESSAGES
[Sun May 14 13:16:56 2006] END HANDLER MESSAGES
[Sun May 14 13:16:56 2006] action exited with status 0
[Sun May 14 13:16:56 2006] completed event "button/lid LID0 00000080 00000008"

I emptied the kernel ring buffer with dmesg -c before these attempts and then raised the level of info with dmesg -n8. Still dmesg shows nothing after these events, even though they are noted by acpid.

Can anyone guess where the problem is? If it is in lid.sh then why aren't everybody else suffering from this?

Revision history for this message
Mikko Saarinen (mikk0) wrote :

I wonder what this notifying client 4342 means. If that is a pid, then it is hald-addon-acpi:

mikko@mini:/etc/acpi$ ps -A | grep 4342
 4342 ? 00:00:00 hald-addon-acpi

I also made lid.sh a symbolic link to sleepbtn.sh and guess what - now every time I close the lid (or push that little button near the hinge) the machine goes to sleep! So there is something in lid.sh that is not working right.

After all sleepbtn.sh only sends this event: "acpi_fakekey $KEY_SLEEP" Next thing I'll do is to look if lid.sh sends any such messages.

This is progress, as now I can actually use my machine the way I'm used to =)

Revision history for this message
Mikko Saarinen (mikk0) wrote :

All the other button scripts have a line that triggers an acpi_fakekey $KEYNAME function. Why is there not such a line in lid.sh?

Found this by calling 'grep acpi_fakekey /etc/acpi/*'

This is still not working even with the latest updates.

Revision history for this message
Andrew Jorgensen (ajorg) wrote :

Mikko, will you look at Bug #34389 and see if yours is a duplicate of that?

Thanks

Revision history for this message
Andrew Ash (ash211) wrote :

Mikko, please check on the above comment, and also let us know if this still occurs in Dapper or Edgy? Thanks

Revision history for this message
Mikko Saarinen (mikk0) wrote :

Yes. I think this is a duplicate of bug #34389. Thanks for pointing it out.

mikko@mini:~$ cat /proc/acpi/button/lid/LID0/state
state: closed

And yes, this still happens with Edgy.

Revision history for this message
Andrew Ash (ash211) wrote :

OK then. I'm marking this a duplicate of that bug. Please continue discussion on its page. Thanks.

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for acpi (Ubuntu) because there has been no activity for 60 days.]

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.