Skip to content
Commit a26d3c2f authored by Tomasz Moń's avatar Tomasz Moń Committed by Benjamin Cabé
Browse files

drivers: udc_dwc2: Workaround endpoint disable race condition



Endpoint disable function is racing against bus traffic. If the bus
traffic leads to transfer completion immediately before the endpoint
disable is executed, then the transfer complete interrupt will remain
set when the endpoint is disabled. For OUT endpoints this leads to "No
buffer for ep" errors, while for IN endpoint this can lead to double
buffer pull which causes assertion failure.

The proper solution would be to change endpoint disable to not actually
wait for the individual events (and accept that the endpoint may not
need to be disabled because the transfer can just finish). For the time
being workaround the issue by clearing XferCompl bit on endpoint
disable.

Signed-off-by: default avatarTomasz Moń <tomasz.mon@nordicsemi.no>
parent c19d34c5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment