[PATCH] usb/fsl_udc: fix dequeuing a request in progress

Felipe Balbi balbi at ti.com
Thu Nov 24 20:32:09 EST 2011


On Wed, Nov 23, 2011 at 08:20:54AM +0000, Li Yang-R58472 wrote:
> >Leo, I have debugged this issue at my board just now, the reason of
> >failure is we only have one ep struct for ep0, so when talking about ep0,
> >it always pointers to udc->ep[0]. So even we initialize the current qh
> >address for ep0in at probe, it still can't get the ep0in's qh address
> >through ep structure, as ep0 is always udc->ep[0].
> 
> Oops.  I forgot the fact that we used a single ep structure to handle
> both IN and OUT ep0 because the gadget layer only knows about one ep0
> structure.

the gadget framework knows about USB endpoints which are bidirectional
logical entities. One USB endpoint is composed of two unidirectional HW
endpoints.

> I guess currently we have no other way out unless the gadget layer do
> honor ep0 with direction.  IMHO, it is a limitation to current gadget
> APIs that each udc driver need to take too much care of the protocol
> related stuff on ep0.

indeed, if you can come up with a sensible patch we're here to review
;-)

-- 
balbi
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20111124/0ea659b4/attachment.pgp>


More information about the Linuxppc-dev mailing list