usb: usbkbd free urb cleanup
authorMariusz Kozlowski <m.kozlowski@tuxland.pl>
Wed, 8 Nov 2006 14:35:58 +0000 (15:35 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 1 Dec 2006 22:23:33 +0000 (14:23 -0800)
- usb_free_urb() cleanup

Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/input/usbkbd.c

index b6c2ba7..dac8864 100644 (file)
@@ -208,10 +208,8 @@ static int usb_kbd_alloc_mem(struct usb_device *dev, struct usb_kbd *kbd)
 
 static void usb_kbd_free_mem(struct usb_device *dev, struct usb_kbd *kbd)
 {
-       if (kbd->irq)
-               usb_free_urb(kbd->irq);
-       if (kbd->led)
-               usb_free_urb(kbd->led);
+       usb_free_urb(kbd->irq);
+       usb_free_urb(kbd->led);
        if (kbd->new)
                usb_buffer_free(dev, 8, kbd->new, kbd->new_dma);
        if (kbd->cr)