HID: Intel-thc-hid: Intel-thc: Add Wake-on-Touch support
authorEven Xu <even.xu@intel.com>
Wed, 14 May 2025 06:37:33 +0000 (14:37 +0800)
committerJiri Kosina <jkosina@suse.com>
Tue, 10 Jun 2025 19:19:50 +0000 (21:19 +0200)
commitdcb2ccb93095fcaa2969370dcbbe82fc83d42229
tree20180c5b59bc2f6151252237f6d4f04a617a7564
parent2c7c9c5db3bc418fc52b222651524470eeaf6f36
HID: Intel-thc-hid: Intel-thc: Add Wake-on-Touch support

Wake-on-Touch (WoT) feature gives system the capability to wake from
sleep state by user touch event, it requires platform providing wake
GPIO through ACPI resource.

Intel UEFI provides a user setting to enable or disable THC device WoT
feature. If it's enabled, UEFI assigns an additional wake GPIO resource
to THC device ACPI configuration, facilitating system wakeup.

This patch provides helper APIs for THC device driver to query wake
GPIO resource, enable WoT feature and unconfigure WoT.

APIs added:
- thc_wot_config(): Query and configure wake-on-touch feature.
- thc_wot_unconfig(): Unconfig wake-on-touch feature.

Signed-off-by: Even Xu <even.xu@intel.com>
Tested-by: Chong Han <chong.han@intel.com>
Signed-off-by: Jiri Kosina <jkosina@suse.com>
drivers/hid/intel-thc-hid/Makefile
drivers/hid/intel-thc-hid/intel-thc/intel-thc-dev.h
drivers/hid/intel-thc-hid/intel-thc/intel-thc-wot.c [new file with mode: 0644]
drivers/hid/intel-thc-hid/intel-thc/intel-thc-wot.h [new file with mode: 0644]