summaryrefslogtreecommitdiff
path: root/drivers/usb
diff options
context:
space:
mode:
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>2013-04-06 12:39:49 +0800
committerFelipe Balbi <balbi@ti.com>2013-04-23 14:09:57 +0300
commit6ee3e8e63d77bb4ed686f0c92dc7aa1a8e13fefb (patch)
tree4591baf4fbe676b7445aa60b3ed09067ce869f09 /drivers/usb
parent9b192de60b5a584ee4ed967fb6758773c75e4643 (diff)
usb: gadget: f_obex: fix error return code in obex_bind()
Fix to return a negative error code from the error handling case instead of 0, as returned elsewhere in this function. Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/gadget/f_obex.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/usb/gadget/f_obex.c b/drivers/usb/gadget/f_obex.c
index 29a348a2a294..8aa2be5329bc 100644
--- a/drivers/usb/gadget/f_obex.c
+++ b/drivers/usb/gadget/f_obex.c
@@ -348,6 +348,7 @@ static int obex_bind(struct usb_configuration *c, struct usb_function *f)
/* allocate instance-specific endpoints */
+ status = -ENODEV;
ep = usb_ep_autoconfig(cdev->gadget, &obex_fs_ep_in_desc);
if (!ep)
goto fail;