Commit 734c58ae authored by Gustavo A. R. Silva's avatar Gustavo A. R. Silva Committed by Peter Chen

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: default avatarGustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: default avatarPeter Chen <peter.chen@nxp.com>
parent 5771a8c0
...@@ -944,7 +944,6 @@ isr_setup_status_complete(struct usb_ep *ep, struct usb_request *req) ...@@ -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) static int isr_setup_status_phase(struct ci_hdrc *ci)
{ {
int retval;
struct ci_hw_ep *hwep; struct ci_hw_ep *hwep;
/* /*
...@@ -960,9 +959,7 @@ static int isr_setup_status_phase(struct ci_hdrc *ci) ...@@ -960,9 +959,7 @@ static int isr_setup_status_phase(struct ci_hdrc *ci)
ci->status->context = ci; ci->status->context = ci;
ci->status->complete = isr_setup_status_complete; ci->status->complete = isr_setup_status_complete;
retval = _ep_queue(&hwep->ep, ci->status, GFP_ATOMIC); return _ep_queue(&hwep->ep, ci->status, GFP_ATOMIC);
return retval;
} }
/** /**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment