diff options
Diffstat (limited to 'drivers/usb/input/usbmouse.c')
-rw-r--r-- | drivers/usb/input/usbmouse.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/usb/input/usbmouse.c b/drivers/usb/input/usbmouse.c index cbbbea332ed7..68a55642c082 100644 --- a/drivers/usb/input/usbmouse.c +++ b/drivers/usb/input/usbmouse.c | |||
@@ -126,9 +126,7 @@ static int usb_mouse_probe(struct usb_interface *intf, const struct usb_device_i | |||
126 | return -ENODEV; | 126 | return -ENODEV; |
127 | 127 | ||
128 | endpoint = &interface->endpoint[0].desc; | 128 | endpoint = &interface->endpoint[0].desc; |
129 | if (!(endpoint->bEndpointAddress & USB_DIR_IN)) | 129 | if (!usb_endpoint_is_int_in(endpoint)) |
130 | return -ENODEV; | ||
131 | if ((endpoint->bmAttributes & USB_ENDPOINT_XFERTYPE_MASK) != USB_ENDPOINT_XFER_INT) | ||
132 | return -ENODEV; | 130 | return -ENODEV; |
133 | 131 | ||
134 | pipe = usb_rcvintpipe(dev, endpoint->bEndpointAddress); | 132 | pipe = usb_rcvintpipe(dev, endpoint->bEndpointAddress); |