[U-Boot] [PATCH v2 1/1] Add support for Eukrea CPU9260 SBC
Jean-Christophe PLAGNIOL-VILLARD
plagnioj at jcrosoft.com
Sat Jul 18 17:21:24 CEST 2009
> +
> +#ifdef CONFIG_DISPLAY_BOARDINFO
> +int checkboard(void)
> +{
> + char buf[32];
> +
> + printf("Board : Eukrea Electromatique CPU9260\n");
> + printf("Crystal frequency: %8s MHz\n",
> + strmhz(buf, get_main_clk_rate()));
> + printf("CPU clock : %8s MHz\n",
> + strmhz(buf, get_cpu_clk_rate()));
> + printf("Master clock : %8s MHz\n",
> + strmhz(buf, get_mck_clk_rate()));
please use CONFIG_DISPLAY_CPUINFO
> + printf("\n");
> + return 0;
> +}
> +#endif
<snip>
> diff --git a/cpu/arm926ejs/at91/lowlevel_init.S b/cpu/arm926ejs/at91/lowlevel_init.S
> index 5ed518c..9962ae9 100644
> --- a/cpu/arm926ejs/at91/lowlevel_init.S
> +++ b/cpu/arm926ejs/at91/lowlevel_init.S
> @@ -194,7 +194,7 @@ SMRDATA:
> .word CONFIG_SYS_PIOD_PPUDR_VAL
> .word (AT91_BASE_SYS + AT91_PIOD + PIO_ASR)
> .word CONFIG_SYS_PIOD_PPUDR_VAL
> -#elif defined(CONFIG_AT91SAM9261)
> +#elif defined(CONFIG_AT91SAM9260) || defined(CONFIG_AT91SAM9261)
please do this in a separate patch
> .word (AT91_BASE_SYS + AT91_PIOC + PIO_PDR)
> .word CONFIG_SYS_PIOC_PDR_VAL1
> .word (AT91_BASE_SYS + AT91_PIOC + PIO_PUDR)
<snip>
> +
> +/* NAND flash */
> +#define CONFIG_NAND_ATMEL 1
> +#define NAND_MAX_CHIPS 1
> +#define CONFIG_SYS_MAX_NAND_DEVICE 1
> +#define CONFIG_SYS_NAND_BASE 0x40000000
> +#define CONFIG_SYS_NAND_DBW_8 1
> +#undef CONFIG_SYS_NAND_DBW_16
please remove if no-need
> +#define CONFIG_SYS_NAND_READY_PIN AT91_PIN_PC13
> +#define CONFIG_SYS_NAND_ENABLE_PIN AT91_PIN_PC14
> +#define CONFIG_SYS_NAND_MASK_ALE (1 << 21)
> +#define CONFIG_SYS_NAND_MASK_CLE (1 << 22)
> +
> +/* NOR flash */
> +#define CONFIG_SYS_FLASH_CFI 1
> +#define CONFIG_FLASH_CFI_DRIVER 1
> +#define PHYS_FLASH_1 0x10000000
> +#define PHYS_FLASH_2 0x12000000
> +#define CONFIG_SYS_FLASH_BANKS_LIST \
> + { PHYS_FLASH_1, PHYS_FLASH_2 }
> +#define CONFIG_SYS_FLASH_BASE PHYS_FLASH_1
> +#define CONFIG_SYS_MAX_FLASH_SECT (255+4)
> +#define CONFIG_SYS_MAX_FLASH_BANKS 2
> +#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT
> +#define CONFIG_SYS_FLASH_EMPTY_INFO 1
> +#define CONFIG_SYS_FLASH_USE_BUFFER_WRITE 1
> +#define CONFIG_SYS_FLASH_PROTECTION 1
> +#define CONFIG_SYS_MONITOR_BASE PHYS_FLASH_1
> +
<snip>
> +#undef CONFIG_SYS_USE_NANDFLASH
> +#define CONFIG_SYS_USE_FLASH 1
> +
> +#if defined(CONFIG_SYS_USE_FLASH)
> +#define CONFIG_ENV_IS_IN_FLASH 1
> +#define CONFIG_ENV_OFFSET 0x40000
> +#define CONFIG_ENV_SECT_SIZE 0x20000
> +#define CONFIG_ENV_SIZE 0x20000
> +#define CONFIG_ENV_OVERWRITE 1
> +
> +#define CONFIG_BOOTCOMMAND "run flashboot"
> +
> +#define MTDIDS_DEFAULT "nor0=physmap-flash.0,nand0=nand"
> +#define MTDPARTS_DEFAULT \
> + "mtdparts=physmap-flash.0:" \
> + "256k(u-boot)ro," \
> + "128k(u-boot-env)ro," \
> + "1792k(kernel)," \
> + "-(rootfs);" \
> + "nand:-(nand)"
> +
> +#define CONFIG_BOOTARGS "root=/dev/mtdblock3 rootfstype=jffs2 "
> +
> +#define CONFIG_EXTRA_ENV_SETTINGS \
> + "mtdids=" MTDIDS_DEFAULT "\0" \
> + "mtdparts=" MTDPARTS_DEFAULT "\0" \
> + "partition=nand0,0\0" \
> + "ramargs=setenv bootargs $(bootargs) $(mtdparts)\0" \
> + "ramboot=tftpboot 0x22000000 cpu9260/uImage;" \
> + "run ramargs;bootm 22000000\0" \
> + "flashboot=run ramargs;bootm 0x10060000\0" \
> + "updtub=tftp 0x24000000 cpu9260/u-boot.bin;protect off" \
> + " 0x10000000 0x1003ffff;erase 0x10000000 " \
> + "0x1003ffff;cp.b 0x24000000 0x10000000 " \
> + "$(filesize)\0" \
> + "updtui=tftp 0x24000000 cpu9260/uImage;protect off" \
> + " 0x10060000 0x1021ffff;erase 0x10060000 " \
> + "0x1021ffff;cp.b 0x24000000 0x10060000 " \
> + "$(filesize)\0" \
> + "updtrfs=tftp 0x24000000 cpu9260/rootfs.jffs2;protect " \
> + "off 0x10220000 0x13ffffff;erase 0x10220000 " \
> + "0x13ffffff;cp.b 0x24000000 0x10220000 " \
> + "$(filesize)\0" \
> + ""
> +#else
> +#error "Undefined memory device"
why?
> +#endif
> +
> +#define CONFIG_BAUDRATE 115200
> +#define CONFIG_SYS_BAUDRATE_TABLE {115200 , 19200, 38400, 57600, 9600 }
> +
> +#define CONFIG_SYS_PROMPT "CPU9260=> "
> +#define CONFIG_SYS_CBSIZE 256
> +#define CONFIG_SYS_MAXARGS 16
> +#define CONFIG_SYS_PBSIZE \
> + (CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16)
> +#define CONFIG_SYS_LONGHELP 1
> +#define CONFIG_CMDLINE_EDITING 1
> +#define CONFIG_SILENT_CONSOLE 1
> +#define CONFIG_NETCONSOLE 1
> +
> +#define ROUND(A, B) (((A) + (B)) & ~((B) - 1))
please remove
Best Regards,
J.
More information about the U-Boot
mailing list