wacom: fix pressure in Cintiq 21UX2
PATCH 1/1 wacom: fix pressure in Cintiq 21UX2
Currently the pressure range in Cintiq 21UX2 is limited to half of the supported. This patch fixes the problem.
Signed-off-by Aristeu Rozanski <[email protected]>
--- drivers/input/tablet/wacom_wac.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/input/tablet/wacom_wac.c +2 -1
@@ -442,7 +442,8 @@ static void wacom_intuos_general(struct/* general pen packet */ if ((data[1 ] &0xb8 ) ==0xa0 ) { t = (data[6 ] <<2 ) | ((data[7 ] >>6 ) &3 ); -if (features->type >=INTUOS4S && features->type <=INTUOS4L ) +if (features->type >=INTUOS4S && features->type <=INTUOS4L || + features->type ==WACOM_21UX2 ) t = (t <<1 ) | (data[1 ] &1 );input_report_abs (input,ABS_PRESSURE , t); input_report_abs(input, ABS_TILT_X,
Quoted 4 lines · Aristeu Rozanski
Currently the pressure range in Cintiq 21UX2 is limited to half of the supported. This patch fixes the problem.
Signed-off-by Aristeu Rozanski <[email protected]>
Acked-by Ping Cheng <[email protected]>
Thank you Aristeu.
Dmitry, this patch should be backported since it is a bug fix.
Ping
Quoted 17 lines
---
drivers/input/tablet/wacom_wac.c | 3 ++-1 file changed, 2 insertions(+), 1 deletion(-)drivers/input/tablet/wacom_wac.c 2010-10-07 17:20:30.000000000 -0400 renamed from drivers/input/tablet/wacom_wac.c 2010-09-22 14:52:22.000000000 -0400 +2
-1@@ -442,7 +442,8 @@ static void wacom_intuos_general(struct /* general pen packet */ if ((data[1] & 0xb8) == 0xa0) { t = (data[6] << 2) | ((data[7] >> 6) & 3); - if (features->type >= INTUOS4S && features->type <= INTUOS4L) + if (features->type >= INTUOS4S && features->type <= INTUOS4L || + features->type == WACOM_21UX2) t = (t << 1) | (data[1] & 1); input_report_abs(input, ABS_PRESSURE, t); input_report_abs(input, ABS_TILT_X,
Dmitry Torokhov
maintainerQuoted 4 lines · Ping Cheng
Quoted 3 lines · Aristeu Rozanski
Currently the pressure range in Cintiq 21UX2 is limited to half of the supported. This patch fixes the problem.
Quoted 8 lines
Quoted 1 line
Signed-off-by Aristeu Rozanski <[email protected]>Acked-by Ping Cheng <[email protected]>Thank you Aristeu.
Dmitry, this patch should be backported since it is a bug fix.
OK, will mark it for stable.
Thanks.
Signature · 1 line
Dmitry