diff options
author | Gustavo A. R. Silva <garsilva@embeddedor.com> | 2017-07-09 21:08:20 -0500 |
---|---|---|
committer | Peter Chen <peter.chen@nxp.com> | 2017-07-19 09:49:11 +0800 |
commit | 734c58aefcc48f888e74fd082a0a2eca167e8816 (patch) | |
tree | 35e547c6759ea7dbb6b3f2453875bf52115b06c3 /drivers/usb | |
parent | 5771a8c08880cdca3bfb4a3fc6d309d6bba20877 (diff) | |
download | linux-734c58aefcc48f888e74fd082a0a2eca167e8816.tar.gz linux-734c58aefcc48f888e74fd082a0a2eca167e8816.tar.bz2 linux-734c58aefcc48f888e74fd082a0a2eca167e8816.zip |
usb: chipidea: udc: compress return logic into line
Simplify return logic to avoid unnecessary variable assignment.
This issue was detected using Coccinelle and the following
semantic patch:
@@
local idexpression ret;
expression e;
@@
-ret =
+return
e;
-return ret;
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Peter Chen <peter.chen@nxp.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/chipidea/udc.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/usb/chipidea/udc.c b/drivers/usb/chipidea/udc.c index d68b125796f9..6502c13331e8 100644 --- a/drivers/usb/chipidea/udc.c +++ b/drivers/usb/chipidea/udc.c @@ -944,7 +944,6 @@ isr_setup_status_complete(struct usb_ep *ep, struct usb_request *req) */ static int isr_setup_status_phase(struct ci_hdrc *ci) { - int retval; struct ci_hw_ep *hwep; /* @@ -960,9 +959,7 @@ static int isr_setup_status_phase(struct ci_hdrc *ci) ci->status->context = ci; ci->status->complete = isr_setup_status_complete; - retval = _ep_queue(&hwep->ep, ci->status, GFP_ATOMIC); - - return retval; + return _ep_queue(&hwep->ep, ci->status, GFP_ATOMIC); } /** |