]> git.baikalelectronics.ru Git - kernel.git/commit
usb: dwc3: gadget: Check END_TRANSFER completion
authorThinh Nguyen <Thinh.Nguyen@synopsys.com>
Thu, 19 Dec 2019 02:14:44 +0000 (18:14 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 15 Jan 2020 09:39:23 +0000 (10:39 +0100)
commit9232763d90cbbf8f8076457d7178130e4eb971ab
tree2768ffe8860e0ee2e6d17694262838611ebc9a1a
parentb352f107059e64b95fd35c8c5fd11da740537021
usb: dwc3: gadget: Check END_TRANSFER completion

While the END_TRANSFER command is sent but not completed, any request
dequeue during this time will cause the driver to issue the END_TRANSFER
command. The driver needs to submit the command only once to stop the
controller from processing further. The controller may take more time to
process the same command multiple times unnecessarily. Let's add a flag
DWC3_EP_END_TRANSFER_PENDING to check for this condition.

Fixes: c369f6d54bd1 ("usb: dwc3: gadget: remove DWC3_EP_END_TRANSFER_PENDING")
Signed-off-by: Thinh Nguyen <thinhn@synopsys.com>
Signed-off-by: Felipe Balbi <balbi@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/dwc3/core.h
drivers/usb/dwc3/ep0.c
drivers/usb/dwc3/gadget.c