Commit 31a2f5a7 authored by Felipe Balbi's avatar Felipe Balbi

usb: dwc3: gadget: init req->{direction,epnum} from alloc_request()

We dont' need to touch req->direction or req->epnum from
ep_queue(). It's enough that we initialize both fields from
alloc_request() and just keep them for the entire lifetime of the
request.

No functional changes.
Signed-off-by: default avatarFelipe Balbi <felipe.balbi@linux.intel.com>
parent d7ca7e18
...@@ -837,6 +837,7 @@ static struct usb_request *dwc3_gadget_ep_alloc_request(struct usb_ep *ep, ...@@ -837,6 +837,7 @@ static struct usb_request *dwc3_gadget_ep_alloc_request(struct usb_ep *ep,
if (!req) if (!req)
return NULL; return NULL;
req->direction = dep->direction;
req->epnum = dep->number; req->epnum = dep->number;
req->dep = dep; req->dep = dep;
...@@ -1285,8 +1286,6 @@ static int __dwc3_gadget_ep_queue(struct dwc3_ep *dep, struct dwc3_request *req) ...@@ -1285,8 +1286,6 @@ static int __dwc3_gadget_ep_queue(struct dwc3_ep *dep, struct dwc3_request *req)
req->request.actual = 0; req->request.actual = 0;
req->request.status = -EINPROGRESS; req->request.status = -EINPROGRESS;
req->direction = dep->direction;
req->epnum = dep->number;
trace_dwc3_ep_queue(req); trace_dwc3_ep_queue(req);
......
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