All of lore.kernel.org
 help / color / mirror / Atom feed
From: Maxime Ripard <maxime@cerno.tech>
To: "Peng Fan (OSS)" <peng.fan@oss.nxp.com>
Cc: u-boot@lists.denx.de, Andre Przywara <andre.przywara@arm.com>,
	Peng Fan <peng.fan@nxp.com>, Li Jun <jun.li@nxp.com>,
	Marek Vasut <marex@denx.de>, Tom Rini <trini@konsulko.com>,
	Miquel Raynal <miquel.raynal@bootlin.com>,
	Jagan Teki <jagan@amarulasolutions.com>
Subject: Re: [PATCH 03/12] Revert "usb: gadget: fastboot: use correct max packet size"
Date: Sat, 3 Jul 2021 15:47:11 +0200	[thread overview]
Message-ID: <20210703134711.iyctnqb2wxomtj37@gilmour> (raw)
In-Reply-To: <aa2a619a-c82d-5839-5be1-9c3cde300550@oss.nxp.com>

Hi Peng,

On Tue, Jun 29, 2021 at 10:27:27AM +0800, Peng Fan (OSS) wrote:
> Maxime
> 
> On 2021/6/25 21:05, Maxime Ripard wrote:
> > This reverts commit 27c9141b1114fd5721437abbb1c694e45e765f19.
> > ---
> >   drivers/usb/gadget/f_fastboot.c | 2 +-
> >   1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/drivers/usb/gadget/f_fastboot.c b/drivers/usb/gadget/f_fastboot.c
> > index 8ba55aab9f8f..1fcffaf9dd26 100644
> > --- a/drivers/usb/gadget/f_fastboot.c
> > +++ b/drivers/usb/gadget/f_fastboot.c
> > @@ -427,7 +427,7 @@ static unsigned int rx_bytes_expected(struct usb_ep *ep)
> >   {
> >   	int rx_remain = fastboot_data_remaining();
> >   	unsigned int rem;
> > -	unsigned int maxpacket = usb_endpoint_maxp(ep->desc);
> > +	unsigned int maxpacket = ep->maxpacket;
> 
> Have you ever checked what's the value here of ep->maxpacket and
> usb_endpoint_maxp(ep->desc); in your failure case?

ep->maxpacket is 512, usb_endpoint_maxp(ep->desc) is 18277.

It might just be that there's a bug somewhere else that is covered by
the fact that we wouldn't get any transfer longer than 512 with
ep->maxpacket.

Is there a way to send USB data of arbitrary size without using
fastboot?

Maxime

  reply	other threads:[~2021-07-03 13:47 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-25 13:05 [PATCH 00/12] Random Fixes for the CHIP Pro Maxime Ripard
2021-06-25 13:05 ` [PATCH 01/12] Revert "sunxi: spl: remove DMA related settings of the NAND controller" Maxime Ripard
2021-06-25 13:05 ` [PATCH 02/12] Revert "spl: nand: sunxi: use PIO instead of DMA" Maxime Ripard
2021-06-25 13:05 ` [PATCH 03/12] Revert "usb: gadget: fastboot: use correct max packet size" Maxime Ripard
2021-06-25 13:47   ` Sean Anderson
2021-06-25 14:14     ` Maxime Ripard
2021-06-29  2:27   ` Peng Fan (OSS)
2021-07-03 13:47     ` Maxime Ripard [this message]
2021-06-25 13:05 ` [PATCH 04/12] Kconfig: Migrate SPL_PANIC_ON_RAW_IMAGE Maxime Ripard
2021-06-25 13:05 ` [PATCH 05/12] mtd: Allow for a longer mtdparts table Maxime Ripard
2021-06-25 13:05 ` [PATCH 06/12] fastboot: Add missing newlines Maxime Ripard
2021-06-25 13:40   ` Andre Przywara
2021-06-25 13:05 ` [PATCH 07/12] configs: chip pro: Disable video output Maxime Ripard
2021-06-25 13:38   ` Andre Przywara
2021-06-25 13:05 ` [PATCH 08/12] clk: sunxi: Add missing clock compatible Maxime Ripard
2021-06-25 13:38   ` Andre Przywara
2021-06-25 13:05 ` [PATCH 09/12] fastboot: nand: Fix return error code Maxime Ripard
2021-06-25 14:08   ` Andre Przywara
2021-06-25 13:05 ` [PATCH 10/12] configs: chip pro: Disable UMS Maxime Ripard
2021-06-25 13:05 ` [PATCH 11/12] configs: chip pro: fix the offsets Maxime Ripard
2021-06-25 13:05 ` [PATCH 12/12] configs: chip pro: Fix NAND Controller name Maxime Ripard

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=20210703134711.iyctnqb2wxomtj37@gilmour \
    --to=maxime@cerno.tech \
    --cc=andre.przywara@arm.com \
    --cc=jagan@amarulasolutions.com \
    --cc=jun.li@nxp.com \
    --cc=marex@denx.de \
    --cc=miquel.raynal@bootlin.com \
    --cc=peng.fan@nxp.com \
    --cc=peng.fan@oss.nxp.com \
    --cc=trini@konsulko.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.