Skip to contentSkip to conversation

ARM: mach-shmobile: Add zboot support for SuperH Mobile ARM

PATCH Superseded Simon Horman 2 participants 5 messages Oct 8, 2010 – Oct 12, 2010

v1 of 5 Superseded Latest is v5 →

lore
Share & tools
lore
#0 lore raw

cover ARM: mach-shmobile: Add zboot support for SuperH Mobile ARM

Hi,

this short patch series by Kuninori Morimoto adds
zboot support to mach-shmobile.

#3 lore raw

PATCH 2/2 ARM: mach-shmobile: Add zboot support for SuperH Mobile ARM

Quoted 9 lines · Simon Horman

From: Kuninori Morimoto <[email protected]>

When COFNIG_ZBOOT_ROM is selected, the resulting zImage file will be small boot loader and may be burned to rom or flash.

This is the board-specific portion of this patch-set.

Hey Simon,

Thanks for your work on this!

Quoted 14 lines
(quoted diff) +14 -0
+static void __init
+fixup_ap4evb(struct machine_desc *desc, struct tag *tag,
+ ? ? ? ? ? ?char **cmdline, struct meminfo *mi)
+{
+#ifdef CONFIG_ZBOOT_ROM
+ ? ? ? /*
+ ? ? ? ?* below settings are needed when zboot
+ ? ? ? ?*/
+ ? ? ? tag->hdr.tag ? ? ? ? ? ?= ATAG_CORE;
+ ? ? ? tag->hdr.size ? ? ? ? ? = tag_size(tag_core);
+ ? ? ? tag->u.core.flags ? ? ? = 0;
+ ? ? ? tag->u.core.pagesize ? ?= 0;
+ ? ? ? tag->u.core.rootdev ? ? = 0;
+

Review

Quoted 10 lines
(quoted diff) +10 -0
+ ? ? ? tag ? ? ? ? ? ? ? ? ? ? = tag_next(tag);
+ ? ? ? tag->hdr.tag ? ? ? ? ? ?= ATAG_MEM;
+ ? ? ? tag->hdr.size ? ? ? ? ? = tag_size(tag_mem32);
+ ? ? ? tag->u.mem.size ? ? ? ? = CONFIG_MEMORY_SIZE;
+ ? ? ? tag->u.mem.start ? ? ? ?= CONFIG_MEMORY_START;
+
+ ? ? ? tag ? ? ? ? ? ? ? ? ? ? = tag_next(tag);
+ ? ? ? tag->hdr.tag ? ? ? ? ? ?= ATAG_NONE;
+ ? ? ? tag->hdr.size ? ? ? ? ? = 0;
+#endif

Hm, I wonder if this part can be rearranged. Perhaps I'm misunderstanding, but I would really really prefer if the memory information could be passed from the romImage header instead of adding fixups in the board specific code. This code looks like a workaround for not passing information properly. We probably want to pass other parameters anyway, so it shouldn't be any big issue.

Cheers,

/ magnus

#4 lore raw

PATCH 2/2 ARM: mach-shmobile: Add zboot support for SuperH Mobile ARM

Quoted 38 lines · Magnus Damm
Quoted 9 lines · Simon Horman

From: Kuninori Morimoto <[email protected]>

When COFNIG_ZBOOT_ROM is selected, the resulting zImage file will be small boot loader and may be burned to rom or flash.

This is the board-specific portion of this patch-set.

Hey Simon,

Thanks for your work on this!

Quoted 23 lines
(quoted diff) +23 -0
+static void __init
+fixup_ap4evb(struct machine_desc *desc, struct tag *tag,
+ ? ? ? ? ? ?char **cmdline, struct meminfo *mi)
+{
+#ifdef CONFIG_ZBOOT_ROM
+ ? ? ? /*
+ ? ? ? ?* below settings are needed when zboot
+ ? ? ? ?*/
+ ? ? ? tag->hdr.tag ? ? ? ? ? ?= ATAG_CORE;
+ ? ? ? tag->hdr.size ? ? ? ? ? = tag_size(tag_core);
+ ? ? ? tag->u.core.flags ? ? ? = 0;
+ ? ? ? tag->u.core.pagesize ? ?= 0;
+ ? ? ? tag->u.core.rootdev ? ? = 0;
+
+ ? ? ? tag ? ? ? ? ? ? ? ? ? ? = tag_next(tag);
+ ? ? ? tag->hdr.tag ? ? ? ? ? ?= ATAG_MEM;
+ ? ? ? tag->hdr.size ? ? ? ? ? = tag_size(tag_mem32);
+ ? ? ? tag->u.mem.size ? ? ? ? = CONFIG_MEMORY_SIZE;
+ ? ? ? tag->u.mem.start ? ? ? ?= CONFIG_MEMORY_START;
+
+ ? ? ? tag ? ? ? ? ? ? ? ? ? ? = tag_next(tag);
+ ? ? ? tag->hdr.tag ? ? ? ? ? ?= ATAG_NONE;
+ ? ? ? tag->hdr.size ? ? ? ? ? = 0;
Quoted 8 lines
Quoted 1 line

+#endif

Hm, I wonder if this part can be rearranged. Perhaps I'm misunderstanding, but I would really really prefer if the memory information could be passed from the romImage header instead of adding fixups in the board specific code. This code looks like a workaround for not passing information properly. We probably want to pass other parameters anyway, so it shouldn't be any big issue.

Hi Magnus,

thanks for the suggestion. I will look into it and get back to you.