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

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

index e4971d6aaafb323d5d931c99fe0f25c10d072906..c703f73e16550211652c86fc1d37be2e30bead47 100644 (file)
@@ -704,9 +704,7 @@ static void auerbuf_free (pauerbuf_t bp)
 {
        kfree(bp->bufp);
        kfree(bp->dr);
-       if (bp->urbp) {
-               usb_free_urb(bp->urbp);
-       }
+       usb_free_urb(bp->urbp);
        kfree(bp);
 }
 
@@ -1155,8 +1153,7 @@ static void auerswald_int_release (pauerswald_t cp)
         dbg ("auerswald_int_release");
 
         /* stop the int endpoint */
-        if (cp->inturbp)
-                usb_kill_urb (cp->inturbp);
+       usb_kill_urb (cp->inturbp);
 
         /* deallocate memory */
         auerswald_int_free (cp);