I have a SAMSUNG laptop, which by the experience in the last months, has been a great one. I am actually implementing some functionality to it, and since I noticed, I am able to wake up my laptop from sleep by just opening the lid on Windows 7, however, I need to press to power button to wake up in Ubuntu. Using a program called i-nex, I noted that the kernel DOES dettect a "lid switch", and I am looking forward to use it to wake up function. Any ideas?

enter image description here

UPDATE: Thanks @yossile for bringing up some clues! However, output of command cat /proc/acpi/wakeup does not show the LID device. I still tried the second set of commands you gave me with no effect. Then I tried experimenting, guessing that LID should be named by other value, so I tried enabling the others. No victory so far. But I noticed that devices that did not have any pci listings were disabled at all time no matter what I tried. Here is the output of command cat /proc/acpi/wakeup:

root@samsung:~# cat /proc/acpi/wakeup
Device  S-state   Status   Sysfs node
PCE4      S4    *disabled  pci:0000:00:04.0
SBAZ      S4    *disabled  pci:0000:00:14.2
P0PC      S4    *disabled  pci:0000:00:14.4
GEC       S4    *disabled  
PE20      S4    *disabled  pci:0000:00:15.0
PE21      S4    *disabled  
PE22      S4    *disabled  pci:0000:00:15.2
PE23      S4    *disabled  
PWRB      S5    *enabled

So maybe it could be that LID is either GEC,PE21, or PE23?

Still, there is /proc/acpi/button/lid/LID/state file which shows that LID is opened. Any more ideas?


You can check whether the Lid open event is configured to wake up your OS by executing the cat /proc/acpi/wakeup command.
If the status of the 'LID' device is currently disabled you can try enabling it by executing:

sudo -s
echo "LID" > /proc/acpi/wakeup

This will set the status to enabled.
Running the commands again will set it back to disabled.

  • This is exactly what I wanted thought to disable wakeup on opening the lid. Thanks. Sep 23 '13 at 5:56
  • 6
    My /proc/acpi/wakeup didn't contain LID but LID0 instead. Thus echo "LID0" > /proc/acpi/wakeup did the trick. Thank you!
    – humkins
    Nov 20 '13 at 0:07
  • 5
    My /proc/acpi/ directory contains only button/lid/LID0 on my Sony VAIO (which wakes in Windows when opening the lid, but neither echoing LID or LID0 into wakeup gets the desired behavior. Jan 23 '15 at 20:46
  • 1
    If you want to do the opposite and disable wakeup on lid open, the echo "LID" > /proc/acpi/wakeup toggles from enabled to disable and back. And in my case as @gumkins mentions it was LID0 for me not LID
    – gene_wood
    Oct 29 '19 at 0:44

In my case, I also had to set in BIOS, to use sleep optimized for linux instead of windows.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.