mirror of
https://github.com/torvalds/linux.git
synced 2026-11-07 06:17:02 +01:00
usb: gadget: dummy_hcd: fix SuperSpeed ep0 maxpacket
For USB_SPEED_SUPER, dummy_hcd sets ep0 maxpacket to 9.
That is incorrect for SuperSpeed ep0 and breaks short packet handling
in control transfer tests.
Set ep0 maxpacket to 512 for SuperSpeed.
Fixes: 1cd8fd2887 ("usb: gadget: dummy_hcd: add SuperSpeed support")
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Igor Skalkin <igor.skalkin@oss.qualcomm.com>
Link: https://patch.msgid.link/20260812081910.6821-2-igor.skalkin@oss.qualcomm.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
cb3b441f26
commit
e68f245bcb
|
|
@ -918,7 +918,7 @@ static int dummy_set_selfpowered(struct usb_gadget *_gadget, int value)
|
|||
static void dummy_udc_update_ep0(struct dummy *dum)
|
||||
{
|
||||
if (dum->gadget.speed == USB_SPEED_SUPER)
|
||||
dum->ep[0].ep.maxpacket = 9;
|
||||
dum->ep[0].ep.maxpacket = 512;
|
||||
else
|
||||
dum->ep[0].ep.maxpacket = 64;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user