[U-Boot] [PATCH v2] AT91: fix at91sam9260.h for AT91SAM9XE

Reinhard Meyer u-boot at emk-elektronik.de
Tue Aug 24 20:41:21 CEST 2010


For some reason Atmel changed the GPBR address for the AT91SAM9XE
to be different from the engineering samples and the AT91SAM9260.
Also let the correct SoC name be defined.

Signed-off-by: Reinhard Meyer <u-boot at emk-elektronik.de>
---
  one probably need not understand why the first mail
  got clobbered up in spaces at start of each line...

  arch/arm/include/asm/arch-at91/at91sam9260.h |   19 +++++++++++++++----
  1 files changed, 15 insertions(+), 4 deletions(-)

diff --git a/arch/arm/include/asm/arch-at91/at91sam9260.h b/arch/arm/include/asm/arch-at91/at91sam9260.h
index ec04318..91ea800 100644
--- a/arch/arm/include/asm/arch-at91/at91sam9260.h
+++ b/arch/arm/include/asm/arch-at91/at91sam9260.h
@@ -59,7 +59,16 @@
  #define AT91_RTT_BASE		0xfffffd20
  #define AT91_PIT_BASE		0xfffffd30
  #define AT91_WDT_BASE		0xfffffd40
-#define AT91_GPR_BASE		0xfffffd50
+/*
+ * The latest revision of the AT91SAM9XE has the GPBR moved up 0x10.
+ * (its not a bug, its a feature...)
+ * Maybe we can figure a dynamic way to handle this later...
+ */
+#ifdef CONFIG_AT91SAM9XE
+# define AT91_GPR_BASE		0xfffffd60
+#else
+# define AT91_GPR_BASE		0xfffffd50
+#endif

  #ifdef CONFIG_AT91_LEGACY

@@ -140,10 +149,12 @@
  /*
   * Cpu Name
   */
-#if defined(CONFIG_AT91SAM9260)
-#define CONFIG_SYS_AT91_CPU_NAME	"AT91SAM9260"
+#if defined(CONFIG_AT91SAM9XE)
+# define CONFIG_SYS_AT91_CPU_NAME	"AT91SAM9XE"
+#elif defined(CONFIG_AT91SAM9260)
+# define CONFIG_SYS_AT91_CPU_NAME	"AT91SAM9260"
  #elif defined(CONFIG_AT91SAM9G20)
-#define CONFIG_SYS_AT91_CPU_NAME	"AT91SAM9G20"
+# define CONFIG_SYS_AT91_CPU_NAME	"AT91SAM9G20"
  #endif

  #endif
-- 
1.5.6.5




More information about the U-Boot mailing list