1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29#ifndef _CONFIG_DNS325_H
30#define _CONFIG_DNS325_H
31
32
33
34
35#define MACH_TYPE_DNS325 3800
36#define CONFIG_MACH_TYPE MACH_TYPE_DNS325
37#define CONFIG_IDENT_STRING "\nD-Link DNS-325"
38
39
40
41
42#define CONFIG_FEROCEON_88FR131
43#define CONFIG_KIRKWOOD
44#define CONFIG_KW88F6281
45#define CONFIG_SKIP_LOWLEVEL_INIT
46
47
48
49
50#define CONFIG_SYS_NO_FLASH
51#include <config_cmd_default.h>
52#define CONFIG_CMD_DHCP
53#define CONFIG_CMD_ENV
54#define CONFIG_CMD_NAND
55#define CONFIG_CMD_PING
56#define CONFIG_CMD_USB
57#define CONFIG_CMD_IDE
58#define CONFIG_CMD_DATE
59#define CONFIG_SYS_MVFS
60
61#define CONFIG_NR_DRAM_BANKS 1
62
63
64
65
66
67#include "mv-common.h"
68
69
70#undef CONFIG_SYS_PROMPT
71#define CONFIG_SYS_PROMPT "=> "
72
73
74
75
76#ifdef CONFIG_CMD_NET
77#define CONFIG_MVGBE_PORTS {1, 0}
78#define CONFIG_NETCONSOLE
79#endif
80
81
82
83
84#ifdef CONFIG_MVSATA_IDE
85#define CONFIG_SYS_ATA_IDE0_OFFSET MV_SATA_PORT0_OFFSET
86#define CONFIG_SYS_ATA_IDE1_OFFSET MV_SATA_PORT1_OFFSET
87#endif
88
89
90
91
92#ifdef CONFIG_CMD_DATE
93#define CONFIG_RTC_MV
94#endif
95
96
97
98
99#define CONFIG_KIRKWOOD_GPIO
100
101
102
103
104#define CONFIG_SYS_HUSH_PARSER
105#define CONFIG_SYS_PROMPT_HUSH_PS2 "> "
106
107
108
109
110#define CONFIG_CONSOLE_MUX
111#define CONFIG_SYS_CONSOLE_IS_IN_ENV
112
113
114
115
116#define CONFIG_OF_LIBFDT
117
118
119
120
121#define CONFIG_DISPLAY_CPUINFO
122
123
124
125
126#ifdef CONFIG_CMD_NAND
127#define CONFIG_ENV_IS_IN_NAND
128#define CONFIG_ENV_SECT_SIZE 0x20000
129#else
130#define CONFIG_ENV_IS_NOWHERE
131#endif
132
133#define CONFIG_ENV_SIZE 0x20000
134#define CONFIG_ENV_ADDR 0xe0000
135#define CONFIG_ENV_OFFSET 0xe0000
136
137
138
139
140#define MTDIDS_DEFAULT "nand0=orion_nand"
141
142#define MTDPARTS_DEFAULT "mtdparts=orion_nand:" \
143 "896k(u-boot),128k(u-boot-env),5m(kernel),-(rootfs)\0"
144
145#define CONFIG_EXTRA_ENV_SETTINGS \
146 "stdin=serial\0" \
147 "stdout=serial\0" \
148 "stderr=serial\0" \
149 "loadaddr=0x800000\0" \
150 "autoload=no\0" \
151 "console=ttyS0,115200\0" \
152 "mtdparts="MTDPARTS_DEFAULT \
153 "optargs=\0" \
154 "bootenv=uEnv.txt\0" \
155 "importbootenv=echo Importing environment ...; " \
156 "env import -t ${loadaddr} ${filesize}\0" \
157 "loadbootenv=fatload usb 0 ${loadaddr} ${bootenv}\0" \
158 "setbootargs=setenv bootargs console=${console} " \
159 "${optargs} " \
160 "${mtdparts} " \
161 "root=${bootenvroot} " \
162 "rootfstype=${bootenvrootfstype}\0" \
163 "subbootcmd=run setbootargs; " \
164 "if run bootenvloadimage; then " \
165 "bootm ${loadaddr};" \
166 "fi;\0" \
167 "nandroot=ubi0:rootfs ubi.mtd=rootfs\0" \
168 "nandrootfstype=ubifs\0" \
169 "nandloadimage=nand read ${loadaddr} kernel\0" \
170 "setnandbootenv=echo Booting from nand ...; " \
171 "setenv bootenvroot ${nandroot}; " \
172 "setenv bootenvrootfstype ${nandrootfstype}; " \
173 "setenv bootenvloadimage ${nandloadimage}\0"
174
175#define CONFIG_BOOTCOMMAND \
176 "if test -n ${bootenv} && usb start; then " \
177 "if run loadbootenv; then " \
178 "echo Loaded environment ${bootenv} from usb;" \
179 "run importbootenv;" \
180 "fi;" \
181 "if test -n ${bootenvcmd}; then " \
182 "echo Running bootenvcmd ...;" \
183 "run bootenvcmd;" \
184 "fi;" \
185 "fi;" \
186 "run setnandbootenv subbootcmd;"
187
188#endif
189