提交 8d515fda 编写于 作者: J Jason Gerecke 提交者: Jiri Kosina

HID: wacom: Report full pressure range for Intuos, Cintiq 13HD Touch

The new Intuos tablets added in eda01dab and the Cintiq 13HD Touch added
in b4bf2120 are capable of reporting 2048 levels of pressure. Although the
kernel reports the correct range to userspace, an oversight has resulted
in the driver ingoring the 11th pressure bit and only sending pressures
of 0 through 1023.

We could fix this issue by expanding the type check to include these
devices, but it makes much more sense to just have the driver look at
the device's maximum pressure when determining if it should read the
11th bit.
Signed-off-by: NJason Gerecke <jason.gerecke@wacom.com>
Reviewed-by: NPing Cheng <pingc@wacom.com>
Signed-off-by: NJiri Kosina <jkosina@suse.cz>
上级 f7acb55c
......@@ -765,7 +765,7 @@ static void wacom_intuos_general(struct wacom_wac *wacom)
/* general pen packet */
if ((data[1] & 0xb8) == 0xa0) {
t = (data[6] << 2) | ((data[7] >> 6) & 3);
if (features->type >= INTUOS4S && features->type <= CINTIQ_COMPANION_2) {
if (features->pressure_max == 2047) {
t = (t << 1) | (data[1] & 1);
}
input_report_abs(input, ABS_PRESSURE, t);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册