USB: Gadget: Webcam: Return correct result of bind
authorJassi Brar <[email protected]>
Fri, 24 Jun 2011 18:47:26 +0000 (00:17 +0530)
committerGreg Kroah-Hartman <[email protected]>
Fri, 1 Jul 2011 21:45:42 +0000 (14:45 -0700)
The config bind was reported success even if usb_add_function
failed. Fix the return value.

Signed-off-by: Jassi Brar <[email protected]>
Acked-by: Laurent Pinchart <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
drivers/usb/gadget/f_uvc.c

index df74d0311910bddb967185215481743844cec281..7a8b9aa4aea5468e8ce92b0d2f8184d409509721 100644 (file)
@@ -651,7 +651,7 @@ uvc_bind_config(struct usb_configuration *c,
        if (ret)
                kfree(uvc);
 
-       return 0;
+       return ret;
 
 error:
        kfree(uvc);