You've already forked linux-t2-patches
mirror of
https://github.com/t2linux/linux-t2-patches.git
synced 2026-04-30 13:52:11 -07:00
40 lines
1.3 KiB
Diff
40 lines
1.3 KiB
Diff
From a6c0007592c20a54d4cd68abe26ded40e0023518 Mon Sep 17 00:00:00 2001
|
|
From: Kerem Karabay <kekrby@gmail.com>
|
|
Date: Tue, 27 May 2025 22:13:16 +0530
|
|
Subject: [PATCH 4/5] HID: multitouch: specify that Apple Touch Bar is direct
|
|
|
|
Currently the driver determines the device type based on the
|
|
application, but this value is not reliable on Apple Touch Bar, where
|
|
the application is HID_DG_TOUCHPAD even though this device is direct,
|
|
so add a quirk for the same.
|
|
|
|
Acked-by: Benjamin Tissoires <bentiss@kernel.org>
|
|
Signed-off-by: Kerem Karabay <kekrby@gmail.com>
|
|
Co-developed-by: Aditya Garg <gargaditya08@live.com>
|
|
Signed-off-by: Aditya Garg <gargaditya08@live.com>
|
|
---
|
|
drivers/hid/hid-multitouch.c | 7 +++++++
|
|
1 file changed, 7 insertions(+)
|
|
|
|
diff --git a/drivers/hid/hid-multitouch.c b/drivers/hid/hid-multitouch.c
|
|
index f71500d1f..81c02138f 100644
|
|
--- a/drivers/hid/hid-multitouch.c
|
|
+++ b/drivers/hid/hid-multitouch.c
|
|
@@ -1349,6 +1349,13 @@ static int mt_touch_input_configured(struct hid_device *hdev,
|
|
if (td->serial_maybe)
|
|
mt_post_parse_default_settings(td, app);
|
|
|
|
+ /*
|
|
+ * The application for Apple Touch Bars is HID_DG_TOUCHPAD,
|
|
+ * but these devices are direct.
|
|
+ */
|
|
+ if (cls->quirks & MT_QUIRK_APPLE_TOUCHBAR)
|
|
+ app->mt_flags |= INPUT_MT_DIRECT;
|
|
+
|
|
if (cls->is_indirect)
|
|
app->mt_flags |= INPUT_MT_POINTER;
|
|
|
|
--
|
|
2.49.0
|
|
|