usb: dwc3: ep0: fix DMA starvation by assigning req->trb on ep0
authorFelipe Balbi <felipe.balbi@linux.intel.com>
Mon, 11 Sep 2017 07:45:12 +0000 (10:45 +0300)
committerFelipe Balbi <felipe.balbi@linux.intel.com>
Mon, 18 Sep 2017 10:30:30 +0000 (13:30 +0300)
commit55168470835688e5da5828cdcf1b1498d7baadb1
tree99db634867dcdabcfaed22789bdee863ec06d0b2
parent2bd6bf03f4c1c59381d62c61d03f6cc3fe71f66e
usb: dwc3: ep0: fix DMA starvation by assigning req->trb on ep0

If we don't assign a TRB to ep0 requests, we won't be able to unmap
the request later on resulting in starvation of DMA resources.

Fixes: 4a71fcb8ac5f ("usb: dwc3: gadget: only unmap requests from DMA if mapped")
Reported-by: Thinh Nguyen <Thinh.Nguyen@synopsys.com>
Tested-by: Thinh Nguyen <Thinh.Nguyen@synopsys.com>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
drivers/usb/dwc3/ep0.c