usb: dwc3: gadget: assign resource_index inside get_transfer_index()
Instead of returning resource index number just to assign it to a field inside 'dep' which was passed as argument, we can assing dep->resource_index from inside dwc3_gadget_ep_get_transfer_index() itself. Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
This commit is contained in:
@@ -79,7 +79,7 @@ static int dwc3_ep0_start_trans(struct dwc3_ep *dep)
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
||||
dep->resource_index = dwc3_gadget_ep_get_transfer_index(dep);
|
||||
dwc3_gadget_ep_get_transfer_index(dep);
|
||||
dwc->ep0_next_event = DWC3_EP0_COMPLETE;
|
||||
|
||||
return 0;
|
||||
|
Reference in New Issue
Block a user