1
2
3
4
5
6
7
8
9
10
11
12
13#ifndef __CONFIG_H
14#define __CONFIG_H
15
16#ifdef CONFIG_36BIT
17#define CONFIG_PHYS_64BIT
18#endif
19
20
21#define CONFIG_BOOKE 1
22#define CONFIG_E500 1
23#define CONFIG_MPC8548 1
24#define CONFIG_MPC8548CDS 1
25
26#ifndef CONFIG_SYS_TEXT_BASE
27#define CONFIG_SYS_TEXT_BASE 0xfff80000
28#endif
29
30#define CONFIG_SYS_SRIO
31#define CONFIG_SRIO1
32
33#define CONFIG_PCI
34#define CONFIG_PCI1
35#define CONFIG_PCIE1
36#undef CONFIG_PCI2
37#define CONFIG_FSL_PCI_INIT 1
38#define CONFIG_PCI_INDIRECT_BRIDGE 1
39#define CONFIG_FSL_PCIE_RESET 1
40#define CONFIG_SYS_PCI_64BIT 1
41
42#define CONFIG_TSEC_ENET
43#define CONFIG_ENV_OVERWRITE
44#define CONFIG_INTERRUPTS
45#define CONFIG_FSL_LAW 1
46
47#define CONFIG_FSL_VIA
48
49#ifndef __ASSEMBLY__
50extern unsigned long get_clock_freq(void);
51#endif
52#define CONFIG_SYS_CLK_FREQ get_clock_freq()
53
54
55
56
57#define CONFIG_L2_CACHE
58#define CONFIG_BTB
59
60
61
62
63#define CONFIG_ENABLE_36BIT_PHYS 1
64
65#ifdef CONFIG_PHYS_64BIT
66#define CONFIG_ADDR_MAP
67#define CONFIG_SYS_NUM_ADDR_MAP 16
68#endif
69
70#define CONFIG_SYS_MEMTEST_START 0x00200000
71#define CONFIG_SYS_MEMTEST_END 0x00400000
72
73#define CONFIG_SYS_CCSRBAR 0xe0000000
74#define CONFIG_SYS_CCSRBAR_PHYS_LOW CONFIG_SYS_CCSRBAR
75
76
77#define CONFIG_SYS_FSL_DDR2
78#undef CONFIG_FSL_DDR_INTERACTIVE
79#define CONFIG_SPD_EEPROM
80#define CONFIG_DDR_SPD
81
82#define CONFIG_DDR_ECC
83#define CONFIG_ECC_INIT_VIA_DDRCONTROLLER
84#define CONFIG_MEM_INIT_VALUE 0xDeadBeef
85
86#define CONFIG_SYS_DDR_SDRAM_BASE 0x00000000
87#define CONFIG_SYS_SDRAM_BASE CONFIG_SYS_DDR_SDRAM_BASE
88
89#define CONFIG_NUM_DDR_CONTROLLERS 1
90#define CONFIG_DIMM_SLOTS_PER_CTLR 1
91#define CONFIG_CHIP_SELECTS_PER_CTRL (2 * CONFIG_DIMM_SLOTS_PER_CTLR)
92
93
94#define SPD_EEPROM_ADDRESS 0x51
95
96
97#ifndef CONFIG_SPD_EEPROM
98#error ("CONFIG_SPD_EEPROM is required")
99#endif
100
101#undef CONFIG_CLOCKS_IN_MHZ
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168#define CONFIG_SYS_FLASH_BASE 0xff000000
169#ifdef CONFIG_PHYS_64BIT
170#define CONFIG_SYS_FLASH_BASE_PHYS 0xfff000000ull
171#else
172#define CONFIG_SYS_FLASH_BASE_PHYS CONFIG_SYS_FLASH_BASE
173#endif
174
175#define CONFIG_SYS_BR0_PRELIM \
176 (BR_PHYS_ADDR(CONFIG_SYS_FLASH_BASE_PHYS + 0x800000) | BR_PS_16 | BR_V)
177#define CONFIG_SYS_BR1_PRELIM \
178 (BR_PHYS_ADDR(CONFIG_SYS_FLASH_BASE_PHYS) | BR_PS_16 | BR_V)
179
180#define CONFIG_SYS_OR0_PRELIM 0xff806e65
181#define CONFIG_SYS_OR1_PRELIM 0xff806e65
182
183#define CONFIG_SYS_FLASH_BANKS_LIST \
184 {CONFIG_SYS_FLASH_BASE_PHYS + 0x800000, CONFIG_SYS_FLASH_BASE_PHYS}
185#define CONFIG_SYS_MAX_FLASH_BANKS 2
186#define CONFIG_SYS_MAX_FLASH_SECT 128
187#undef CONFIG_SYS_FLASH_CHECKSUM
188#define CONFIG_SYS_FLASH_ERASE_TOUT 60000
189#define CONFIG_SYS_FLASH_WRITE_TOUT 500
190
191#define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE
192
193#define CONFIG_FLASH_CFI_DRIVER
194#define CONFIG_SYS_FLASH_CFI
195#define CONFIG_SYS_FLASH_EMPTY_INFO
196
197#define CONFIG_HWCONFIG
198
199
200
201
202#define CONFIG_SYS_LBC_SDRAM_BASE 0xf0000000
203#ifdef CONFIG_PHYS_64BIT
204#define CONFIG_SYS_LBC_SDRAM_BASE_PHYS 0xff0000000ull
205#else
206#define CONFIG_SYS_LBC_SDRAM_BASE_PHYS CONFIG_SYS_LBC_SDRAM_BASE
207#endif
208#define CONFIG_SYS_LBC_SDRAM_SIZE 64
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228#define CONFIG_SYS_BR2_PRELIM \
229 (BR_PHYS_ADDR(CONFIG_SYS_LBC_SDRAM_BASE_PHYS) \
230 | BR_PS_32 | (3<<BR_MSEL_SHIFT) | BR_V)
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246#define CONFIG_SYS_OR2_PRELIM 0xfc006901
247
248#define CONFIG_SYS_LBC_LCRR 0x00030004
249#define CONFIG_SYS_LBC_LBCR 0x00000000
250#define CONFIG_SYS_LBC_LSRT 0x20000000
251#define CONFIG_SYS_LBC_MRTPR 0x00000000
252
253
254
255
256
257
258
259#define CONFIG_SYS_LBC_LSDMR_COMMON ( LSDMR_RFCR16 \
260 | LSDMR_PRETOACT7 \
261 | LSDMR_ACTTORW7 \
262 | LSDMR_BL8 \
263 | LSDMR_WRC4 \
264 | LSDMR_CL3 \
265 | LSDMR_RFEN \
266 )
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298#define CONFIG_FSL_CADMUS
299
300#define CADMUS_BASE_ADDR 0xf8000000
301#ifdef CONFIG_PHYS_64BIT
302#define CADMUS_BASE_ADDR_PHYS 0xff8000000ull
303#else
304#define CADMUS_BASE_ADDR_PHYS CADMUS_BASE_ADDR
305#endif
306#define CONFIG_SYS_BR3_PRELIM \
307 (BR_PHYS_ADDR(CADMUS_BASE_ADDR_PHYS) | BR_PS_8 | BR_V)
308#define CONFIG_SYS_OR3_PRELIM 0xfff00ff7
309
310#define CONFIG_SYS_INIT_RAM_LOCK 1
311#define CONFIG_SYS_INIT_RAM_ADDR 0xe4010000
312#define CONFIG_SYS_INIT_RAM_SIZE 0x4000
313
314#define CONFIG_SYS_GBL_DATA_OFFSET (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
315#define CONFIG_SYS_INIT_SP_OFFSET CONFIG_SYS_GBL_DATA_OFFSET
316
317#define CONFIG_SYS_MONITOR_LEN (256 * 1024)
318#define CONFIG_SYS_MALLOC_LEN (1024 * 1024)
319
320
321#define CONFIG_CONS_INDEX 2
322#define CONFIG_SYS_NS16550
323#define CONFIG_SYS_NS16550_SERIAL
324#define CONFIG_SYS_NS16550_REG_SIZE 1
325#define CONFIG_SYS_NS16550_CLK get_bus_freq(0)
326
327#define CONFIG_SYS_BAUDRATE_TABLE \
328 {300, 600, 1200, 2400, 4800, 9600, 19200, 38400,115200}
329
330#define CONFIG_SYS_NS16550_COM1 (CONFIG_SYS_CCSRBAR+0x4500)
331#define CONFIG_SYS_NS16550_COM2 (CONFIG_SYS_CCSRBAR+0x4600)
332
333
334#define CONFIG_SYS_HUSH_PARSER
335
336
337#define CONFIG_OF_LIBFDT 1
338#define CONFIG_OF_BOARD_SETUP 1
339#define CONFIG_OF_STDOUT_VIA_ALIAS 1
340
341
342
343
344#define CONFIG_SYS_I2C
345#define CONFIG_SYS_I2C_FSL
346#define CONFIG_SYS_FSL_I2C_SPEED 400000
347#define CONFIG_SYS_FSL_I2C_SLAVE 0x7F
348#define CONFIG_SYS_FSL_I2C_OFFSET 0x3000
349#define CONFIG_SYS_I2C_NOPROBES { {0, 0x69} }
350
351
352#define CONFIG_ID_EEPROM
353#define CONFIG_SYS_I2C_EEPROM_CCID
354#define CONFIG_SYS_ID_EEPROM
355#define CONFIG_SYS_I2C_EEPROM_ADDR 0x57
356#define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 2
357
358
359
360
361
362#define CONFIG_SYS_PCI1_MEM_VIRT 0x80000000
363#ifdef CONFIG_PHYS_64BIT
364#define CONFIG_SYS_PCI1_MEM_BUS 0xe0000000
365#define CONFIG_SYS_PCI1_MEM_PHYS 0xc00000000ull
366#else
367#define CONFIG_SYS_PCI1_MEM_BUS 0x80000000
368#define CONFIG_SYS_PCI1_MEM_PHYS 0x80000000
369#endif
370#define CONFIG_SYS_PCI1_MEM_SIZE 0x20000000
371#define CONFIG_SYS_PCI1_IO_VIRT 0xe2000000
372#define CONFIG_SYS_PCI1_IO_BUS 0x00000000
373#ifdef CONFIG_PHYS_64BIT
374#define CONFIG_SYS_PCI1_IO_PHYS 0xfe2000000ull
375#else
376#define CONFIG_SYS_PCI1_IO_PHYS 0xe2000000
377#endif
378#define CONFIG_SYS_PCI1_IO_SIZE 0x00100000
379
380#ifdef CONFIG_PCIE1
381#define CONFIG_SYS_PCIE1_NAME "Slot"
382#define CONFIG_SYS_PCIE1_MEM_VIRT 0xa0000000
383#ifdef CONFIG_PHYS_64BIT
384#define CONFIG_SYS_PCIE1_MEM_BUS 0xe0000000
385#define CONFIG_SYS_PCIE1_MEM_PHYS 0xc20000000ull
386#else
387#define CONFIG_SYS_PCIE1_MEM_BUS 0xa0000000
388#define CONFIG_SYS_PCIE1_MEM_PHYS 0xa0000000
389#endif
390#define CONFIG_SYS_PCIE1_MEM_SIZE 0x20000000
391#define CONFIG_SYS_PCIE1_IO_VIRT 0xe3000000
392#define CONFIG_SYS_PCIE1_IO_BUS 0x00000000
393#ifdef CONFIG_PHYS_64BIT
394#define CONFIG_SYS_PCIE1_IO_PHYS 0xfe3000000ull
395#else
396#define CONFIG_SYS_PCIE1_IO_PHYS 0xe3000000
397#endif
398#define CONFIG_SYS_PCIE1_IO_SIZE 0x00100000
399#endif
400
401
402
403
404#define CONFIG_SYS_SRIO1_MEM_VIRT 0xc0000000
405#ifdef CONFIG_PHYS_64BIT
406#define CONFIG_SYS_SRIO1_MEM_PHYS 0xc40000000ull
407#else
408#define CONFIG_SYS_SRIO1_MEM_PHYS 0xc0000000
409#endif
410#define CONFIG_SYS_SRIO1_MEM_SIZE 0x20000000
411
412#ifdef CONFIG_LEGACY
413#define BRIDGE_ID 17
414#define VIA_ID 2
415#else
416#define BRIDGE_ID 28
417#define VIA_ID 4
418#endif
419
420#if defined(CONFIG_PCI)
421
422#define CONFIG_PCI_PNP
423
424#undef CONFIG_EEPRO100
425#undef CONFIG_TULIP
426#define CONFIG_E1000
427
428#define CONFIG_PCI_SCAN_SHOW
429
430#endif
431
432
433#if defined(CONFIG_TSEC_ENET)
434
435#define CONFIG_MII 1
436#define CONFIG_TSEC1 1
437#define CONFIG_TSEC1_NAME "eTSEC0"
438#define CONFIG_TSEC2 1
439#define CONFIG_TSEC2_NAME "eTSEC1"
440#define CONFIG_TSEC3 1
441#define CONFIG_TSEC3_NAME "eTSEC2"
442#define CONFIG_TSEC4
443#define CONFIG_TSEC4_NAME "eTSEC3"
444#undef CONFIG_MPC85XX_FEC
445
446#define CONFIG_PHY_MARVELL
447
448#define TSEC1_PHY_ADDR 0
449#define TSEC2_PHY_ADDR 1
450#define TSEC3_PHY_ADDR 2
451#define TSEC4_PHY_ADDR 3
452
453#define TSEC1_PHYIDX 0
454#define TSEC2_PHYIDX 0
455#define TSEC3_PHYIDX 0
456#define TSEC4_PHYIDX 0
457#define TSEC1_FLAGS TSEC_GIGABIT
458#define TSEC2_FLAGS TSEC_GIGABIT
459#define TSEC3_FLAGS (TSEC_GIGABIT | TSEC_REDUCED)
460#define TSEC4_FLAGS (TSEC_GIGABIT | TSEC_REDUCED)
461
462
463#define CONFIG_ETHPRIME "eTSEC0"
464#define CONFIG_PHY_GIGE 1
465#endif
466
467
468
469
470#define CONFIG_ENV_IS_IN_FLASH 1
471#if CONFIG_SYS_MONITOR_BASE > 0xfff80000
472#define CONFIG_ENV_ADDR 0xfff80000
473#else
474#define CONFIG_ENV_ADDR (CONFIG_SYS_MONITOR_BASE - CONFIG_ENV_SECT_SIZE)
475#endif
476#define CONFIG_ENV_SECT_SIZE 0x20000
477#define CONFIG_ENV_SIZE 0x2000
478
479#define CONFIG_LOADS_ECHO 1
480#define CONFIG_SYS_LOADS_BAUD_CHANGE 1
481
482
483
484
485#define CONFIG_BOOTP_BOOTFILESIZE
486#define CONFIG_BOOTP_BOOTPATH
487#define CONFIG_BOOTP_GATEWAY
488#define CONFIG_BOOTP_HOSTNAME
489
490
491
492
493
494#include <config_cmd_default.h>
495
496#define CONFIG_CMD_PING
497#define CONFIG_CMD_I2C
498#define CONFIG_CMD_MII
499#define CONFIG_CMD_ELF
500#define CONFIG_CMD_IRQ
501#define CONFIG_CMD_SETEXPR
502#define CONFIG_CMD_REGINFO
503
504#if defined(CONFIG_PCI)
505 #define CONFIG_CMD_PCI
506#endif
507
508
509#undef CONFIG_WATCHDOG
510
511
512
513
514#define CONFIG_SYS_LONGHELP
515#define CONFIG_CMDLINE_EDITING
516#define CONFIG_AUTO_COMPLETE
517#define CONFIG_SYS_LOAD_ADDR 0x2000000
518#if defined(CONFIG_CMD_KGDB)
519#define CONFIG_SYS_CBSIZE 1024
520#else
521#define CONFIG_SYS_CBSIZE 256
522#endif
523#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE+sizeof(CONFIG_SYS_PROMPT)+16)
524#define CONFIG_SYS_MAXARGS 16
525#define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE
526
527
528
529
530
531
532#define CONFIG_SYS_BOOTMAPSZ (64 << 20)
533#define CONFIG_SYS_BOOTM_LEN (64 << 20)
534
535#if defined(CONFIG_CMD_KGDB)
536#define CONFIG_KGDB_BAUDRATE 230400
537#endif
538
539
540
541
542
543
544#if defined(CONFIG_TSEC_ENET)
545#define CONFIG_HAS_ETH0
546#define CONFIG_ETHADDR 00:E0:0C:00:00:FD
547#define CONFIG_HAS_ETH1
548#define CONFIG_ETH1ADDR 00:E0:0C:00:01:FD
549#define CONFIG_HAS_ETH2
550#define CONFIG_ETH2ADDR 00:E0:0C:00:02:FD
551#define CONFIG_HAS_ETH3
552#define CONFIG_ETH3ADDR 00:E0:0C:00:03:FD
553#endif
554
555#define CONFIG_IPADDR 192.168.1.253
556
557#define CONFIG_HOSTNAME unknown
558#define CONFIG_ROOTPATH "/nfsroot"
559#define CONFIG_BOOTFILE "8548cds/uImage.uboot"
560#define CONFIG_UBOOTPATH 8548cds/u-boot.bin
561
562#define CONFIG_SERVERIP 192.168.1.1
563#define CONFIG_GATEWAYIP 192.168.1.1
564#define CONFIG_NETMASK 255.255.255.0
565
566#define CONFIG_LOADADDR 1000000
567
568#define CONFIG_BOOTDELAY 10
569#undef CONFIG_BOOTARGS
570
571#define CONFIG_BAUDRATE 115200
572
573#define CONFIG_EXTRA_ENV_SETTINGS \
574 "hwconfig=fsl_ddr:ecc=off\0" \
575 "netdev=eth0\0" \
576 "uboot=" __stringify(CONFIG_UBOOTPATH) "\0" \
577 "tftpflash=tftpboot $loadaddr $uboot; " \
578 "protect off " __stringify(CONFIG_SYS_TEXT_BASE) \
579 " +$filesize; " \
580 "erase " __stringify(CONFIG_SYS_TEXT_BASE) \
581 " +$filesize; " \
582 "cp.b $loadaddr " __stringify(CONFIG_SYS_TEXT_BASE) \
583 " $filesize; " \
584 "protect on " __stringify(CONFIG_SYS_TEXT_BASE) \
585 " +$filesize; " \
586 "cmp.b $loadaddr " __stringify(CONFIG_SYS_TEXT_BASE) \
587 " $filesize\0" \
588 "consoledev=ttyS1\0" \
589 "ramdiskaddr=2000000\0" \
590 "ramdiskfile=ramdisk.uboot\0" \
591 "fdtaddr=c00000\0" \
592 "fdtfile=mpc8548cds.dtb\0"
593
594#define CONFIG_NFSBOOTCOMMAND \
595 "setenv bootargs root=/dev/nfs rw " \
596 "nfsroot=$serverip:$rootpath " \
597 "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \
598 "console=$consoledev,$baudrate $othbootargs;" \
599 "tftp $loadaddr $bootfile;" \
600 "tftp $fdtaddr $fdtfile;" \
601 "bootm $loadaddr - $fdtaddr"
602
603
604#define CONFIG_RAMBOOTCOMMAND \
605 "setenv bootargs root=/dev/ram rw " \
606 "console=$consoledev,$baudrate $othbootargs;" \
607 "tftp $ramdiskaddr $ramdiskfile;" \
608 "tftp $loadaddr $bootfile;" \
609 "tftp $fdtaddr $fdtfile;" \
610 "bootm $loadaddr $ramdiskaddr $fdtaddr"
611
612#define CONFIG_BOOTCOMMAND CONFIG_NFSBOOTCOMMAND
613
614#endif
615