// Determine if a driver exists for this device - only look at the
// first interface of the first configuration.
struct usb_interface_descriptor *iface = (void*)(&config[1]);
- if ((iface->bInterfaceClass != USB_CLASS_HID
- || iface->bInterfaceSubClass != USB_INTERFACE_SUBCLASS_BOOT
- || iface->bInterfaceProtocol != USB_INTERFACE_PROTOCOL_KEYBOARD)
- && (iface->bInterfaceClass != USB_CLASS_MASS_STORAGE)
- && (iface->bInterfaceClass != USB_CLASS_HUB))
+ if (iface->bInterfaceClass != USB_CLASS_HID
+ && iface->bInterfaceClass != USB_CLASS_MASS_STORAGE
+ && iface->bInterfaceClass != USB_CLASS_HUB)
// Not a supported device.
goto fail;
else if (iface->bInterfaceClass == USB_CLASS_MASS_STORAGE)
ret = usb_msc_init(pipe, iface, imax);
else
- ret = usb_keyboard_init(pipe, iface, imax);
+ ret = usb_hid_init(pipe, iface, imax);
if (ret)
goto fail;
dprintf(3, "init usb\n");
- usb_keyboard_setup();
+ usb_hid_setup();
// Look for USB controllers
int ehcibdf = -1;