patch "usb: gadget: udc: renesas_usb3: fix maxpacket size of ep0" added to usb-linus
Subsystems (2)
This is a note to let you know that I've just added the patch titled
usb: gadget: udc: renesas_usb3: fix maxpacket size of ep0
to my usb git tree which can be found at
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git
in the usb-linus branch.
The patch will show up in the next release of the linux-next tree (usually sometime within the next 24 hours during the week.)
The patch will hopefully also be merged in Linus's tree for the next -rc kernel release.
If you have any questions about this process, please let me know.
Quoted 1 line
From
dfe1a51d2a36647f74cbad478801efa7cf394376Mon Sep 17 00:00:00 2001
From: Yoshihiro Shimoda <[email protected]>
Date: Fri, 3 Aug 2018 12:12:46 +0900
Subject: usb: gadget: udc: renesas_usb3: fix maxpacket size of ep0
This patch fixes an issue that maxpacket size of ep0 is incorrect for SuperSpeed. Otherwise, CDC NCM class with SuperSpeed doesn't work correctly on this driver because its control read data size is more than 64 bytes.
--- drivers/usb/gadget/udc/renesas_usb3.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/usb/gadget/udc/renesas_usb3.c +4 -1
@@ -812,12 +812,15 @@ static void usb3_irq_epc_int_1_speed(struct renesas_usb3 *usb3)switch (speed) {case USB_STA_SPEED_SS : usb3->gadget.speed =USB_SPEED_SUPER ; + usb3->gadget.ep0->maxpacket =USB3_EP0_SS_MAX_PACKET_SIZE ;break ;case USB_STA_SPEED_HS : usb3->gadget.speed =USB_SPEED_HIGH ; + usb3->gadget.ep0->maxpacket =USB3_EP0_HSFS_MAX_PACKET_SIZE ;break ;case USB_STA_SPEED_FS : usb3->gadget.speed =USB_SPEED_FULL ; + usb3->gadget.ep0->maxpacket =USB3_EP0_HSFS_MAX_PACKET_SIZE ;break ;default : usb3->gadget.speed =USB_SPEED_UNKNOWN ;
@@ -2513,7 +2516,7 @@ static int renesas_usb3_init_ep(struct renesas_usb3 *usb3, struct device *dev,/* for control pipe */ usb3->gadget.ep0 = &usb3_ep->ep;usb_ep_set_maxpacket_limit (&usb3_ep->ep, -USB3_EP0_HSFS_MAX_PACKET_SIZE ); +USB3_EP0_SS_MAX_PACKET_SIZE ); usb3_ep->ep.caps.type_control = true; usb3_ep->ep.caps.dir_in = true; usb3_ep->ep.caps.dir_out = true;
Signature · 1 line
2.18.0