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

Merge tag 'input-for-v6.10-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input

Pull input fixes from Dmitry Torokhov:

- fixes for ili210x and elantech drivers

- new products IDs added to xpad controller driver

- a tweak to i8042 driver to always keep keyboard in Ayaneo Kun
handheld in raw mode

- populated "id_table" in ads7846 touchscreen driver to make sure
non-OF instantiated devices can properly determine the model data.

* tag 'input-for-v6.10-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
Input: ads7846 - use spi_device_id table
Input: xpad - add support for ASUS ROG RAIKIRI PRO
Input: ili210x - fix ili251x_read_touch_data() return value
Input: i8042 - add Ayaneo Kun to i8042 quirk table
Input: elantech - fix touchpad state on resume for Lenovo N24

+61 -5
+1
drivers/input/joystick/xpad.c
··· 209 209 { 0x0738, 0xf738, "Super SFIV FightStick TE S", 0, XTYPE_XBOX360 }, 210 210 { 0x07ff, 0xffff, "Mad Catz GamePad", 0, XTYPE_XBOX360 }, 211 211 { 0x0b05, 0x1a38, "ASUS ROG RAIKIRI", 0, XTYPE_XBOXONE }, 212 + { 0x0b05, 0x1abb, "ASUS ROG RAIKIRI PRO", 0, XTYPE_XBOXONE }, 212 213 { 0x0c12, 0x0005, "Intec wireless", 0, XTYPE_XBOX }, 213 214 { 0x0c12, 0x8801, "Nyko Xbox Controller", 0, XTYPE_XBOX }, 214 215 { 0x0c12, 0x8802, "Zeroplus Xbox Controller", 0, XTYPE_XBOX },
+31
drivers/input/mouse/elantech.c
··· 1477 1477 } 1478 1478 1479 1479 /* 1480 + * Some hw_version 4 models fail to properly activate absolute mode on 1481 + * resume without going through disable/enable cycle. 1482 + */ 1483 + static const struct dmi_system_id elantech_needs_reenable[] = { 1484 + #if defined(CONFIG_DMI) && defined(CONFIG_X86) 1485 + { 1486 + /* Lenovo N24 */ 1487 + .matches = { 1488 + DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"), 1489 + DMI_MATCH(DMI_PRODUCT_NAME, "81AF"), 1490 + }, 1491 + }, 1492 + #endif 1493 + { } 1494 + }; 1495 + 1496 + /* 1480 1497 * Put the touchpad back into absolute mode when reconnecting 1481 1498 */ 1482 1499 static int elantech_reconnect(struct psmouse *psmouse) 1483 1500 { 1501 + int err; 1502 + 1484 1503 psmouse_reset(psmouse); 1485 1504 1486 1505 if (elantech_detect(psmouse, 0)) 1487 1506 return -1; 1507 + 1508 + if (dmi_check_system(elantech_needs_reenable)) { 1509 + err = ps2_command(&psmouse->ps2dev, NULL, PSMOUSE_CMD_DISABLE); 1510 + if (err) 1511 + psmouse_warn(psmouse, "failed to deactivate mouse on %s: %d\n", 1512 + psmouse->ps2dev.serio->phys, err); 1513 + 1514 + err = ps2_command(&psmouse->ps2dev, NULL, PSMOUSE_CMD_ENABLE); 1515 + if (err) 1516 + psmouse_warn(psmouse, "failed to reactivate mouse on %s: %d\n", 1517 + psmouse->ps2dev.serio->phys, err); 1518 + } 1488 1519 1489 1520 if (elantech_set_absolute_mode(psmouse)) { 1490 1521 psmouse_err(psmouse,
+16 -2
drivers/input/serio/i8042-acpipnpio.h
··· 76 76 #define SERIO_QUIRK_PROBE_DEFER BIT(5) 77 77 #define SERIO_QUIRK_RESET_ALWAYS BIT(6) 78 78 #define SERIO_QUIRK_RESET_NEVER BIT(7) 79 - #define SERIO_QUIRK_DIECT BIT(8) 79 + #define SERIO_QUIRK_DIRECT BIT(8) 80 80 #define SERIO_QUIRK_DUMBKBD BIT(9) 81 81 #define SERIO_QUIRK_NOLOOP BIT(10) 82 82 #define SERIO_QUIRK_NOTIMEOUT BIT(11) ··· 1332 1332 .driver_data = (void *)(SERIO_QUIRK_NOMUX | SERIO_QUIRK_RESET_ALWAYS | 1333 1333 SERIO_QUIRK_NOLOOP | SERIO_QUIRK_NOPNP) 1334 1334 }, 1335 + { 1336 + /* 1337 + * The Ayaneo Kun is a handheld device where some the buttons 1338 + * are handled by an AT keyboard. The keyboard is usually 1339 + * detected as raw, but sometimes, usually after a cold boot, 1340 + * it is detected as translated. Make sure that the keyboard 1341 + * is always in raw mode. 1342 + */ 1343 + .matches = { 1344 + DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "AYANEO"), 1345 + DMI_MATCH(DMI_BOARD_NAME, "KUN"), 1346 + }, 1347 + .driver_data = (void *)(SERIO_QUIRK_DIRECT) 1348 + }, 1335 1349 { } 1336 1350 }; 1337 1351 ··· 1669 1655 if (quirks & SERIO_QUIRK_RESET_NEVER) 1670 1656 i8042_reset = I8042_RESET_NEVER; 1671 1657 } 1672 - if (quirks & SERIO_QUIRK_DIECT) 1658 + if (quirks & SERIO_QUIRK_DIRECT) 1673 1659 i8042_direct = true; 1674 1660 if (quirks & SERIO_QUIRK_DUMBKBD) 1675 1661 i8042_dumbkbd = true;
+11 -1
drivers/input/touchscreen/ads7846.c
··· 1111 1111 }; 1112 1112 MODULE_DEVICE_TABLE(of, ads7846_dt_ids); 1113 1113 1114 + static const struct spi_device_id ads7846_spi_ids[] = { 1115 + { "tsc2046", 7846 }, 1116 + { "ads7843", 7843 }, 1117 + { "ads7845", 7845 }, 1118 + { "ads7846", 7846 }, 1119 + { "ads7873", 7873 }, 1120 + { }, 1121 + }; 1122 + MODULE_DEVICE_TABLE(spi, ads7846_spi_ids); 1123 + 1114 1124 static const struct ads7846_platform_data *ads7846_get_props(struct device *dev) 1115 1125 { 1116 1126 struct ads7846_platform_data *pdata; ··· 1396 1386 }, 1397 1387 .probe = ads7846_probe, 1398 1388 .remove = ads7846_remove, 1389 + .id_table = ads7846_spi_ids, 1399 1390 }; 1400 1391 1401 1392 module_spi_driver(ads7846_driver); 1402 1393 1403 1394 MODULE_DESCRIPTION("ADS7846 TouchScreen Driver"); 1404 1395 MODULE_LICENSE("GPL"); 1405 - MODULE_ALIAS("spi:ads7846");
+2 -2
drivers/input/touchscreen/ili210x.c
··· 261 261 if (!error && data[0] == 2) { 262 262 error = i2c_master_recv(client, data + ILI251X_DATA_SIZE1, 263 263 ILI251X_DATA_SIZE2); 264 - if (error >= 0 && error != ILI251X_DATA_SIZE2) 265 - error = -EIO; 264 + if (error >= 0) 265 + error = error == ILI251X_DATA_SIZE2 ? 0 : -EIO; 266 266 } 267 267 268 268 return error;