From: Kishon Vijay Abraham I <kishon@ti.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 06/11] usb: dwc3: add a workaround for too small OUT requests
Date: Mon, 23 Feb 2015 19:54:43 +0530 [thread overview]
Message-ID: <54EB382B.20709@ti.com> (raw)
In-Reply-To: <1424700152-8554-7-git-send-email-l.majewski@samsung.com>
Hi,
On Monday 23 February 2015 07:32 PM, Lukasz Majewski wrote:
> From: Marek Szyprowski <m.szyprowski@samsung.com>
>
> DWC3 hangs on OUT requests smaller than maxpacket size,
> so HACK the request length to be at least equal to maxpacket size.
Curious to know using which gadget this issue was seen.
Thanks
Kishon
>
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
> drivers/usb/dwc3/gadget.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c
> index 01bc83b..f8a75d3 100644
> --- a/drivers/usb/dwc3/gadget.c
> +++ b/drivers/usb/dwc3/gadget.c
> @@ -974,6 +974,12 @@ static int __dwc3_gadget_ep_queue(struct dwc3_ep *dep, struct dwc3_request *req)
> req->direction = dep->direction;
> req->epnum = dep->number;
>
> + /* DWC3 hangs on OUT requests smaller than maxpacket size,
> + so HACK the request length */
> + if (dep->direction == 0 &&
> + req->request.length < dep->endpoint.maxpacket)
> + req->request.length = dep->endpoint.maxpacket;
> +
> /*
> * We only add to our list of requests now and
> * start consuming the list once we get XferNotReady
>
next prev parent reply other threads:[~2015-02-23 14:24 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-23 14:02 [U-Boot] [PATCH 00/11] usb: dwc3: Fixes and improvements for DWC3 driver Lukasz Majewski
2015-02-23 14:02 ` [U-Boot] [PATCH 01/11] usb: composite: Add .reset callback to usb_gadget_driver structure Lukasz Majewski
2015-02-23 14:02 ` [U-Boot] [PATCH 02/11] usb: dwc3: linux-compat: Fix: Adding missing include files Lukasz Majewski
2015-02-23 14:12 ` Kishon Vijay Abraham I
2015-02-23 14:02 ` [U-Boot] [PATCH 03/11] usb: dwc3: Add BIT() macro Lukasz Majewski
2015-02-23 15:04 ` Marek Vasut
2015-02-23 14:02 ` [U-Boot] [PATCH 04/11] usb: dwc3: make dwc3_set_mode to static Lukasz Majewski
2015-02-23 14:18 ` Kishon Vijay Abraham I
2015-02-23 14:02 ` [U-Boot] [PATCH 05/11] usb: dwc3: Set usbdrd phy ctrl and mode in dwc3 core Lukasz Majewski
2015-02-23 14:23 ` Kishon Vijay Abraham I
2015-02-23 14:02 ` [U-Boot] [PATCH 06/11] usb: dwc3: add a workaround for too small OUT requests Lukasz Majewski
2015-02-23 14:24 ` Kishon Vijay Abraham I [this message]
2015-02-23 14:44 ` Lukasz Majewski
2015-02-24 13:23 ` Kishon Vijay Abraham I
2015-02-23 14:02 ` [U-Boot] [PATCH 07/11] usb: dwc3: gadget: add common endpoint configuration for dwc3 udc driver Lukasz Majewski
2015-02-23 14:02 ` [U-Boot] [PATCH 08/11] usb: dwc3: optimize interrupt loop Lukasz Majewski
2015-02-23 14:02 ` [U-Boot] [PATCH 09/11] usb: dwc3: gadget: Set all ctrl fields of Transfer Control Blocks (TRB) to be LST Lukasz Majewski
2015-02-23 14:02 ` [U-Boot] [PATCH 10/11] usb: dwc3: gadget: Set non EP0 max packet limit to 512B Lukasz Majewski
2015-02-23 14:02 ` [U-Boot] [PATCH 11/11] usb: dwc3: Correct clean up code for requests Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 00/14] usb: dwc3: Fixes and improvements for DWC3 driver Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 01/14] usb: board: samsung: Add default board_usb_cleanup() definition for Exynos SoCs Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 02/14] usb: board: goni: Add default board_usb_cleanup() definition for Goni board Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 03/14] usb: gadget: UMS: Invoke board specific USB cleanup interface Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 04/14] usb: gadget: thor: " Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 05/14] usb: composite: Add .reset callback to usb_gadget_driver structure Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 06/14] usb: dwc3: Remove BIT(x) macro from DWC3's gadget code Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 07/14] usb: dwc3: make dwc3_set_mode to static Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 08/14] usb: dwc3: add a workaround for too small OUT requests Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 09/14] usb: dwc3: gadget: add common endpoint configuration for dwc3 udc driver Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 10/14] usb: dwc3: optimize interrupt loop Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 11/14] usb: dwc3: gadget: Set all ctrl fields of Transfer Control Blocks (TRB) to be LST Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 12/14] usb: dwc3: gadget: Set non EP0 max packet limit to 512B Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 13/14] usb: dwc3: Correct clean up code for requests Lukasz Majewski
2015-03-03 16:32 ` [U-Boot] [PATCH 14/14] usb: gadget: thor: Claim EP after allocating it in thor gadget Lukasz Majewski
2015-03-03 22:26 ` [U-Boot] [PATCH 00/14] usb: dwc3: Fixes and improvements for DWC3 driver Marek Vasut
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=54EB382B.20709@ti.com \
--to=kishon@ti.com \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox