提交 fee73e61 编写于 作者: F Felipe Balbi

usb: dwc3: gadget: reduce scope of ret variable

We can declare it inside list_for_each_entry_safe() loop and reduce
its scope.
Signed-off-by: NFelipe Balbi <felipe.balbi@linux.intel.com>
上级 6afbdb57
...@@ -2313,10 +2313,10 @@ static void dwc3_gadget_ep_cleanup_completed_requests(struct dwc3_ep *dep, ...@@ -2313,10 +2313,10 @@ static void dwc3_gadget_ep_cleanup_completed_requests(struct dwc3_ep *dep,
{ {
struct dwc3_request *req; struct dwc3_request *req;
struct dwc3_request *tmp; struct dwc3_request *tmp;
int ret = 0;
list_for_each_entry_safe(req, tmp, &dep->started_list, list) { list_for_each_entry_safe(req, tmp, &dep->started_list, list) {
unsigned length; unsigned length;
int ret;
length = req->request.length; length = req->request.length;
if (req->num_pending_sgs) if (req->num_pending_sgs)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册