- if (vendor != -1 && product != -1) {
- info("%s - User specified USB Touch -- Vend:Prod - %x:%x",
- __FUNCTION__, vendor, product);
- }
-
- for (ix = 0; ix < sizeof (mtouchusb_devices) /
- sizeof (struct usb_device_id); ix++) {
- if ((udev->descriptor.idVendor ==
- mtouchusb_devices [ix].idVendor) &&
- (udev->descriptor.idProduct ==
- mtouchusb_devices [ix].idProduct)) {
- valid_device = 1;
- break;
- }
- }
-
- if (udev->descriptor.idVendor == vendor &&
- udev->descriptor.idProduct == product) { /* User specified */
- valid_device = 1;
- }
-
- if (!valid_device) {
- err("%s - No valid device!", __FUNCTION__);
- return -EIO;
- }
-
- if (udev->descriptor.bNumConfigurations != 1) {
- err("%s - Only one device configuration is supported.",
- __FUNCTION__);
- return -EIO;
- }