Re: [PATCH 5/7] usb: dwc3: ep0: add handling for unaligned OUT transfers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



* Felipe Balbi | 2011-08-29 15:26:36 [+0300]:

>Hi,
Hi,

>On Mon, Aug 29, 2011 at 01:48:14PM +0200, Sebastian Andrzej Siewior wrote:
>> >A better approach might be to introduce a "quirks" field on struct
>> >usb_gadget, as have gadget drivers check for that. Something like:
>> >
>> >	if (gadget->quirks & GADGET_NEEDS_ALIGNED_OUT)
>> >		req->length = gadget->ep0->maxpacket;
>> >	else
>> >		req->length = len;
>> 
>> This is bad because you have to ensure the buffer is large enough. For
>> ep0 the composite framework allocated bMaxPacketSize0 anyway right?
>
>composite has a 1k buffer. The buffer has to be big enough for a big
>load of descriptors.

If so, why not unconditionally queue maxpacket size then? The host does
not see a difference.

Sebastian
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux