X-Git-Url: https://git.kernelconcepts.de/?p=karo-tx-uboot.git;a=blobdiff_plain;f=include%2Fconfigs%2Ftx48.h;h=0281d2530de0852753d1a17dcf122e2b1e75969a;hp=63aa8268ed5380e926ca76870da3864c5c3ca28b;hb=cce4dee35eced4de9217a21bb7a6055205d759d6;hpb=dcd0b15449e1811dd1b9f2fda01e29392e494fcb diff --git a/include/configs/tx48.h b/include/configs/tx48.h index 63aa8268ed..0281d2530d 100644 --- a/include/configs/tx48.h +++ b/include/configs/tx48.h @@ -1,7 +1,7 @@ /* * tx48.h * - * Copyright (C) 2012 Lothar Waßmann + * Copyright (C) 2012-2014 Lothar Waßmann * * based on: am335x_evm * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/ @@ -13,8 +13,7 @@ #ifndef __CONFIG_H #define __CONFIG_H -#define CONFIG_OMAP -#define CONFIG_AM33XX +#define CONFIG_AM33XX /* must be set before including omap.h */ #include #include @@ -22,8 +21,9 @@ /* * Ka-Ro TX48 board - SoC configuration */ +#define CONFIG_OMAP #define CONFIG_AM33XX_GPIO -#define CONFIG_SYS_HZ 1000 /* Ticks per second */ +#define CONFIG_SYS_HZ 1000 /* Ticks per second */ #ifndef CONFIG_SPL_BUILD #define CONFIG_SKIP_LOWLEVEL_INIT @@ -71,11 +71,11 @@ */ #define CONFIG_SYS_LONGHELP #define CONFIG_SYS_PROMPT "TX48 U-Boot > " -#define CONFIG_SYS_CBSIZE 2048 /* Console I/O buffer size */ +#define CONFIG_SYS_CBSIZE 2048 /* Console I/O buffer size */ #define CONFIG_SYS_PBSIZE \ (CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16) /* Print buffer size */ -#define CONFIG_SYS_MAXARGS 64 /* Max number of command args */ +#define CONFIG_SYS_MAXARGS 256 /* Max number of command args */ #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE /* Boot argument buffer size */ #define CONFIG_VERSION_VARIABLE /* U-BOOT version */ @@ -89,17 +89,7 @@ * Flattened Device Tree (FDT) support */ #define CONFIG_OF_LIBFDT -#ifdef CONFIG_OF_LIBFDT /* set via cmdline parameter thru boards.cfg */ -#define CONFIG_FDT_FIXUP_PARTITIONS #define CONFIG_OF_BOARD_SETUP -#define CONFIG_MACH_TYPE (-1) -#define CONFIG_SYS_FDT_ADDR (PHYS_SDRAM_1 + SZ_16M) -#else -#ifndef MACH_TYPE_TIAM335EVM -#define MACH_TYPE_TIAM335EVM 3589 /* Until the next sync */ -#endif -#define CONFIG_MACH_TYPE MACH_TYPE_TIAM335EVM -#endif /* * Boot Linux @@ -115,57 +105,58 @@ #define CONFIG_ZERO_BOOTDELAY_CHECK #define CONFIG_SYS_AUTOLOAD "no" #define CONFIG_BOOTFILE "uImage" -#define CONFIG_BOOTARGS "console=ttyO0,115200 ro debug panic=1" -#define CONFIG_BOOTCOMMAND "run bootcmd_nand" +#define CONFIG_BOOTARGS "init=/linuxrc console=ttyO0,115200 ro debug panic=1" +#define CONFIG_BOOTCOMMAND "run bootcmd_${boot_mode} bootm_cmd" #define CONFIG_LOADADDR 83000000 +#define CONFIG_FDTADDR 81000000 #define CONFIG_SYS_LOAD_ADDR _pfx(0x, CONFIG_LOADADDR) +#define CONFIG_SYS_FDT_ADDR _pfx(0x, CONFIG_FDTADDR) #define CONFIG_U_BOOT_IMG_SIZE SZ_1M #define CONFIG_HW_WATCHDOG /* - * Extra Environments + * Extra Environment Settings */ -#ifdef CONFIG_OF_LIBFDT -#define TX48_BOOTM_CMD \ - "bootm_cmd=bootm ${loadaddr} - ${fdtaddr}\0" -#define TX48_MTDPARTS_CMD "" -#else -#define TX48_BOOTM_CMD \ - "bootm_cmd=bootm\0" -#define TX48_MTDPARTS_CMD " ${mtdparts}" -#endif +#define CONFIG_SYS_CPU_CLK_STR xstr(CONFIG_SYS_MPU_CLK) #define CONFIG_EXTRA_ENV_SETTINGS \ "autostart=no\0" \ "baseboard=stk5-v3\0" \ + "bootargs_jffs2=run default_bootargs;set bootargs ${bootargs}" \ + " root=/dev/mtdblock4 rootfstype=jffs2\0" \ "bootargs_mmc=run default_bootargs;set bootargs ${bootargs}" \ " root=/dev/mmcblk0p2 rootwait\0" \ - "bootargs_nand=run default_bootargs;set bootargs ${bootargs}" \ - " root=/dev/mtdblock4 rootfstype=jffs2\0" \ - "nfsroot=/tftpboot/rootfs\0" \ "bootargs_nfs=run default_bootargs;set bootargs ${bootargs}" \ - " root=/dev/nfs ip=dhcp nfsroot=${nfs_server}:${nfsroot},nolock\0"\ - "bootcmd_mmc=set autostart no;run bootargs_mmc;" \ - " fatload mmc 0 ${loadaddr} uImage;run bootm_cmd\0" \ - "bootcmd_nand=set autostart no;run bootargs_nand;" \ - " nboot linux;run bootm_cmd\0" \ - "bootcmd_net=set autostart no;run bootargs_nfs;dhcp;" \ - " run bootm_cmd\0" \ - TX48_BOOTM_CMD \ + " root=/dev/nfs nfsroot=${nfs_server}:${nfsroot},nolock" \ + " ip=dhcp\0" \ + "bootargs_ubifs=run default_bootargs;set bootargs ${bootargs}" \ + " ubi.mtd=rootfs root=ubi0:rootfs rootfstype=ubifs\0" \ + "bootcmd_jffs2=set autostart no;run bootargs_jffs2" \ + ";nboot linux\0" \ + "bootcmd_mmc=set autostart no;run bootargs_mmc" \ + ";fatload mmc 0 ${loadaddr} uImage\0" \ + "bootcmd_nand=set autostart no;run bootargs_ubifs" \ + ";nboot linux\0" \ + "bootcmd_net=set autoload y;set autostart n;run bootargs_nfs" \ + ";dhcp\0" \ + "bootm_cmd=bootm ${loadaddr} - ${fdtaddr}\0" \ + "boot_mode=nand\0" \ + "cpu_clk=" CONFIG_SYS_CPU_CLK_STR "\0" \ "default_bootargs=set bootargs " CONFIG_BOOTARGS \ - TX48_MTDPARTS_CMD \ - " ${append_bootargs}\0" \ - "cpu_clk=" xstr(CONFIG_SYS_MPU_CLK) "\0" \ - "fdtaddr=81000000\0" \ - "fdtsave=nand erase.part dtb;nand write ${fdtaddr} dtb ${fdtsize}\0" \ + " ${append_bootargs}\0" \ + "fdtaddr=" xstr(CONFIG_FDTADDR) "\0" \ + "fdtsave=fdt resize;nand erase.part dtb" \ + ";nand write ${fdtaddr} dtb ${fdtsize}\0" \ "mtdids=" MTDIDS_DEFAULT "\0" \ "mtdparts=" MTDPARTS_DEFAULT "\0" \ + "nfsroot=/tftpboot/rootfs\0" \ "otg_mode=device\0" \ "touchpanel=tsc2007\0" \ "video_mode=VGA\0" #define MTD_NAME "omap2-nand.0" #define MTDIDS_DEFAULT "nand0=" MTD_NAME +#define CONFIG_FDT_FIXUP_PARTITIONS /* * U-Boot Commands @@ -267,6 +258,7 @@ #define CONFIG_DOS_PARTITION #define CONFIG_CMD_FAT +#define CONFIG_FAT_WRITE #define CONFIG_CMD_EXT2 /* @@ -289,13 +281,13 @@ xstr(CONFIG_ENV_RANGE) \ "(env)," \ xstr(CONFIG_ENV_RANGE) \ - "(env2),4m(linux),16m(rootfs),107904k(userfs),256k(dtb),512k@0x7f80000(bbt)ro" + "(env2),6m(linux),32m(rootfs),89216k(userfs),512k@0x7f00000(dtb),512k@0x7f80000(bbt)ro" #else #define MTDPARTS_DEFAULT "mtdparts=" MTD_NAME ":" \ "128k(u-boot-spl)," \ "1m(u-boot)," \ xstr(CONFIG_ENV_RANGE) \ - "(env),4m(linux),16m(rootfs),108288k(userfs),256k(dtb),512k@0x7f80000(bbt)ro" + "(env),6m(linux),32m(rootfs),89600k(userfs),512k@0x7f00000(dtb),512k@0x7f80000(bbt)ro" #endif #define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM_1