Re: [PATCH] usb/fsl_udc: fix dequeuing a request in progress
From: Peter Chen <hidden>
Date: 2011-11-23 03:02:10
On Tue, Nov 22, 2011 at 7:48 PM, Peter Chen [off-list ref] wrote:
quoted
quoted
It seems to can't get the correct qh pointer, you may still need to use below code to get it =A0 =A0 =A0 int i =3D ep_index(ep) * 2 + ep_is_in(ep); =A0 =A0 =A0 struct ep_queue_head *dQH =3D &ep->udc->ep_qh[i];Thanks for trying. =A0 =A0It will be much easier if we can dereference Q=
H from the ep structure. =A0It is really strange that the ep->qh pointer is= not working somehow.
quoted
Seems only ep0-out's qh pointer is assigned at ep structure. At probe: /* setup udc->eps[] for ep0 */ struct_ep_setup(udc_controller, 0, "ep0", 0);quoted
We have initialized it in struct_ep_setup(): =A0 =A0 =A0 =A0ep->qh =3D &udc->ep_qh[index]; Can you do me a favor on investigating why it's failing?
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 ep= 0in at probe, it still can't get the ep0in's qh address through ep structure, as ep0 is always udc->ep[0].
quoted
Thanks, Leo -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@vger.kernel.org More majordomo info at =A0http://vger.kernel.org/majordomo-info.html-- BR, Peter Chen
--=20 BR, Peter Chen