Skip to content

Commit

Permalink
usb: dwc3: gadget: reduce scope of ret variable
Browse files Browse the repository at this point in the history
We can declare it inside list_for_each_entry_safe() loop and reduce
its scope.

Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
  • Loading branch information
Felipe Balbi committed May 21, 2018
1 parent 6afbdb5 commit fee73e6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/usb/dwc3/gadget.c
Original file line number Diff line number Diff line change
Expand Up @@ -2313,10 +2313,10 @@ static void dwc3_gadget_ep_cleanup_completed_requests(struct dwc3_ep *dep,
{
struct dwc3_request *req;
struct dwc3_request *tmp;
int ret = 0;

list_for_each_entry_safe(req, tmp, &dep->started_list, list) {
unsigned length;
int ret;

length = req->request.length;
if (req->num_pending_sgs)
Expand Down

0 comments on commit fee73e6

Please sign in to comment.