• Thinh Nguyen's avatar
    usb: dwc3: gadget: Remove unnecessary checks · 8411993e
    Thinh Nguyen authored
    Remove 2 unnecessary checks:
    1) A request in the started_list must have its trb field set. So
    checking for req->trb is unnecessary.
    
    2) An endpoint must have started (and have not ended) for the request to
    still be in the started_list. There's no point to check if the endpoint
    is started. We had this check because previously the driver didn't
    handle the endpoint's started/ended flags for END_TRANSFER command
    properly. See commit 9f45581f
    
     ("usb: dwc3: gadget: early giveback
    if End Transfer already completed").
    Signed-off-by: default avatarThinh Nguyen <thinhn@synopsys.com>
    Signed-off-by: default avatarFelipe Balbi <balbi@kernel.org>
    8411993e
gadget.c 89.1 KB