mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH] Documentation: user: barebox: make barebox chainloading clearer
Date: Wed, 29 Nov 2023 12:52:55 +0100	[thread overview]
Message-ID: <20231129115255.1538958-1-a.fatoum@pengutronix.de> (raw)

barebox images are designed to be chainloadable and can be loaded as if
they were a kernel by other bootloaders. The documentation lists
examples for two ways to achieve this with U-Boot preinstalled on the
board. They are not as clear as they could be as the resulting uImage
is called image in the mkimage line, but barebox.bin later on. This is
unfortunate as the build results in a barebox.bin already, which
corresponds to barebox proper in PBL setups. Rename it to barebox.uImage
instead and while at it note that booti isn't applicable to arm32.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 Documentation/user/barebox.rst | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/Documentation/user/barebox.rst b/Documentation/user/barebox.rst
index c95adb78bb83..80f0f96a98de 100644
--- a/Documentation/user/barebox.rst
+++ b/Documentation/user/barebox.rst
@@ -212,7 +212,8 @@ like a Linux kernel that is passed an external device tree. For example:
 
   U-Boot: tftp $kernel_addr barebox-dt-2nd.img
   U-Boot: tftp $fdt_addr my-board.dtb
-  U-Boot: booti $kernel_addr - $fdt_addr
+  U-Boot: bootm $kernel_addr - $fdt_addr # On 32-bit ARM
+  U-Boot: booti $kernel_addr - $fdt_addr # for other platforms
 
 For non-DT enabled-bootloaders or other architectures, often the normal barebox
 binaries can also be used as they are designed to be startable second stage
@@ -224,7 +225,7 @@ converted to uImage format using the mkimage tool provided with U-Boot:
 .. code-block:: console
 
   sh: mkimage -n barebox -A arm -T kernel -C none -a 0x80000000 -d \
-      build/images/barebox-freescale-imx53-loco.img image
+      build/images/barebox-freescale-imx53-loco.img barebox.uImage
 
 U-Boot expects the start address of the binary to be given in the image using the
 ``-a`` option. The address depends on the board and must be an address which isn't
@@ -233,7 +234,7 @@ image for that board. The image can then be started with ``bootm``:
 
 .. code-block:: console
 
-  U-Boot: tftp $load_addr barebox.bin
+  U-Boot: tftp $load_addr barebox.uImage
   U-Boot: bootm $load_addr
 
 With barebox already running on your board, this can be used to chainload
-- 
2.39.2




             reply	other threads:[~2023-11-29 11:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-29 11:52 Ahmad Fatoum [this message]
2023-12-05  7:55 ` Sascha Hauer

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=20231129115255.1538958-1-a.fatoum@pengutronix.de \
    --to=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /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