From: Yann E. MORIN <yann.morin.1998@free.fr>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 2/5] package/rpi-firmware: add option to install firmware files in target/boot/
Date: Fri, 29 Nov 2013 20:01:53 +0100 [thread overview]
Message-ID: <20131129190153.GA4639@free.fr> (raw)
In-Reply-To: <20131129092715.24d2b199@skate>
Thomas, All,
On 2013-11-29 09:27 +0100, Thomas Petazzoni spake thusly:
> Dear Jeremy Rosen,
>
> On Fri, 29 Nov 2013 09:00:19 +0100 (CET), Jeremy Rosen wrote:
>
> > Basically, you build the root filesystem the way it will look when all
> > sub-filesystems are mounted, you describe how they are mounted and
> > the system builds the partitions accordingly.
>
> I don't necessarily agree here, because this strategy makes the
> confusion between two things:
>
> * The contents of the /boot directory in the root filesystem.
>
> * The contents of the boot partition needed for some platforms (OMAP,
> RPi, UEFI-based x86 platforms, etc.)
>
> Those are two different things, and Yann's proposal merges them. As an
> example, provided your bootloader has ext3 support and you're on an
> OMAP platform, you may want to have something like:
>
> * The /boot directory in the root filesystem contains the kernel image
> (uImage, zImage)
>
> * The boot partition contains just the bootloader images (MLO,
> u-boot.img).
>
> There is no point to have the kernel image in the boot partition, and
> there is no point in having the bootloader images in the /boot
> directory of the root filesystem.
OK, now I can follow what you mean (although one may argue whether the
kernel is part of those 'boot' files, since it does not make sense to
have it in the root file system).
However, this means that each 'platform' (eg. the RPi, your special
OMAP board...) will each have to provide a manifest of things to install
in the boot partition, and 'genimages' will have to interpret this
manifest to populate the boot partition.
I won't say I like this, even if I see your point. And from a more
global perspective, the boot partition might also be something else than
a filesystem.
So OK, I'll see how to manage this. Here is a quick proposal:
1) genimages should be able to create board-specific partitions, eg.:
(a) a filesystem mounted on, and filled from /boot
(b) an unmounted filesystem filled with an arbitrary set of files
(c) a binary blob
- For (a), we can already do that, it's like any other filesystem.
- For (b), the submitted genimages can't do that, but the one in
buildroot.config can, so I just have to reinstate my 'fs_filler'
hook.
- For (c), this has to be implemented. I suggest we postpone this
until the basic genimages is upstream, and we have an actual
use-case for it (no need to over-engineer the sutff, YAGNI...)
Of course, there are the cases where we may need any conbinations of one
or more of:
- a boot blob (eg. MBR, UEFI; obviously only one!)
- a binary blob partition (eg. a U-Boot image)
- a mounted /boot filesystem
- a unmounted filesystem
2) bootloaders for case (a) will have to:
(a) install their files in $(TARGET_DIR)/boot
genimages should be prepared to generate a partition with a filesystem
filed from the content of /boot, and add an entry for it in fstab.
(Done! :-) )
We currently (as far as I know) have no such bootloader; not even
rpi-firmware fits in this category.
3) bootloaders for case (b) will have to:
(a) install their files, and a manifest of those files, in a known
location
(b) that location should be platform-agnostic, so that genimages will
find it; $(BINARIES_DIR)/boot-files/ looks like a good candidate.
genimages should be prepared to generate a partition with a filesystem
filled by copying files listed in a manifest file.
(Relatively easy, I think.)
The kind of bootloaders I know that fit in this category are
rpi-firmware and grub. There may have others.
4) bootloaders for case (c) will have to:
(a) install the binary blob in a known location;
$(BINARIES_DIR)/boot-files/ looks like a good candidate.
genimages should be prepared to generate a partition by simply dumping
the content of a file.
The bootloaders that fit in this category are U-Boot, RedBoot... Note
that this does not imply an MBR-type of partitioning.
Any comment on the above?
And thanks for the guidance and enlightment! :-)
Regards,
Yann E. MORIN.
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
next prev parent reply other threads:[~2013-11-29 19:01 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-22 22:50 [Buildroot] [RFC] Introduce the 'genimages' infrastructure Yann E. MORIN
2013-11-22 22:50 ` [Buildroot] [PATCH 1/5] package/rpi-firmware: only install one firmware file Yann E. MORIN
2013-11-24 9:04 ` Arnout Vandecappelle
2013-11-22 22:50 ` [Buildroot] [PATCH 2/5] package/rpi-firmware: add option to install firmware files in target/boot/ Yann E. MORIN
2013-11-28 20:11 ` Thomas Petazzoni
2013-11-28 20:55 ` Yann E. MORIN
2013-11-29 8:00 ` Jeremy Rosen
2013-11-29 8:09 ` Yann E. MORIN
2013-11-29 8:27 ` Thomas Petazzoni
2013-11-29 19:01 ` Yann E. MORIN [this message]
2013-12-01 0:59 ` Arnout Vandecappelle
2013-12-01 14:10 ` Yann E. MORIN
2013-11-22 22:50 ` [Buildroot] [PATCH 3/5] package/rpi-firmware: move to bootloaders menu Yann E. MORIN
2013-11-22 22:55 ` Yann E. MORIN
2013-11-28 20:08 ` Thomas Petazzoni
2013-11-28 21:16 ` Yann E. MORIN
2013-12-01 1:04 ` Arnout Vandecappelle
2013-11-22 22:50 ` [Buildroot] [PATCH 4/5] fs/custom: generate complete, partition-based device images Yann E. MORIN
2013-11-22 22:58 ` Yann E. MORIN
2013-11-25 9:31 ` Arnout Vandecappelle
2013-11-25 19:05 ` Yann E. MORIN
2013-11-25 22:27 ` Arnout Vandecappelle
2013-11-25 22:45 ` Yann E. MORIN
2013-11-25 22:56 ` Arnout Vandecappelle
2013-11-25 23:03 ` Yann E. MORIN
2013-11-26 8:12 ` Arnout Vandecappelle
2013-11-26 17:06 ` Yann E. MORIN
2013-11-22 22:50 ` [Buildroot] [PATCH 5/5] board/raspberrypi: provide partition description for the new genimanges Yann E. MORIN
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=20131129190153.GA4639@free.fr \
--to=yann.morin.1998@free.fr \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox