
On Thu, Jun 09, 2011 at 11:13:25AM +0200, Reinhard Meyer wrote:
Dear Sergey Lapin,
Make AFEB9260 build again. Based on fix for AT91SAM9260EK.
Signed-off-by: Sergey Lapin slapin@ossfans.org
Cleaned-up a bit
board/afeb9260/afeb9260.c | 103 ++++++++++++++++++++++++------------------- boards.cfg | 2 +- include/configs/afeb9260.h | 28 +++++++++--- 3 files changed, 79 insertions(+), 54 deletions(-)
...
diff --git a/boards.cfg b/boards.cfg index ac20c81..a187a9f 100644 --- a/boards.cfg +++ b/boards.cfg @@ -72,7 +72,7 @@ netstar arm arm925t voiceblue arm arm925t omap1510inn arm arm925t - ti aspenite arm arm926ejs - Marvell armada100 -afeb9260 arm arm926ejs - - at91 +afeb9260 arm arm926ejs - - at91 afeb9260:AT91SAM9260 at91cap9adk arm arm926ejs - atmel at91 at91sam9260ek_nandflash arm arm926ejs at91sam9260ek atmel at91 at91sam9260ek:AT91SAM9260,SYS_USE_NANDFLASH at91sam9260ek_dataflash_cs0 arm arm926ejs at91sam9260ek atmel at91 at91sam9260ek:AT91SAM9260,SYS_USE_DATAFLASH_CS0
Does not the afeb9260 have a manufacturer?
It have, but no established name. This is volunteer project.
And if it is not planned to be available with other Atmel SoCs, it is not necessary to have the "AT91SAM9260" in the boards.cfg file. See also below.
Fixed this.
diff --git a/include/configs/afeb9260.h b/include/configs/afeb9260.h index 36a2a46..9114a52 100644 --- a/include/configs/afeb9260.h +++ b/include/configs/afeb9260.h @@ -25,12 +25,19 @@
#ifndef __CONFIG_H #define __CONFIG_H +#include <asm/arch/hardware.h>
-#define CONFIG_AT91_LEGACY +#define CONFIG_SYS_TEXT_BASE 0x21f00000
/* ARM asynchronous clock */ #define CONFIG_SYS_AT91_MAIN_CLOCK 18429952 /* from 18.432 MHz crystal */ -#define CONFIG_SYS_HZ 1000 +#define CONFIG_SYS_AT91_SLOW_CLOCK 32768 +#define CONFIG_SYS_HZ 1000
+#define CONFIG_BOARD_EARLY_INIT_F +#define CONFIG_DISPLAY_CPUINFO
#define CONFIG_AT91SAM9260 1 /* It's an Atmel AT91SAM9260 SoC*/
This should lead to a double definition warning. See above. Also, please do not use "1" if no numerical value is intended for the define. Important: if you define the SoC type in this file, it must be before "hardware.h" is included.
Fixed.
#define CONFIG_AFEB9260 1 /* on an AFEB9260 Board */
Please remove the "1" here. Fix further down as well.
Done
@@ -46,8 +53,14 @@ /*
- Hardware drivers
*/ +#define CONFIG_ATMEL_LEGACY #define CONFIG_AT91_GPIO 1
No "1" here.
Done
+#define CONFIG_AT91_PULLUP 1
This "1" is required. OK.
Avoid double empty lines.
Fixed
#define CONFIG_ATMEL_USART 1
No "1" here.
+#define CONFIG_USART_BASE ATMEL_BASE_DBGU +#define CONFIG_USART_ID ATMEL_ID_SYS #undef CONFIG_USART0 #undef CONFIG_USART1 #undef CONFIG_USART2
Please, no #undef's. Fix further down as well.
Removed these.
About section below: #include <config_cmd_default.h> #undef CONFIG_CMD_BDI #undef CONFIG_CMD_FPGA #undef CONFIG_CMD_IMI #undef CONFIG_CMD_IMLS #undef CONFIG_CMD_LOADS #undef CONFIG_CMD_SOURCE
Is it ok or should I have to change it? If I need to change it, then I'd like to know how to do it right way.
All the best, S.