Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
[GitHub/mt8127/android_kernel_alcatel_ttab.git] / drivers / usb / class / cdc-acm.c
index 171d7a9df3aedd31fe660b4a7fec2cb5f9e1e6d8..9b1cbcf8fb7fcfbd0f3b576d207a90dd4421c62f 100644 (file)
@@ -962,6 +962,10 @@ static int acm_probe(struct usb_interface *intf,
 
        /* normal quirks */
        quirks = (unsigned long)id->driver_info;
+
+       if (quirks == IGNORE_DEVICE)
+               return -ENODEV;
+
        num_rx_buf = (quirks == SINGLE_RX_URB) ? 1 : ACM_NR;
 
        /* handle quirks deadly to normal probing*/
@@ -1675,6 +1679,15 @@ static const struct usb_device_id acm_ids[] = {
        .driver_info = NO_DATA_INTERFACE,
        },
 
+#if IS_ENABLED(CONFIG_INPUT_IMS_PCU)
+       { USB_DEVICE(0x04d8, 0x0082),   /* Application mode */
+       .driver_info = IGNORE_DEVICE,
+       },
+       { USB_DEVICE(0x04d8, 0x0083),   /* Bootloader mode */
+       .driver_info = IGNORE_DEVICE,
+       },
+#endif
+
        /* control interfaces without any protocol set */
        { USB_INTERFACE_INFO(USB_CLASS_COMM, USB_CDC_SUBCLASS_ACM,
                USB_CDC_PROTO_NONE) },