[PATCH 2/4] ARM: head: Add some space behind the image header

Sascha Hauer s.hauer at pengutronix.de
Tue Mar 12 05:29:55 EDT 2013


This adds 32bytes of space behind the image header (exception table
+ barebox magic) for board/SoC specific use. This can be used for
example to embed some extra information in a flashed image.

Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
 arch/arm/include/asm/barebox-arm-head.h | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm/include/asm/barebox-arm-head.h b/arch/arm/include/asm/barebox-arm-head.h
index 9d9b854..225a336 100644
--- a/arch/arm/include/asm/barebox-arm-head.h
+++ b/arch/arm/include/asm/barebox-arm-head.h
@@ -33,6 +33,13 @@ static inline void arm_cpu_lowlevel_init(void)
 	set_cr(r);
 }
 
+/*
+ * 32 bytes at this is offset is reserved in the barebox head for board/SoC
+ * usage
+ */
+#define ARM_HEAD_SPARE_OFS	0x30
+#define ARM_HEAD_SPARE_MARKER	0x55555555
+
 #ifdef CONFIG_HAVE_MACH_ARM_HEAD
 #include <mach/barebox-arm-head.h>
 #else
@@ -64,6 +71,9 @@ static inline void barebox_arm_head(void)
 							 * barebox can skip relocation
 							 */
 		".word _barebox_image_size\n"		/* image size to copy */
+		".rept 8\n"
+		".word 0x55555555\n"
+		".endr\n"
 	);
 }
 #endif
-- 
1.8.2.rc2




More information about the barebox mailing list