From 28f75f4db1e5ea1366375b2a6c40d66659e0e7ec Mon Sep 17 00:00:00 2001 From: Jassi Brar Date: Sat, 25 Jun 2011 00:17:26 +0530 Subject: [PATCH] USB: Gadget: Webcam: Return correct result of bind The config bind was reported success even if usb_add_function failed. Fix the return value. Signed-off-by: Jassi Brar Acked-by: Laurent Pinchart Signed-off-by: Greg Kroah-Hartman --- drivers/usb/gadget/f_uvc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/gadget/f_uvc.c b/drivers/usb/gadget/f_uvc.c index df74d0311910..7a8b9aa4aea5 100644 --- a/drivers/usb/gadget/f_uvc.c +++ b/drivers/usb/gadget/f_uvc.c @@ -651,7 +651,7 @@ uvc_bind_config(struct usb_configuration *c, if (ret) kfree(uvc); - return 0; + return ret; error: kfree(uvc); -- 2.20.1