summaryrefslogtreecommitdiffstats
path: root/drivers/usb/dwc3/gadget.c
diff options
context:
space:
mode:
authorPratyush Anand <pratyush.anand@st.com>2013-01-14 15:59:33 +0530
committerFelipe Balbi <balbi@ti.com>2013-01-18 14:28:36 +0200
commit15f86bde29f0fdfb877d9c753547fa2e2f5ef1fe (patch)
tree7708fd09156f64618bc33a4a8ab1cf9d77091cbb /drivers/usb/dwc3/gadget.c
parent7efea86c2868b8fd9df65e589e33aebe498ce21d (diff)
usb: dwc3: gadget: correct return from ep_queue
Its better to return from each if condition as they are mutually exclusive. Signed-off-by: Pratyush Anand <pratyush.anand@st.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/dwc3/gadget.c')
-rw-r--r--drivers/usb/dwc3/gadget.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c
index 356a5a2af75..c4ffb3557d6 100644
--- a/drivers/usb/dwc3/gadget.c
+++ b/drivers/usb/dwc3/gadget.c
@@ -1097,6 +1097,7 @@ static int __dwc3_gadget_ep_queue(struct dwc3_ep *dep, struct dwc3_request *req)
if (ret && ret != -EBUSY)
dev_dbg(dwc->dev, "%s: failed to kick transfers\n",
dep->name);
+ return ret;
}
/*
@@ -1113,6 +1114,7 @@ static int __dwc3_gadget_ep_queue(struct dwc3_ep *dep, struct dwc3_request *req)
if (ret && ret != -EBUSY)
dev_dbg(dwc->dev, "%s: failed to kick transfers\n",
dep->name);
+ return ret;
}
return 0;