usb:option: prevent the module interface as usb port

The EC20 has more usb interface, so prevent them to as usb
device.
This commit is contained in:
SteveChen
2019-12-17 11:42:53 +08:00
parent f6a175c3e8
commit 20bf1a18b5

View File

@ -2114,7 +2114,7 @@ static int option_probe(struct usb_serial *serial,
if (dev_desc->idVendor == cpu_to_le16(0x2c7c) &&
dev_desc->idProduct == cpu_to_le16(0x0125) &&
iface_desc->bInterfaceClass == 0x04)
serial->interface->cur_altsetting->desc.bInterfaceNumber >= 4)
return -ENODEV;
/* Store the blacklist info so we can use it during attach. */