usb: dwc3: gadget: Wait for transfer completion
authorThinh Nguyen <Thinh.Nguyen@synopsys.com>
Wed, 6 May 2020 02:46:57 +0000 (19:46 -0700)
committerFelipe Balbi <balbi@kernel.org>
Mon, 25 May 2020 08:09:41 +0000 (11:09 +0300)
commite0d19563eb6c191ca5539789173fb0e8fc5e69ed
tree0f649dfb131a75dddd8459f43ecc7db1766f83e4
parent3eaecd0c2333aa9eeefce2ff130c9323cde53178
usb: dwc3: gadget: Wait for transfer completion

If a transfer is in-progress, any new request should not kick off
another transfer. The driver needs to wait for the current transfer to
complete before starting off the next transfer. Introduce a new flag
DWC3_EP_WAIT_TRANSFER_COMPLETE for this.

Signed-off-by: Thinh Nguyen <thinhn@synopsys.com>
Signed-off-by: Felipe Balbi <balbi@kernel.org>
drivers/usb/dwc3/core.h
drivers/usb/dwc3/gadget.c