public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] test: dfu: script: wrong md5sum on nand partitions
Date: Fri, 12 Sep 2014 08:53:42 -0600	[thread overview]
Message-ID: <541308F6.9010807@wwwdotorg.org> (raw)
In-Reply-To: <1410503250-13761-1-git-send-email-hs@denx.de>

On 09/12/2014 12:27 AM, Heiko Schocher wrote:
> when uplaoding a file, at least from a nand partition, the complete
> mtd nand partition size is transferred. This leads in a wrong md5sum
> as the filesize is different between the downloaded file and the
> uploaded file. Limit the uploaded filesize to the downloaded
> fixes this.

I was going to say that it'd be better to fix U-Boot's NAND code to 
transfer the correct amount of data. However, I suppose the correct 
amount *is* the whole partition for anything other than a filesystem 
file. As such, I'd suggest replacing "nand" in the patch description 
with something else, since presumably the exact same issue applies to 
partitions on eMMC. The issue applies to any partition.

I wonder if there's a way to distinguish between file tests and 
partition tests in dfu_gadget_test.sh, so that the $N_FILE_FULL -> 
$N_FILE conversion can be applied only for partitions. Otherwise, a file 
upload/download test could end up changing (increasing) the file length 
and this bug wouldn't be detected.

  reply	other threads:[~2014-09-12 14:53 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-12  6:27 [U-Boot] [PATCH] test: dfu: script: wrong md5sum on nand partitions Heiko Schocher
2014-09-12 14:53 ` Stephen Warren [this message]
2014-09-15  5:32   ` Heiko Schocher
2014-09-15  9:45     ` Lukasz Majewski
2014-09-15 10:48       ` Heiko Schocher
2014-09-15 11:55         ` Lukasz Majewski
2014-09-17 20:48           ` Scott Wood

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=541308F6.9010807@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --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