* [PATCH] arm: support booting of uimages with as barebox payload.
@ 2012-07-17 11:23 Christian Kapeller
2012-07-17 12:49 ` Jean-Christophe PLAGNIOL-VILLARD
0 siblings, 1 reply; 4+ messages in thread
From: Christian Kapeller @ 2012-07-17 11:23 UTC (permalink / raw)
To: barebox
Packing barebox within an uimage gives us integrity checking.
Generate the image with:
./scripts/mkimage -A arm -O barebox -T firmware -C none -d barebox.bin -a 0xffffffff barebox.uimage
Signed-off-by: Christian Kapeller <christian.kapeller@cmotion.eu>
---
arch/arm/lib/bootm.c | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/arch/arm/lib/bootm.c b/arch/arm/lib/bootm.c
index 3a00437..791efc2 100644
--- a/arch/arm/lib/bootm.c
+++ b/arch/arm/lib/bootm.c
@@ -117,6 +117,13 @@ static struct image_handler rawimage_handler = {
.filetype = filetype_unknown,
};
+static struct image_handler bbuimage_handler = {
+ .name = "ARM barebox uImage",
+ .bootm = do_bootm_linux,
+ .filetype = filetype_uimage,
+ .ih_os = IH_OS_BAREBOX,
+};
+
struct zimage_header {
u32 unused[9];
u32 magic;
@@ -470,6 +477,7 @@ static int armlinux_register_image_handler(void)
register_image_handler(&uimage_handler);
register_image_handler(&rawimage_handler);
register_image_handler(&zimage_handler);
+ register_image_handler(&bbuimage_handler);
if (IS_BUILTIN(CONFIG_CMD_BOOTM_AIMAGE)) {
register_image_handler(&aimage_handler);
binfmt_register(&binfmt_aimage_hook);
--
1.7.5.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] arm: support booting of uimages with as barebox payload.
2012-07-17 11:23 [PATCH] arm: support booting of uimages with as barebox payload Christian Kapeller
@ 2012-07-17 12:49 ` Jean-Christophe PLAGNIOL-VILLARD
2012-07-17 13:23 ` Christian Kapeller
0 siblings, 1 reply; 4+ messages in thread
From: Jean-Christophe PLAGNIOL-VILLARD @ 2012-07-17 12:49 UTC (permalink / raw)
To: Christian Kapeller; +Cc: barebox
On 13:23 Tue 17 Jul , Christian Kapeller wrote:
> Packing barebox within an uimage gives us integrity checking.
>
> Generate the image with:
> ./scripts/mkimage -A arm -O barebox -T firmware -C none -d barebox.bin -a 0xffffffff barebox.uimage
>
> Signed-off-by: Christian Kapeller <christian.kapeller@cmotion.eu>
> ---
boot it as a linux kernel
it will work
Best Regards,
J.
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] arm: support booting of uimages with as barebox payload.
2012-07-17 12:49 ` Jean-Christophe PLAGNIOL-VILLARD
@ 2012-07-17 13:23 ` Christian Kapeller
2012-07-17 15:34 ` Sascha Hauer
0 siblings, 1 reply; 4+ messages in thread
From: Christian Kapeller @ 2012-07-17 13:23 UTC (permalink / raw)
To: Jean-Christophe PLAGNIOL-VILLARD; +Cc: barebox
On 07/17/2012 02:49 PM, Jean-Christophe PLAGNIOL-VILLARD wrote:
> On 13:23 Tue 17 Jul , Christian Kapeller wrote:
>> Packing barebox within an uimage gives us integrity checking.
>>
>> Generate the image with:
>> ./scripts/mkimage -A arm -O barebox -T firmware -C none -d barebox.bin -a 0xffffffff barebox.uimage
>>
>> Signed-off-by: Christian Kapeller <christian.kapeller@cmotion.eu>
>> ---
> boot it as a linux kernel
>
> it will work
You are right, it does. But then, I am asking myself, why is there a OS
definition for 'barebox', when we aren't using it in the first place?
Regards,
Christian
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] arm: support booting of uimages with as barebox payload.
2012-07-17 13:23 ` Christian Kapeller
@ 2012-07-17 15:34 ` Sascha Hauer
0 siblings, 0 replies; 4+ messages in thread
From: Sascha Hauer @ 2012-07-17 15:34 UTC (permalink / raw)
To: Christian Kapeller; +Cc: barebox
On Tue, Jul 17, 2012 at 03:23:27PM +0200, Christian Kapeller wrote:
> On 07/17/2012 02:49 PM, Jean-Christophe PLAGNIOL-VILLARD wrote:
> > On 13:23 Tue 17 Jul , Christian Kapeller wrote:
> >> Packing barebox within an uimage gives us integrity checking.
> >>
> >> Generate the image with:
> >> ./scripts/mkimage -A arm -O barebox -T firmware -C none -d barebox.bin -a 0xffffffff barebox.uimage
> >>
> >> Signed-off-by: Christian Kapeller <christian.kapeller@cmotion.eu>
> >> ---
> > boot it as a linux kernel
> >
> > it will work
>
> You are right, it does. But then, I am asking myself, why is there a OS
> definition for 'barebox', when we aren't using it in the first place?
It's derived from U-Boot where it initially was:
#define IH_OS_U_BOOT 17 /* Firmware */
When renaming U-Boot to barebox this was one of the occurences of
'U_BOOT' that shouldn't have been renamed.
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2012-07-17 15:34 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-17 11:23 [PATCH] arm: support booting of uimages with as barebox payload Christian Kapeller
2012-07-17 12:49 ` Jean-Christophe PLAGNIOL-VILLARD
2012-07-17 13:23 ` Christian Kapeller
2012-07-17 15:34 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox