[U-Boot] [RFC PATCH 08/19] switch ARM over to generic board
Simon Glass
sjg at chromium.org
Wed Dec 28 07:35:49 CET 2011
Signed-off-by: Simon Glass <sjg at chromium.org>
---
arch/arm/config.mk | 3 ---
arch/arm/include/asm/global_data.h | 8 ++++++++
arch/arm/lib/Makefile | 2 ++
3 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/arch/arm/config.mk b/arch/arm/config.mk
index 31e9ef9..45f9dca 100644
--- a/arch/arm/config.mk
+++ b/arch/arm/config.mk
@@ -33,9 +33,6 @@ endif
PLATFORM_CPPFLAGS += -DCONFIG_ARM -D__ARM__
-# Move to unified board system later
-CONFIG_SYS_LEGACY_BOARD := y
-
# Explicitly specifiy 32-bit ARM ISA since toolchain default can be -mthumb:
PF_CPPFLAGS_ARM := $(call cc-option,-marm,)
diff --git a/arch/arm/include/asm/global_data.h b/arch/arm/include/asm/global_data.h
index c3ff789..e31e06a 100644
--- a/arch/arm/include/asm/global_data.h
+++ b/arch/arm/include/asm/global_data.h
@@ -23,6 +23,13 @@
#ifndef __ASM_GBL_DATA_H
#define __ASM_GBL_DATA_H
+
+#ifndef CONFIG_SYS_LEGACY_BOARD
+
+/* Use the generic board which requires a unified global_data */
+#include <asm-generic/global_data.h>
+
+#else
/*
* The following data structure is placed in some memory which is
* available very early after boot (like DPRAM on MPC8xx/MPC82xx, or
@@ -99,5 +106,6 @@ typedef struct global_data {
#define GD_FLG_ENV_READY 0x00080 /* Environment imported into hash table */
#define DECLARE_GLOBAL_DATA_PTR register volatile gd_t *gd asm ("r8")
+#endif /* CONFIG_SYS_LEGACY_BOARD */
#endif /* __ASM_GBL_DATA_H */
diff --git a/arch/arm/lib/Makefile b/arch/arm/lib/Makefile
index 213c76f..fd3b331 100644
--- a/arch/arm/lib/Makefile
+++ b/arch/arm/lib/Makefile
@@ -37,7 +37,9 @@ GLSOBJS += _umodsi3.o
GLCOBJS += div0.o
+ifeq ($(CONFIG_SYS_LEGACY_BOARD),y)
COBJS-y += board.o
+endif
COBJS-y += bootm.o
COBJS-y += cache.o
COBJS-y += cache-cp15.o
--
1.7.3.1
More information about the U-Boot
mailing list