]> git.karo-electronics.de Git - karo-tx-uboot.git/blob - include/configs/net2big_v2.h
9cf76d0435585d71672bf211942c6321827b9924
[karo-tx-uboot.git] / include / configs / net2big_v2.h
1 /*
2  * Copyright (C) 2011 Simon Guinot <sguinot@lacie.com>
3  *
4  * See file CREDITS for list of people who contributed to this
5  * project.
6  *
7  * This program is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License as
9  * published by the Free Software Foundation; either version 2 of
10  * the License, or (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  */
17
18 #ifndef _CONFIG_NET2BIG_V2_H
19 #define _CONFIG_NET2BIG_V2_H
20
21 /*
22  * Machine number information
23  */
24 #define CONFIG_IDENT_STRING             " 2Big v2"
25
26 /*
27  * High Level Configuration Options (easy to change)
28  */
29 #define CONFIG_FEROCEON_88FR131         /* CPU Core subversion */
30 #define CONFIG_KIRKWOOD                 /* SOC Family Name */
31 #define CONFIG_KW88F6281                /* SOC Name */
32 #define CONFIG_MACH_NET2BIG_V2          /* Machine type */
33 #define CONFIG_SKIP_LOWLEVEL_INIT       /* disable board lowlevel_init */
34
35 /*
36  * Commands configuration
37  */
38 #define CONFIG_SYS_NO_FLASH             /* Declare no flash (NOR/SPI) */
39 #include <config_cmd_default.h>
40 #define CONFIG_CMD_ENV
41 #define CONFIG_CMD_DHCP
42 #define CONFIG_CMD_PING
43 #define CONFIG_CMD_SF
44 #define CONFIG_CMD_I2C
45 #define CONFIG_CMD_IDE
46 #define CONFIG_CMD_USB
47
48 /*
49  * Core clock definition.
50  */
51 #define CONFIG_SYS_TCLK                 166000000 /* 166MHz */
52
53 /*
54  * mv-common.h should be defined after CMD configs since it used them
55  * to enable certain macros
56  */
57 #define CONFIG_NR_DRAM_BANKS            2
58 #include "mv-common.h"
59
60 /* Remove or override few declarations from mv-common.h */
61 #undef CONFIG_RBTREE
62 #undef CONFIG_ENV_SPI_MAX_HZ
63 #undef CONFIG_SYS_IDE_MAXBUS
64 #undef CONFIG_SYS_IDE_MAXDEVICE
65 #undef CONFIG_SYS_PROMPT
66 #define CONFIG_ENV_SPI_MAX_HZ           20000000 /* 20Mhz */
67 #define CONFIG_SYS_IDE_MAXBUS           1
68 #define CONFIG_SYS_IDE_MAXDEVICE        1
69 #define CONFIG_SYS_PROMPT               "2big2> "
70
71 /*
72  * Ethernet Driver configuration
73  */
74 #ifdef CONFIG_CMD_NET
75 #define CONFIG_MISC_INIT_R /* Call misc_init_r() to initialize MAC address */
76 #define CONFIG_MVGBE_PORTS              {1, 0} /* enable port 0 only */
77 #define CONFIG_NETCONSOLE
78 #endif
79
80 /*
81  * SATA Driver configuration
82  */
83 #ifdef CONFIG_MVSATA_IDE
84 #define CONFIG_SYS_ATA_IDE0_OFFSET      MV_SATA_PORT0_OFFSET
85 #define CONFIG_SYS_ATA_IDE1_OFFSET      MV_SATA_PORT1_OFFSET
86 #endif
87
88 /*
89  * Enable GPI0 support
90  */
91 #define CONFIG_KIRKWOOD_GPIO
92
93 /*
94  * Enable I2C support
95  */
96 #ifdef CONFIG_CMD_I2C
97 /* I2C EEPROM HT24LC04 (512B - 32 pages of 16 Bytes) */
98 #define CONFIG_CMD_EEPROM
99 #define CONFIG_SYS_I2C_EEPROM_ADDR              0x50
100 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS       4 /* 16-byte page size */
101 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN          1 /* 8-bit device address */
102 #endif /* CONFIG_CMD_I2C */
103
104 /*
105  * File systems support
106  */
107 #define CONFIG_CMD_EXT2
108 #define CONFIG_CMD_FAT
109
110 /*
111  * Use the HUSH parser
112  */
113 #define CONFIG_SYS_HUSH_PARSER
114 #define CONFIG_SYS_PROMPT_HUSH_PS2      "> "
115
116 /*
117  * Console configuration
118  */
119 #define CONFIG_CONSOLE_MUX
120 #define CONFIG_SYS_CONSOLE_IS_IN_ENV
121
122 /*
123  * Enable device tree support
124  */
125 #define CONFIG_OF_LIBFDT
126
127 /*
128  * Environment variables configurations
129  */
130 #define CONFIG_ENV_IS_IN_SPI_FLASH
131 #define CONFIG_ENV_SECT_SIZE            0x10000 /* 64KB */
132 #define CONFIG_ENV_SIZE                 0x1000  /* 4KB */
133 #define CONFIG_ENV_ADDR                 0x70000
134 #define CONFIG_ENV_OFFSET               0x70000 /* env starts here */
135
136 /*
137  * Default environment variables
138  */
139 #define CONFIG_BOOTARGS "console=ttyS0,115200"
140
141 #define CONFIG_BOOTCOMMAND                                      \
142         "dhcp && run netconsole; "                              \
143         "if run usbload || run diskload; then bootm; fi"
144
145 #define CONFIG_EXTRA_ENV_SETTINGS                               \
146         "stdin=serial\0"                                        \
147         "stdout=serial\0"                                       \
148         "stderr=serial\0"                                       \
149         "bootfile=uImage\0"                                     \
150         "loadaddr=0x800000\0"                                   \
151         "autoload=no\0"                                         \
152         "netconsole="                                           \
153                 "set stdin $stdin,nc; "                         \
154                 "set stdout $stdout,nc; "                       \
155                 "set stderr $stderr,nc;\0"                      \
156         "diskload=ide reset && "                                \
157                 "ext2load ide 0:1 $loadaddr /boot/$bootfile\0"  \
158         "usbload=usb start && "                                 \
159                 "fatload usb 0:1 $loadaddr /boot/$bootfile\0"
160
161 #endif /* _CONFIG_NET2BIG_V2_H */