Dirk Behme | ad9bc8e | 2009-01-28 21:39:58 +0100 | [diff] [blame] | 1 | /* |
Sanjeev Premi | 741de26 | 2011-10-25 06:11:29 +0000 | [diff] [blame] | 2 | * Configuration settings for the TI OMAP3 EVM board. |
| 3 | * |
| 4 | * Copyright (C) 2006-2011 Texas Instruments Incorporated - http://www.ti.com/ |
| 5 | * |
Dirk Behme | ad9bc8e | 2009-01-28 21:39:58 +0100 | [diff] [blame] | 6 | * Author : |
| 7 | * Manikandan Pillai <mani.pillai@ti.com> |
| 8 | * Derived from Beagle Board and 3430 SDP code by |
| 9 | * Richard Woodruff <r-woodruff2@ti.com> |
| 10 | * Syed Mohammed Khasim <khasim@ti.com> |
| 11 | * |
| 12 | * Manikandan Pillai <mani.pillai@ti.com> |
| 13 | * |
Dirk Behme | ad9bc8e | 2009-01-28 21:39:58 +0100 | [diff] [blame] | 14 | * See file CREDITS for list of people who contributed to this |
| 15 | * project. |
| 16 | * |
| 17 | * This program is free software; you can redistribute it and/or |
| 18 | * modify it under the terms of the GNU General Public License as |
| 19 | * published by the Free Software Foundation; either version 2 of |
| 20 | * the License, or (at your option) any later version. |
| 21 | * |
| 22 | * This program is distributed in the hope that it will be useful, |
| 23 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 24 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 25 | * GNU General Public License for more details. |
| 26 | * |
| 27 | * You should have received a copy of the GNU General Public License |
| 28 | * along with this program; if not, write to the Free Software |
| 29 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, |
| 30 | * MA 02111-1307 USA |
| 31 | */ |
| 32 | |
Sanjeev Premi | 741de26 | 2011-10-25 06:11:29 +0000 | [diff] [blame] | 33 | #ifndef __OMAP3EVM_CONFIG_H |
| 34 | #define __OMAP3EVM_CONFIG_H |
| 35 | |
| 36 | #include <asm/arch/cpu.h> |
| 37 | #include <asm/arch/omap3.h> |
| 38 | |
Sanjeev Premi | 741de26 | 2011-10-25 06:11:29 +0000 | [diff] [blame] | 39 | /* ---------------------------------------------------------------------------- |
| 40 | * Supported U-boot commands |
| 41 | * ---------------------------------------------------------------------------- |
| 42 | */ |
Sanjeev Premi | 741de26 | 2011-10-25 06:11:29 +0000 | [diff] [blame] | 43 | #include <config_cmd_default.h> |
| 44 | |
Sanjeev Premi | 3970884 | 2011-10-25 06:11:30 +0000 | [diff] [blame] | 45 | #define CONFIG_CMD_EXT2 |
| 46 | #define CONFIG_CMD_FAT |
| 47 | #define CONFIG_CMD_JFFS2 |
Sanjeev Premi | 741de26 | 2011-10-25 06:11:29 +0000 | [diff] [blame] | 48 | |
Sanjeev Premi | 3970884 | 2011-10-25 06:11:30 +0000 | [diff] [blame] | 49 | #define CONFIG_CMD_I2C |
| 50 | #define CONFIG_CMD_MMC |
| 51 | #define CONFIG_CMD_NAND |
Sanjeev Premi | 741de26 | 2011-10-25 06:11:29 +0000 | [diff] [blame] | 52 | #define CONFIG_CMD_DHCP |
| 53 | #define CONFIG_CMD_PING |
| 54 | |
| 55 | #undef CONFIG_CMD_FLASH /* flinfo, erase, protect */ |
| 56 | #undef CONFIG_CMD_FPGA /* FPGA configuration Support */ |
| 57 | #undef CONFIG_CMD_IMI /* iminfo */ |
| 58 | #undef CONFIG_CMD_IMLS /* List all found images */ |
| 59 | |
| 60 | /* ---------------------------------------------------------------------------- |
| 61 | * Supported U-boot features |
| 62 | * ---------------------------------------------------------------------------- |
| 63 | */ |
| 64 | #define CONFIG_SYS_LONGHELP |
| 65 | #define CONFIG_SYS_HUSH_PARSER |
| 66 | |
| 67 | /* Display CPU and Board information */ |
| 68 | #define CONFIG_DISPLAY_CPUINFO |
| 69 | #define CONFIG_DISPLAY_BOARDINFO |
| 70 | |
| 71 | /* Allow to overwrite serial and ethaddr */ |
| 72 | #define CONFIG_ENV_OVERWRITE |
| 73 | |
| 74 | /* Add auto-completion support */ |
| 75 | #define CONFIG_AUTO_COMPLETE |
| 76 | |
| 77 | /* ---------------------------------------------------------------------------- |
| 78 | * Supported hardware |
| 79 | * ---------------------------------------------------------------------------- |
| 80 | */ |
| 81 | |
| 82 | /* MMC */ |
| 83 | #define CONFIG_MMC |
| 84 | #define CONFIG_GENERIC_MMC |
| 85 | #define CONFIG_OMAP_HSMMC |
Tom Rini | 673283f | 2011-11-18 12:48:09 +0000 | [diff] [blame] | 86 | |
| 87 | /* SPL */ |
| 88 | #define CONFIG_SPL_MMC_SUPPORT |
| 89 | #define CONFIG_SPL_FAT_SUPPORT |
| 90 | #define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 /* address 0x60000 */ |
| 91 | #define CONFIG_SYS_U_BOOT_MAX_SIZE_SECTORS 0x200 /* 256 KB */ |
| 92 | #define CONFIG_SYS_MMC_SD_FAT_BOOT_PARTITION 1 |
| 93 | #define CONFIG_SPL_FAT_LOAD_PAYLOAD_NAME "u-boot.img" |
| 94 | |
| 95 | /* Partition tables */ |
| 96 | /* Only need DOS partition support for SPL, currently */ |
| 97 | #ifndef CONFIG_SPL_BUILD |
Sanjeev Premi | 35e3f6d | 2011-11-16 10:20:50 -0500 | [diff] [blame] | 98 | #define CONFIG_EFI_PARTITION |
Tom Rini | 673283f | 2011-11-18 12:48:09 +0000 | [diff] [blame] | 99 | #endif |
| 100 | #define CONFIG_DOS_PARTITION |
Sanjeev Premi | 741de26 | 2011-10-25 06:11:29 +0000 | [diff] [blame] | 101 | |
| 102 | /* USB |
| 103 | * |
| 104 | * Enable CONFIG_MUSB_HCD for Host functionalities MSC, keyboard |
| 105 | * Enable CONFIG_MUSB_UDD for Device functionalities. |
| 106 | */ |
| 107 | #define CONFIG_USB_OMAP3 |
| 108 | #define CONFIG_MUSB_HCD |
| 109 | /* #define CONFIG_MUSB_UDC */ |
| 110 | |
Tom Rini | 673283f | 2011-11-18 12:48:09 +0000 | [diff] [blame] | 111 | /* NAND SPL */ |
| 112 | #define CONFIG_SPL_NAND_SIMPLE |
| 113 | #define CONFIG_SPL_NAND_SUPPORT |
| 114 | #define CONFIG_SYS_NAND_5_ADDR_CYCLE |
| 115 | #define CONFIG_SYS_NAND_PAGE_COUNT 64 |
| 116 | #define CONFIG_SYS_NAND_PAGE_SIZE 2048 |
| 117 | #define CONFIG_SYS_NAND_OOBSIZE 64 |
| 118 | #define CONFIG_SYS_NAND_BLOCK_SIZE (128*1024) |
| 119 | #define CONFIG_SYS_NAND_BAD_BLOCK_POS 0 |
| 120 | #define CONFIG_SYS_NAND_ECCPOS {2, 3, 4, 5, 6, 7, 8, 9,\ |
| 121 | 10, 11, 12, 13} |
| 122 | #define CONFIG_SYS_NAND_ECCSIZE 512 |
| 123 | #define CONFIG_SYS_NAND_ECCBYTES 3 |
| 124 | #define CONFIG_SYS_NAND_ECCSTEPS (CONFIG_SYS_NAND_PAGE_SIZE / \ |
| 125 | CONFIG_SYS_NAND_ECCSIZE) |
| 126 | #define CONFIG_SYS_NAND_ECCTOTAL (CONFIG_SYS_NAND_ECCBYTES * \ |
| 127 | CONFIG_SYS_NAND_ECCSTEPS) |
| 128 | #define CONFIG_SYS_NAND_U_BOOT_START CONFIG_SYS_TEXT_BASE |
| 129 | #define CONFIG_SYS_NAND_U_BOOT_OFFS 0x80000 |
| 130 | |
Sanjeev Premi | 741de26 | 2011-10-25 06:11:29 +0000 | [diff] [blame] | 131 | /* ----------------------------------------------------------------------------- |
Sanjeev Premi | 3970884 | 2011-10-25 06:11:30 +0000 | [diff] [blame] | 132 | * Include common board configuration |
Sanjeev Premi | 741de26 | 2011-10-25 06:11:29 +0000 | [diff] [blame] | 133 | * ----------------------------------------------------------------------------- |
| 134 | */ |
Sanjeev Premi | 3970884 | 2011-10-25 06:11:30 +0000 | [diff] [blame] | 135 | #include "omap3_evm_common.h" |
Sanjeev Premi | ee8e225 | 2011-10-25 06:11:28 +0000 | [diff] [blame] | 136 | |
| 137 | /* ----------------------------------------------------------------------------- |
| 138 | * Default environment |
| 139 | * ----------------------------------------------------------------------------- |
Tom Rix | fccc0fc | 2009-06-28 12:52:31 -0500 | [diff] [blame] | 140 | */ |
Dirk Behme | ad9bc8e | 2009-01-28 21:39:58 +0100 | [diff] [blame] | 141 | #define CONFIG_BOOTDELAY 10 |
Sanjeev Premi | 136cf92 | 2009-05-15 23:48:37 +0200 | [diff] [blame] | 142 | |
Dirk Behme | ad9bc8e | 2009-01-28 21:39:58 +0100 | [diff] [blame] | 143 | #define CONFIG_EXTRA_ENV_SETTINGS \ |
| 144 | "loadaddr=0x82000000\0" \ |
Ajay Kumar Gupta | 73c8640 | 2009-11-04 15:58:23 -0600 | [diff] [blame] | 145 | "usbtty=cdc_acm\0" \ |
Vaibhav Hiremath | dcc4f38 | 2011-09-03 21:42:35 -0400 | [diff] [blame] | 146 | "mmcdev=0\0" \ |
Sanjeev Premi | effeda5 | 2011-09-23 05:25:28 +0000 | [diff] [blame] | 147 | "console=ttyO0,115200n8\0" \ |
Dirk Behme | ad9bc8e | 2009-01-28 21:39:58 +0100 | [diff] [blame] | 148 | "mmcargs=setenv bootargs console=${console} " \ |
| 149 | "root=/dev/mmcblk0p2 rw " \ |
| 150 | "rootfstype=ext3 rootwait\0" \ |
| 151 | "nandargs=setenv bootargs console=${console} " \ |
| 152 | "root=/dev/mtdblock4 rw " \ |
| 153 | "rootfstype=jffs2\0" \ |
Vaibhav Hiremath | dcc4f38 | 2011-09-03 21:42:35 -0400 | [diff] [blame] | 154 | "loadbootscript=fatload mmc ${mmcdev} ${loadaddr} boot.scr\0" \ |
Dirk Behme | ad9bc8e | 2009-01-28 21:39:58 +0100 | [diff] [blame] | 155 | "bootscript=echo Running bootscript from mmc ...; " \ |
Wolfgang Denk | 74de7ae | 2009-04-01 23:34:12 +0200 | [diff] [blame] | 156 | "source ${loadaddr}\0" \ |
Vaibhav Hiremath | dcc4f38 | 2011-09-03 21:42:35 -0400 | [diff] [blame] | 157 | "loaduimage=fatload mmc ${mmcdev} ${loadaddr} uImage\0" \ |
Dirk Behme | ad9bc8e | 2009-01-28 21:39:58 +0100 | [diff] [blame] | 158 | "mmcboot=echo Booting from mmc ...; " \ |
| 159 | "run mmcargs; " \ |
| 160 | "bootm ${loadaddr}\0" \ |
| 161 | "nandboot=echo Booting from nand ...; " \ |
| 162 | "run nandargs; " \ |
| 163 | "onenand read ${loadaddr} 280000 400000; " \ |
| 164 | "bootm ${loadaddr}\0" \ |
| 165 | |
| 166 | #define CONFIG_BOOTCOMMAND \ |
Vaibhav Hiremath | dcc4f38 | 2011-09-03 21:42:35 -0400 | [diff] [blame] | 167 | "if mmc rescan ${mmcdev}; then " \ |
Dirk Behme | ad9bc8e | 2009-01-28 21:39:58 +0100 | [diff] [blame] | 168 | "if run loadbootscript; then " \ |
| 169 | "run bootscript; " \ |
| 170 | "else " \ |
| 171 | "if run loaduimage; then " \ |
| 172 | "run mmcboot; " \ |
| 173 | "else run nandboot; " \ |
| 174 | "fi; " \ |
| 175 | "fi; " \ |
| 176 | "else run nandboot; fi" |
| 177 | |
Sanjeev Premi | 741de26 | 2011-10-25 06:11:29 +0000 | [diff] [blame] | 178 | #endif /* __OMAP3EVM_CONFIG_H */ |