From: peter.chen@freescale.com (Peter Chen)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 01/10] usb: chipidea: udc: zero-length packet is only needed for TX
Date: Wed, 29 Jul 2015 10:42:05 +0800 [thread overview]
Message-ID: <1438137734-27311-2-git-send-email-peter.chen@freescale.com> (raw)
In-Reply-To: <1438137734-27311-1-git-send-email-peter.chen@freescale.com>
The zero-length packet is the sendor tells the receiver that there
is no more data, so it is only needed at the TX side.
Signed-off-by: Peter Chen <peter.chen@freescale.com>
---
drivers/usb/chipidea/udc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/chipidea/udc.c b/drivers/usb/chipidea/udc.c
index 06b7224..51e66a1 100644
--- a/drivers/usb/chipidea/udc.c
+++ b/drivers/usb/chipidea/udc.c
@@ -445,7 +445,7 @@ static int _hardware_enqueue(struct ci_hw_ep *hwep, struct ci_hw_req *hwreq)
rest -= count;
}
- if (hwreq->req.zero && hwreq->req.length
+ if (hwreq->req.zero && hwreq->req.length && hwep->dir == TX
&& (hwreq->req.length % hwep->ep.maxpacket == 0))
add_td_to_list(hwep, hwreq, 0);
--
1.9.1
next prev parent reply other threads:[~2015-07-29 2:42 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-29 2:42 [PATCH 00/10] USB: chipidea misc patches Peter Chen
2015-07-29 2:42 ` Peter Chen [this message]
2015-07-29 2:42 ` [PATCH 02/10] usb: chipidea: define stream mode disable for both roles Peter Chen
2015-07-29 5:08 ` Greg KH
2015-07-29 4:40 ` Peter Chen
2015-07-29 5:10 ` Greg KH
2015-07-29 4:41 ` Peter Chen
2015-07-29 5:51 ` Sascha Hauer
2015-07-29 6:02 ` Sascha Hauer
2015-07-29 2:42 ` [PATCH 03/10] usb: chipidea: imx: add stream mode enable for device mode at imx6sl/imx6sx Peter Chen
2015-07-29 2:42 ` [PATCH 04/10] Doc: usb: ci-hdrc-usb2: add ahb-burst-config for binding doc Peter Chen
2015-07-29 2:42 ` [PATCH 05/10] ARM: imx6: set ahb-burst-config as 0 for USB Peter Chen
2015-07-29 2:42 ` [PATCH 06/10] usb: chipidea: add ahb burst configuration interface Peter Chen
2015-07-29 2:42 ` [PATCH 07/10] usb: chipidea: usbmisc_imx: add unburst setting for imx6 Peter Chen
2015-07-29 8:30 ` Lothar Waßmann
2015-07-29 7:57 ` Peter Chen
2015-07-29 10:19 ` Lothar Waßmann
2015-07-30 2:36 ` Peter Chen
2015-07-29 2:42 ` [PATCH 08/10] Doc: usb: ci-hdrc-usb2: add tx(rx)-burst-config-dword for binding doc Peter Chen
2015-07-29 2:42 ` [PATCH 09/10] ARM: imx6: change default burst size for USB Peter Chen
2015-07-29 2:42 ` [PATCH 10/10] usb: chipidea: add tx/rx burst size configuration interface Peter Chen
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=1438137734-27311-2-git-send-email-peter.chen@freescale.com \
--to=peter.chen@freescale.com \
--cc=linux-arm-kernel@lists.infradead.org \
/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;
as well as URLs for NNTP newsgroup(s).