summaryrefslogtreecommitdiff
path: root/include/linux/debugobjects.h
diff options
context:
space:
mode:
authorMayank Rana <mrana@codeaurora.org>2015-11-06 15:11:46 -0800
committerDavid Keitel <dkeitel@codeaurora.org>2016-03-22 11:06:58 -0700
commitcda82d5273898db9e5f44fbd7ac320851bfc372d (patch)
tree9b3f077501df6d355fbe9d2ab9372134615d2634 /include/linux/debugobjects.h
parent869c733233e0f449e82764b676f2172bf68bba09 (diff)
usb: dwc3: Clear pending events when it is bigger than event buffer size
Currently there exists a race condition between dwc3_gadget_run_stop() and dwc3 gadget interrupt handling. run_stop() could get cleared and set again in between hard IRQ and threaded IRQ contexts, the DWC3_GEVNTCOUNT could first get set to 0, and then written again in the threaded handler with a non-zero value. Writing back to this register will cause hardware to decrement the value, and since it is 0 will result in a high unsigned value (~65k). To handle this condition mark received events as processed and return IRQ_HANDLED if events count is bigger than event buffer size. Note that the root cause of this condition will be addressed in another patch that prevents the race by synchronizing the hard and threaded interrupt handlers with dwc3_gadget_run_stop() getting called asynchronously. Change-Id: I4d6ade8243867885f26876a5233a8456a7e8bf42 Signed-off-by: Mayank Rana <mrana@codeaurora.org>
Diffstat (limited to 'include/linux/debugobjects.h')
0 files changed, 0 insertions, 0 deletions