Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Input: wacom - process outbound for newer Cintiqs

New Cintiq tablets have a 200 tablet counts outside of screen area.
Add x/y_min for ABS_X/Y to pass this information to userland.

Signed-off-by: Ping Cheng <pingc@wacom.com>
Reviewed-by: Jason Gerecke <killertofu@gmail.com>
Tested-by: Jason Gerecke <killertofu@gmail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>

authored by

Ping Cheng and committed by
Dmitry Torokhov
ac414da3 805a876a

+24 -22
+22 -22
drivers/input/tablet/wacom_wac.c
··· 1576 1576 struct wacom_features *features = &wacom_wac->features; 1577 1577 1578 1578 if (features->device_type == BTN_TOOL_PEN) { 1579 - input_set_abs_params(input_dev, ABS_X, 0, features->x_max, 1580 - features->x_fuzz, 0); 1581 - input_set_abs_params(input_dev, ABS_Y, 0, features->y_max, 1582 - features->y_fuzz, 0); 1579 + input_set_abs_params(input_dev, ABS_X, features->x_min, 1580 + features->x_max, features->x_fuzz, 0); 1581 + input_set_abs_params(input_dev, ABS_Y, features->y_min, 1582 + features->y_max, features->y_fuzz, 0); 1583 1583 input_set_abs_params(input_dev, ABS_PRESSURE, 0, 1584 1584 features->pressure_max, features->pressure_fuzz, 0); 1585 1585 ··· 2135 2135 63, INTUOSPL, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 2136 2136 .touch_max = 16 }; 2137 2137 static const struct wacom_features wacom_features_0xF4 = 2138 - { "Wacom Cintiq 24HD", WACOM_PKGLEN_INTUOS, 104480, 65600, 2047, 2139 - 63, WACOM_24HD, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES }; 2138 + { "Wacom Cintiq 24HD", WACOM_PKGLEN_INTUOS, 104280, 65400, 2047, 2139 + 63, WACOM_24HD, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 200, 200 }; 2140 2140 static const struct wacom_features wacom_features_0xF8 = 2141 - { "Wacom Cintiq 24HD touch", WACOM_PKGLEN_INTUOS, 104480, 65600, 2047, /* Pen */ 2142 - 63, WACOM_24HD, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 2141 + { "Wacom Cintiq 24HD touch", WACOM_PKGLEN_INTUOS, 104280, 65400, 2047, /* Pen */ 2142 + 63, WACOM_24HD, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 200, 200, 2143 2143 .oVid = USB_VENDOR_ID_WACOM, .oPid = 0xf6 }; 2144 2144 static const struct wacom_features wacom_features_0xF6 = 2145 2145 { "Wacom Cintiq 24HD touch", .type = WACOM_24HDT, /* Touch */ ··· 2154 2154 { "Wacom Cintiq 12WX", WACOM_PKGLEN_INTUOS, 53020, 33440, 1023, 2155 2155 63, WACOM_BEE, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES }; 2156 2156 static const struct wacom_features wacom_features_0x304 = 2157 - { "Wacom Cintiq 13HD", WACOM_PKGLEN_INTUOS, 59552, 33848, 1023, 2158 - 63, WACOM_13HD, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES }; 2157 + { "Wacom Cintiq 13HD", WACOM_PKGLEN_INTUOS, 59352, 33648, 1023, 2158 + 63, WACOM_13HD, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 200, 200 }; 2159 2159 static const struct wacom_features wacom_features_0xC7 = 2160 2160 { "Wacom DTU1931", WACOM_PKGLEN_GRAPHIRE, 37832, 30305, 511, 2161 2161 0, PL, WACOM_INTUOS_RES, WACOM_INTUOS_RES }; ··· 2169 2169 { "Wacom DTU1031", WACOM_PKGLEN_DTUS, 22096, 13960, 511, 2170 2170 0, DTUS, WACOM_INTUOS_RES, WACOM_INTUOS_RES }; 2171 2171 static const struct wacom_features wacom_features_0x57 = 2172 - { "Wacom DTK2241", WACOM_PKGLEN_INTUOS, 95840, 54260, 2047, 2173 - 63, DTK, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES}; 2172 + { "Wacom DTK2241", WACOM_PKGLEN_INTUOS, 95640, 54060, 2047, 2173 + 63, DTK, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 200, 200 }; 2174 2174 static const struct wacom_features wacom_features_0x59 = /* Pen */ 2175 - { "Wacom DTH2242", WACOM_PKGLEN_INTUOS, 95840, 54260, 2047, 2176 - 63, DTK, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 2175 + { "Wacom DTH2242", WACOM_PKGLEN_INTUOS, 95640, 54060, 2047, 2176 + 63, DTK, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 200, 200, 2177 2177 .oVid = USB_VENDOR_ID_WACOM, .oPid = 0x5D }; 2178 2178 static const struct wacom_features wacom_features_0x5D = /* Touch */ 2179 2179 { "Wacom DTH2242", .type = WACOM_24HDT, 2180 2180 .oVid = USB_VENDOR_ID_WACOM, .oPid = 0x59, .touch_max = 10 }; 2181 2181 static const struct wacom_features wacom_features_0xCC = 2182 - { "Wacom Cintiq 21UX2", WACOM_PKGLEN_INTUOS, 87200, 65600, 2047, 2183 - 63, WACOM_21UX2, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES }; 2182 + { "Wacom Cintiq 21UX2", WACOM_PKGLEN_INTUOS, 87000, 65400, 2047, 2183 + 63, WACOM_21UX2, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 200, 200 }; 2184 2184 static const struct wacom_features wacom_features_0xFA = 2185 - { "Wacom Cintiq 22HD", WACOM_PKGLEN_INTUOS, 95840, 54260, 2047, 2186 - 63, WACOM_22HD, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES }; 2185 + { "Wacom Cintiq 22HD", WACOM_PKGLEN_INTUOS, 95640, 54060, 2047, 2186 + 63, WACOM_22HD, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 200, 200 }; 2187 2187 static const struct wacom_features wacom_features_0x5B = 2188 - { "Wacom Cintiq 22HDT", WACOM_PKGLEN_INTUOS, 95840, 54260, 2047, 2189 - 63, WACOM_22HD, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 2188 + { "Wacom Cintiq 22HDT", WACOM_PKGLEN_INTUOS, 95640, 54060, 2047, 2189 + 63, WACOM_22HD, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 200, 200, 2190 2190 .oVid = USB_VENDOR_ID_WACOM, .oPid = 0x5e }; 2191 2191 static const struct wacom_features wacom_features_0x5E = 2192 2192 { "Wacom Cintiq 22HDT", .type = WACOM_24HDT, ··· 2340 2340 { "ISD-V4", WACOM_PKGLEN_GRAPHIRE, 12800, 8000, 255, 2341 2341 0, TABLETPC, WACOM_INTUOS_RES, WACOM_INTUOS_RES }; 2342 2342 static const struct wacom_features wacom_features_0x0307 = 2343 - { "Wacom ISDv5 307", WACOM_PKGLEN_INTUOS, 59552, 33848, 2047, 2344 - 63, CINTIQ_HYBRID, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 2343 + { "Wacom ISDv5 307", WACOM_PKGLEN_INTUOS, 59352, 33648, 2047, 2344 + 63, CINTIQ_HYBRID, WACOM_INTUOS3_RES, WACOM_INTUOS3_RES, 200, 200, 2345 2345 .oVid = USB_VENDOR_ID_WACOM, .oPid = 0x309 }; 2346 2346 static const struct wacom_features wacom_features_0x0309 = 2347 2347 { "Wacom ISDv5 309", .type = WACOM_24HDT, /* Touch */
+2
drivers/input/tablet/wacom_wac.h
··· 122 122 int type; 123 123 int x_resolution; 124 124 int y_resolution; 125 + int x_min; 126 + int y_min; 125 127 int device_type; 126 128 int x_phy; 127 129 int y_phy;