Skip to content

Commit

Permalink
backport: HID: wacom: correct misreported EKR ring values
Browse files Browse the repository at this point in the history
The EKR ring claims a range of 0 to 71 but actually reports
values 1 to 72. The ring is used in relative mode so this
change should not affect users.

Signed-off-by: Aaron Armstrong Skomra <aaron.skomra@wacom.com>
Fixes: 72b236d60218f ("HID: wacom: Add support for Express Key Remote.")
Cc: <stable@vger.kernel.org> # v4.3+
Reviewed-by: Ping Cheng <ping.cheng@wacom.com>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
[aaron.skomra@wacom.com: Imported into input-wacom repository (fcf887e7caaa)]
Signed-off-by: Aaron Armstrong Skomra <aaron.skomra@wacom.com>
[aaron.skomra@wacom.com: Backported to input-wacom repository (de08dab)]
Signed-off-by: Aaron Armstrong Skomra <aaron.skomra@wacom.com>
  • Loading branch information
skomra committed Sep 4, 2019
1 parent 7767fc5 commit e926e28
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion 2.6.38/wacom_wac.c
Original file line number Diff line number Diff line change
Expand Up @@ -1055,7 +1055,7 @@ static int wacom_remote_irq(struct wacom_wac *wacom_wac, size_t len)
input_report_key(input, BTN_BASE2, (data[11] & 0x02));

if (data[12] & 0x80)
input_report_abs(input, ABS_WHEEL, (data[12] & 0x7f));
input_report_abs(input, ABS_WHEEL, (data[12] & 0x7f) - 1);
else
input_report_abs(input, ABS_WHEEL, 0);

Expand Down
2 changes: 1 addition & 1 deletion 3.17/wacom_wac.c
Original file line number Diff line number Diff line change
Expand Up @@ -1079,7 +1079,7 @@ static int wacom_remote_irq(struct wacom_wac *wacom_wac, size_t len)
input_report_key(input, BTN_BASE2, (data[11] & 0x02));

if (data[12] & 0x80)
input_report_abs(input, ABS_WHEEL, (data[12] & 0x7f));
input_report_abs(input, ABS_WHEEL, (data[12] & 0x7f) - 1);
else
input_report_abs(input, ABS_WHEEL, 0);

Expand Down
2 changes: 1 addition & 1 deletion 3.7/wacom_wac.c
Original file line number Diff line number Diff line change
Expand Up @@ -1055,7 +1055,7 @@ static int wacom_remote_irq(struct wacom_wac *wacom_wac, size_t len)
input_report_key(input, BTN_BASE2, (data[11] & 0x02));

if (data[12] & 0x80)
input_report_abs(input, ABS_WHEEL, (data[12] & 0x7f));
input_report_abs(input, ABS_WHEEL, (data[12] & 0x7f) - 1);
else
input_report_abs(input, ABS_WHEEL, 0);

Expand Down

0 comments on commit e926e28

Please sign in to comment.