The IMS PCU (Passenger Control Unit) device used custom protocol over serial line, so it is presenting itself as CDC ACM device. Now that we have proper in-kernel driver for it we need to black-list the device in cdc-acm driver.
Unified · Split
| @@ -949,6 +949,10 @@ static int acm_probe(struct usb_interface *intf, · 948 unmodified lines | ||
| 949 | 949 | |
| 950 | 950 | /* normal quirks */ |
| 951 | 951 | quirks = (unsigned long)id->driver_info; |
| 952 | + | |
| 953 | + if (quirks == IGNORE_DEVICE) | |
| 954 | + return -ENODEV; | |
| 955 | + | |
| 952 | 956 | num_rx_buf = (quirks == SINGLE_RX_URB) ? 1 : ACM_NR; |
| 953 | 957 | |
| 954 | 958 | /* handle quirks deadly to normal probing*/ |
| @@ -1650,6 +1654,15 @@ static const struct usb_device_id acm_ids[] = { · 695 unmodified lines | ||
| 1650 | 1654 | .driver_info = NO_DATA_INTERFACE, |
| 1651 | 1655 | }, |
| 1652 | 1656 | |
| 1657 | +#if IS_ENABLED(CONFIG_INPUT_IMS_PCU) | |
| 1658 | + { USB_DEVICE(0x04d8, 0x0082), /* Application mode */ | |
| 1659 | + .driver_info = IGNORE_DEVICE, | |
| 1660 | + }, | |
| 1661 | + { USB_DEVICE(0x04d8, 0x0083), /* Bootloader mode */ | |
| 1662 | + .driver_info = IGNORE_DEVICE, | |
| 1663 | + }, | |
| 1664 | +#endif | |
| 1665 | + | |
| 1653 | 1666 | /* control interfaces without any protocol set */ |
| 1654 | 1667 | { USB_INTERFACE_INFO(USB_CLASS_COMM, USB_CDC_SUBCLASS_ACM, |
| 1655 | 1668 | USB_CDC_PROTO_NONE) }, |
| @@ -128,3 +128,4 @@ struct acm { · 127 unmodified lines | ||
| 128 | 128 | #define NO_CAP_LINE 4 |
| 129 | 129 | #define NOT_A_MODEM 8 |
| 130 | 130 | #define NO_DATA_INTERFACE 16 |
| 131 | +#define IGNORE_DEVICE 32 | |