[PATCH] usb: gadget: cdns3: Fix cdns3_ep_config() by setting ep.maxpacket
Siddharth Vadapalli
s-vadapalli at ti.com
Mon Oct 7 14:21:34 CEST 2024
On Mon, Oct 07, 2024 at 05:37:52PM +0530, Siddharth Vadapalli wrote:
> On Mon, Oct 07, 2024 at 03:02:34PM +0300, Roger Quadros wrote:
>
> Hello Roger,
[...]
> > from include/linux/usb/gadget.h
> >
> > * struct usb_ep - device side representation of USB endpoint
> > ...
> > * @maxpacket:The maximum packet size used on this endpoint. The initial
> > * value can sometimes be reduced (hardware allowing), according to
> > * the endpoint descriptor used to configure the endpoint.
> > * @maxpacket_limit:The maximum packet size value which can be handled by this
> > * endpoint. It's set once by UDC driver when endpoint is initialized, and
> > * should not be changed. Should not be confused with maxpacket.
> >
> > What you want to change is ep->maxpacket and not ep->maxpacket_limit as that is
> > fixed for a particular UDC.
> >
> > how about?
> > priv-ep->endpoint.maxpacket = max_packet_size;
>
> Yes, this is accurate. I will post the v2 patch with this change. Thank
> you for reviewing the patch.
I have implemented your feedback and have posted the v2 patch at:
https://patchwork.ozlabs.org/project/uboot/patch/20241007121927.1680039-1-s-vadapalli@ti.com
Regards,
Siddharth.
More information about the U-Boot
mailing list