From: Stephen Warren <swarren@wwwdotorg.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] dfu: dfu_sf: Take the start address into account
Date: Wed, 23 Sep 2015 09:22:27 -0600 [thread overview]
Message-ID: <5602C3B3.2050102@wwwdotorg.org> (raw)
In-Reply-To: <1442980239-3931-1-git-send-email-festevam@gmail.com>
On 09/22/2015 09:50 PM, Fabio Estevam wrote:
> From: Fabio Estevam <fabio.estevam@freescale.com>
>
> The dfu_alt_info_spl variable allows passing a starting point
> for the binary to be flashed in the SPI NOR.
>
> For example, if we have 'dfu_alt_info_spl=spl raw 0x400', this means
> that we want to flash the binary starting at address 0x400.
>
> In order to do so we need to erase the entire sector and write to
> the the subsequent SPI NOR sectors taking such start address
> into account for the address calculations.
>
> Tested by succesfully writing SPL binary into 0x400 offset and
> the u-boot.img at offset 64 kiB of a SPL NOR.
This feels wrong. The entries in the DFU list must already be
sector-aligned, so there's no need for the code to round them. If the
entries are not already aligned, then the aligned erase operations will
erase other data, which will cause corruption.
next prev parent reply other threads:[~2015-09-23 15:22 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-23 3:50 [U-Boot] [PATCH] dfu: dfu_sf: Take the start address into account Fabio Estevam
2015-09-23 8:09 ` Lukasz Majewski
2015-09-23 15:22 ` Stephen Warren [this message]
2015-09-23 15:36 ` Fabio Estevam
2015-09-23 15:44 ` Fabio Estevam
2015-09-23 15:53 ` Stephen Warren
2015-10-20 0:06 ` [U-Boot] " Tom Rini
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=5602C3B3.2050102@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