From: Arnout Vandecappelle <arnout@mind.be>
To: buildroot@busybox.net
Subject: [Buildroot] designing a firmware update mechanism
Date: Sun, 20 Jan 2013 11:48:34 +0100 [thread overview]
Message-ID: <50FBCB82.9060507@mind.be> (raw)
In-Reply-To: <1358460573.32266.63.camel@genx>
On 01/17/13 23:09, John Stile wrote:
> I use buildroot for an embedded project, which has an atmel arm
> processor, at91BootStrap on NOR to call uboot (and the reset of the
> system) on NAND.
>
> I am trying to devise a brick-safe strategy to update the systems once
> created, but I'm making this up as I go for a lack of better ideas.
>
> So far I am trying to split NAND in redundant halves (each with a copy
> of uboot + uboot-env + kernel + roofs), and modify at91bootstrap to
> choose which uboot to load, based on something inside the uboot-env
> areas.
Do you really need U-Boot itself to be upgradeable? If not, you can put
U-Boot and its environment in NOR. That gives you U-Boot scripting to
choose an appropriate kernel+rootfs, it allows you to use a bootcounter
to fall back on the other kernel when it is resetting all the time (due
to watchdog), it allows you to detect failed upgrades (CRC check fails),
it allows you to put everything in UBI volumes (if you need the wear
levelling and bit scrubbing), etc.
> Will I need to compile 2 versions of uboot, differing only in where to
> look for the uboot-env, or is there another way? If so, is there a way
> to do this within buildroot, or does uboot need to become an external
> project from my buildroot setup?
As Peter wrote, you don't need to (but then you have to hack U-Boot).
If you do want to build two versions of U-Boot, it's not that hard:
make BR2_TARGET_UBOOT_BOARDNAME=myboard_p1 uboot
mv output/images/u-boot.img output/images/u-boot.myboard_p1.img
make BR2_TARGET_UBOOT_BOARDNAME=myboard_p2 uboot
mv output/images/u-boot.img output/images/u-boot.myboard_p2.img
> Could anyone share a firmware update strategy for a project that uses
> buildroot, at91bootstrap, and uboot, or is that outside the scope of
> this list?
>
> I have not found any built-in mechanisms to handle updates.
I started on a project that collects the best practices of firmware
updates, but I haven't made much progress up to now :-(
Regards,
Arnout
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
prev parent reply other threads:[~2013-01-20 10:48 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-17 22:09 [Buildroot] designing a firmware update mechanism John Stile
2013-01-18 11:30 ` Jérôme Pouiller
2013-01-18 13:55 ` Peter Korsgaard
2013-01-20 10:48 ` Arnout Vandecappelle [this message]
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=50FBCB82.9060507@mind.be \
--to=arnout@mind.be \
--cc=buildroot@busybox.net \
/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.