public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Marek Vasut <marex@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [RFC PATCH] usb: dfu: make nand upload working
Date: Sun, 13 Oct 2013 22:50:49 +0200	[thread overview]
Message-ID: <201310132250.50029.marex@denx.de> (raw)
In-Reply-To: <20131012231914.0e4516f9@jawa>

Dear Lukasz Majewski,

> On Sat, 12 Oct 2013 15:47:14 +0800
> 
> Bo Shen <voice.shen@atmel.com> wrote:
> > If won't pass value to dfu->r_left, it always 0, make no transfer,
> > the dfu-util on host side report failed. So, before starting transfer,
> > pass the value, then nand uploading can work.
> > 
> > Signed-off-by: Bo Shen <voice.shen@atmel.com>
> > 
> > ---
> > 
> >  drivers/dfu/dfu.c |    1 +
> >  1 file changed, 1 insertion(+)
> > 
> > diff --git a/drivers/dfu/dfu.c b/drivers/dfu/dfu.c
> > index 56b21c7..3c3ad1b 100644
> > --- a/drivers/dfu/dfu.c
> > +++ b/drivers/dfu/dfu.c
> > @@ -274,6 +274,7 @@ int dfu_read(struct dfu_entity *dfu, void *buf,
> > int size, int blk_seq_num) if (dfu->i_buf_start == NULL)
> > 
> >  			return -ENOMEM;
> > 
> > +		dfu->r_left = dfu->data.nand.size;
> 
> Please do not add nand related code to "generic" DFU code. This can
> damage DFU operation with other memories (like eMMC).
> 
> Such code shall be added to dfu_nand.c file.
> 

ACK, waiting for V2.

Lukasz, do you have a suggestion where this should be placed and why is this an 
actual issue?

Best regards,
Marek Vasut

  reply	other threads:[~2013-10-13 20:50 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-12  7:47 [U-Boot] [RFC PATCH] usb: dfu: make nand upload working Bo Shen
2013-10-12 21:19 ` Lukasz Majewski
2013-10-13 20:50   ` Marek Vasut [this message]
2013-10-14  7:25   ` Bo Shen
2013-10-16  9:00     ` Bo Shen
2013-11-01  1:20       ` Bo Shen

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=201310132250.50029.marex@denx.de \
    --to=marex@denx.de \
    --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