EmbeddedController icon indicating copy to clipboard operation
EmbeddedController copied to clipboard

Framework 12 power button does not work with systemd-logind's HandlePowerKeyLongPress

Open haku opened this issue 5 months ago • 0 comments

In /etc/systemd/logind.conf i have this, but the long press event never triggers.

HandlePowerKey=lock
HandlePowerKeyLongPress=hibernate

I am guessing the power button always sends a momentary-press event even when it is held? Would it be possible to make it so that it sends whatever logind is expecting for long presses? When tailing the logs the short press message appears immediately even when holding the power button:

$ journalctl -u systemd-logind.service -f
Aug 22 10:01:19 hostname systemd-logind[1081]: Power key pressed short.
Aug 22 10:01:19 hostname systemd-logind[1081]: Locking sessions...

It is interesting to note that logind hard-codes 5 seconds for long press while the EC hard-codes 8 seconds*, so there will likely be some skill in holding it for exactly the right duration :)

  • side note: i can not figure out which of these files applies to the FW12?

haku avatar Aug 22 '25 09:08 haku