aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/touchscreen/goodix.h
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2021-12-08 09:33:35 -0800
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2021-12-09 00:13:13 -0800
commit5ede7f0cfb93f0f8edf2245671e18e982a247f55 (patch)
treeb6d2035eb2e01ea9499fb8e5b667e07a82160baa /drivers/input/touchscreen/goodix.h
parentMerge tag 'v5.15' into next (diff)
downloadlinux-dev-5ede7f0cfb93f0f8edf2245671e18e982a247f55.tar.xz
linux-dev-5ede7f0cfb93f0f8edf2245671e18e982a247f55.zip
Input: goodix - add pen support
Some Goodix touchscreens have support for a (Goodix) active pen, add support for this. The info on how to detect when a pen is down and to detect when the stylus buttons are pressed was lifted from the out of tree Goodix driver with pen support written by Adya: https://gitlab.com/AdyaAdya/goodix-touchscreen-linux-driver/ Since there is no way to tell if pen support is present, the registering of the pen input_dev is delayed till the first pen event is detected. This has been tested on a Trekstor Surftab duo W1, a Chuwi Hi13 and a Cyberbook T116 tablet. BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=202161 BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=204513 Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20211207100754.31155-3-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to '')
-rw-r--r--drivers/input/touchscreen/goodix.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/input/touchscreen/goodix.h b/drivers/input/touchscreen/goodix.h
index 62138f930d1a..f79eaeaceedb 100644
--- a/drivers/input/touchscreen/goodix.h
+++ b/drivers/input/touchscreen/goodix.h
@@ -76,6 +76,7 @@ struct goodix_chip_data {
struct goodix_ts_data {
struct i2c_client *client;
struct input_dev *input_dev;
+ struct input_dev *input_pen;
const struct goodix_chip_data *chip;
const char *firmware_name;
struct touchscreen_properties prop;