Re: Double tap to wake optionality
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Date: 2026-09-13 23:33:28
Hi David, On Mon, Sep 07, 2026 at 12:02:12AM +0200, David Heidelberg wrote:
Hello!
Most of touchscreens has ability to jump into low power mode and get woken
up by gesture (such as double tap).
I wonder about suggestion what property should drivers use to implement this
policy where driver doesn't have to jump into low-power mode but completely
power-off (and save battery). My thinking was something such as
/sys/class/input/inputX/gesture_to_wake
(while gesture sounds a bit weird, it seems that TS are capable to recognize
different patterns, not only double-tap).
userspace
│
│ gesture_to_wake = 1
▼
touchscreen driver
│
┌────────────┴────────────┐
│ │
gesture ON gesture OFF
│ │
▼ ▼
low-power TS mode complete power-off
│
▼
IRQ configured
as wake sourceHow is it different from the power/wakeup device attribute? Device's suspend routines check device_may_wakeup() and then either completely power off controllers or configure them for wake up. How exactly wakeup is handled - any touch, or double-tap, or something else - is up to the controller and its firmware. Thanks. -- Dmitry