aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/misc/phidgetkit.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/misc/phidgetkit.c')
-rw-r--r--drivers/usb/misc/phidgetkit.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/usb/misc/phidgetkit.c b/drivers/usb/misc/phidgetkit.c
index abb4dcd811ac..9110793f81d3 100644
--- a/drivers/usb/misc/phidgetkit.c
+++ b/drivers/usb/misc/phidgetkit.c
@@ -551,7 +551,7 @@ static int interfacekit_probe(struct usb_interface *intf, const struct usb_devic
551 return -ENODEV; 551 return -ENODEV;
552 552
553 endpoint = &interface->endpoint[0].desc; 553 endpoint = &interface->endpoint[0].desc;
554 if (!(endpoint->bEndpointAddress & 0x80)) 554 if (!usb_endpoint_dir_in(endpoint))
555 return -ENODEV; 555 return -ENODEV;
556 /* 556 /*
557 * bmAttributes 557 * bmAttributes
@@ -650,8 +650,7 @@ out2:
650 device_remove_file(kit->dev, &dev_output_attrs[i]); 650 device_remove_file(kit->dev, &dev_output_attrs[i]);
651out: 651out:
652 if (kit) { 652 if (kit) {
653 if (kit->irq) 653 usb_free_urb(kit->irq);
654 usb_free_urb(kit->irq);
655 if (kit->data) 654 if (kit->data)
656 usb_buffer_free(dev, URB_INT_SIZE, kit->data, kit->data_dma); 655 usb_buffer_free(dev, URB_INT_SIZE, kit->data, kit->data_dma);
657 if (kit->dev) 656 if (kit->dev)