diff options
author | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2011-11-02 13:30:45 +0100 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2011-12-12 11:48:31 +0200 |
commit | 5bdb1dcc63304a407e70020c1118fca1642bebaa (patch) | |
tree | ee7ee15ec9159b8779cb30e3b9ce8d2d84b516aa /crypto | |
parent | f0f2b2a2db85f99637376caf25e46623af56acad (diff) | |
download | blackbird-op-linux-5bdb1dcc63304a407e70020c1118fca1642bebaa.tar.gz blackbird-op-linux-5bdb1dcc63304a407e70020c1118fca1642bebaa.zip |
usb: dwc3: ep0: handle delayed_status again
Since the re-worked ep0 handling (which uses HW's hints to recognize the ep0
status) we lost the delayed status handling. This is used by the file and mass
storage gadget to gain some extra time so setup its internal status before it
can proceed further requests.
In particular the storage gadget does nothing on USB_REQ_SET_CONFIGURATION but
wakes up a thread which handles the request. If the udc driver continues ep0
handling before the thread did its work then then endpoint is not yet
configured and further requests will fail. Once the gadget is ready, it will
enqueue an empty packet which is used for synchronization.
In order to fix this issue, the patch does the following:
Set ->delayed_status once the delayed_status has been notices and do not
continue on the next XferNotReady event. We will continues ep0 processing once
the gadget enqueued the zero packet for synchronization.
A cleaner approach would be to enforce the gadget to enqueue an empty
(zero) request even for the status phase but this would do for now.
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'crypto')
0 files changed, 0 insertions, 0 deletions