• Thinh Nguyen's avatar
    usb: dwc3: gadget: END_TRANSFER before CLEAR_STALL command · d97c78a1
    Thinh Nguyen authored
    According the programming guide (for all DWC3 IPs), when the driver
    handles ClearFeature(halt) request, it should issue CLEAR_STALL command
    _after_ the END_TRANSFER command completes. The END_TRANSFER command may
    take some time to complete. So, delay the ClearFeature(halt) request
    control status stage and wait for END_TRANSFER command completion
    interrupt. Only after END_TRANSFER command completes that the driver
    may issue CLEAR_STALL command.
    
    Cc: stable@vger.kernel.org
    Fixes: cb11ea56 ("usb: dwc3: gadget: Properly handle ClearFeature(halt)")
    Signed-off-by: default avatarThinh Nguyen <thinhn@synopsys.com>
    Signed-off-by: default avatarFelipe Balbi <balbi@kernel.org>
    d97c78a1
core.h 48.6 KB