You are not logged in.

#1 2015-10-02 21:18:44

cgo
Member
From: Paris, France
Registered: 2010-11-05
Posts: 22

[wol/userspace] How to know the computer powered on from Wake on Lan ?

Hi all,

I have a setup where Wake on LAN works well (x201 laptop woken up from a openwrt router).
This laptop has suspend on lid close.
When I wake my laptop from the network, it boots up (I can even ping it for a few seconds), and it goes straight into suspend mode (boring isn't it smile ?).
I know I can disable suspend on lid close (and/or suspend on lid close when docked).

My question is : is there some way to get the origin/source of the system resume or power on from userspace ? Some property in /sys, /proc, whatever... So that I can script "if the computer got up because of WOL, don't suspend on lid".

Thanks for any help,

Charles

Offline

Board footer

Powered by FluxBB