summaryrefslogtreecommitdiff
path: root/drivers/hid/hid-multitouch.c
diff options
context:
space:
mode:
authorJiri Kosina <jkosina@suse.cz>2021-06-30 09:15:15 +0200
committerJiri Kosina <jkosina@suse.cz>2021-06-30 09:15:15 +0200
commitb3e29642548258c7cd2cb3326a776fff84cd6b69 (patch)
tree1c5da8119d9792ebf4d11ea4787c7529e97c8e53 /drivers/hid/hid-multitouch.c
parent8f4ef88ebadefcf16b7f616f8af940465c44bea2 (diff)
parent498d0ddc6ae931e4e79a57c56b6dd4576aa435b6 (diff)
Merge branch 'for-5.14/multitouch' into for-linus
- patch series that ensures that hid-multitouch driver disables touch and button-press reporting on hid-mt devices during suspend when the device is not configured as a wakeup-source, from Hans de Goede
Diffstat (limited to 'drivers/hid/hid-multitouch.c')
-rw-r--r--drivers/hid/hid-multitouch.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/hid/hid-multitouch.c b/drivers/hid/hid-multitouch.c
index 2e4fb76c45f3..3ea7cb1cda84 100644
--- a/drivers/hid/hid-multitouch.c
+++ b/drivers/hid/hid-multitouch.c
@@ -1768,7 +1768,8 @@ static int mt_suspend(struct hid_device *hdev, pm_message_t state)
struct mt_device *td = hid_get_drvdata(hdev);
/* High latency is desirable for power savings during S3/S0ix */
- if (td->mtclass.quirks & MT_QUIRK_DISABLE_WAKEUP)
+ if ((td->mtclass.quirks & MT_QUIRK_DISABLE_WAKEUP) ||
+ !hid_hw_may_wakeup(hdev))
mt_set_modes(hdev, HID_LATENCY_HIGH, false, false);
else
mt_set_modes(hdev, HID_LATENCY_HIGH, true, true);