diff options
author | Nick Dyer <nick.dyer@itdev.co.uk> | 2018-07-27 14:49:10 -0400 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2018-07-27 14:59:33 -0400 |
commit | 2ca3ba0ae4cf0bf9c17f1a04298c3acca24be5e0 (patch) | |
tree | 2fbba83a1722b836afb756dc38e11f24d50abd11 /drivers/input | |
parent | a4891f10583748933a9985fac7aa7c073cc59c85 (diff) |
Input: atmel_mxt_ts - don't report zero pressure from T9
If T9.CTRL DISAMP is set, then pressure is reported as zero. This means
some app layers (eg tslib) will ignore the contact.
Signed-off-by: Nick Dyer <nick.dyer@itdev.co.uk>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input')
-rw-r--r-- | drivers/input/touchscreen/atmel_mxt_ts.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/input/touchscreen/atmel_mxt_ts.c b/drivers/input/touchscreen/atmel_mxt_ts.c index 77387f896262..e32667d82d0f 100644 --- a/drivers/input/touchscreen/atmel_mxt_ts.c +++ b/drivers/input/touchscreen/atmel_mxt_ts.c | |||
@@ -843,6 +843,10 @@ static void mxt_proc_t9_message(struct mxt_data *data, u8 *message) | |||
843 | mxt_input_sync(data); | 843 | mxt_input_sync(data); |
844 | } | 844 | } |
845 | 845 | ||
846 | /* if active, pressure must be non-zero */ | ||
847 | if (!amplitude) | ||
848 | amplitude = MXT_PRESSURE_DEFAULT; | ||
849 | |||
846 | /* Touch active */ | 850 | /* Touch active */ |
847 | input_mt_report_slot_state(input_dev, MT_TOOL_FINGER, 1); | 851 | input_mt_report_slot_state(input_dev, MT_TOOL_FINGER, 1); |
848 | input_report_abs(input_dev, ABS_MT_POSITION_X, x); | 852 | input_report_abs(input_dev, ABS_MT_POSITION_X, x); |