xref: /OK3568_Linux_fs/u-boot/board/freescale/mpc8313erdb/README (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593SmuzhiyunFreescale MPC8313ERDB Board
2*4882a593Smuzhiyun-----------------------------------------
3*4882a593Smuzhiyun
4*4882a593Smuzhiyun1.	Board Switches and Jumpers
5*4882a593Smuzhiyun
6*4882a593Smuzhiyun	S3 is used to set CONFIG_SYS_RESET_SOURCE.
7*4882a593Smuzhiyun
8*4882a593Smuzhiyun	To boot the image at 0xFE000000 in NOR flash, use these DIP
9*4882a593Smuzhiyun	switch settings for S3 S4:
10*4882a593Smuzhiyun
11*4882a593Smuzhiyun	+------+	+------+
12*4882a593Smuzhiyun	|      |	| **** |
13*4882a593Smuzhiyun	| **** |	|      |
14*4882a593Smuzhiyun	+------+ ON	+------+ ON
15*4882a593Smuzhiyun	  4321		  4321
16*4882a593Smuzhiyun	(where the '*' indicates the position of the tab of the switch.)
17*4882a593Smuzhiyun
18*4882a593Smuzhiyun	To boot the image at the beginning of NAND flash, use these
19*4882a593Smuzhiyun	DIP switch settings for S3 S4:
20*4882a593Smuzhiyun
21*4882a593Smuzhiyun	+------+	+------+
22*4882a593Smuzhiyun	| *    |	|  *** |
23*4882a593Smuzhiyun	|  *** |	| *    |
24*4882a593Smuzhiyun	+------+ ON	+------+ ON
25*4882a593Smuzhiyun	  4321		  4321
26*4882a593Smuzhiyun	(where the '*' indicates the position of the tab of the switch.)
27*4882a593Smuzhiyun
28*4882a593Smuzhiyun	When booting from NAND, use u-boot-nand.bin, not u-boot.bin.
29*4882a593Smuzhiyun
30*4882a593Smuzhiyun2.	Memory Map
31*4882a593Smuzhiyun	The memory map looks like this:
32*4882a593Smuzhiyun
33*4882a593Smuzhiyun	0x0000_0000	0x07ff_ffff	DDR		 128M
34*4882a593Smuzhiyun	0x8000_0000	0x8fff_ffff	PCI MEM		 256M
35*4882a593Smuzhiyun	0x9000_0000	0x9fff_ffff	PCI_MMIO	 256M
36*4882a593Smuzhiyun	0xe000_0000	0xe00f_ffff	IMMR		 1M
37*4882a593Smuzhiyun	0xe200_0000	0xe20f_ffff	PCI IO		 16M
38*4882a593Smuzhiyun	0xe280_0000	0xe280_7fff	NAND FLASH (CS1) 32K
39*4882a593Smuzhiyun	0xf000_0000	0xf001_ffff	VSC7385 (CS2)	 128K
40*4882a593Smuzhiyun	0xfa00_0000	0xfa00_7fff	Board Status/	 32K
41*4882a593Smuzhiyun					LED Control (CS3)
42*4882a593Smuzhiyun	0xfe00_0000	0xfe7f_ffff	NOR FLASH (CS0)	 8M
43*4882a593Smuzhiyun
44*4882a593Smuzhiyun	When booting from NAND, NAND flash is CS0 and NOR flash
45*4882a593Smuzhiyun	is CS1.
46*4882a593Smuzhiyun
47*4882a593Smuzhiyun3.	Definitions
48*4882a593Smuzhiyun
49*4882a593Smuzhiyun3.1	Explanation of NEW definitions in:
50*4882a593Smuzhiyun
51*4882a593Smuzhiyun	include/configs/MPC8313ERDB.h
52*4882a593Smuzhiyun
53*4882a593Smuzhiyun	CONFIG_MPC83xx		MPC83xx family
54*4882a593Smuzhiyun	CONFIG_MPC831x		MPC831x specific
55*4882a593Smuzhiyun	CONFIG_MPC8313ERDB	MPC8313ERDB board specific
56*4882a593Smuzhiyun
57*4882a593Smuzhiyun4.	Compilation
58*4882a593Smuzhiyun
59*4882a593Smuzhiyun	Assuming you're using BASH (or similar) as your shell:
60*4882a593Smuzhiyun
61*4882a593Smuzhiyun	export CROSS_COMPILE=your-cross-compiler-prefix-
62*4882a593Smuzhiyun	make distclean
63*4882a593Smuzhiyun	make MPC8313ERDB_XXX_config
64*4882a593Smuzhiyun	(where XXX is:
65*4882a593Smuzhiyun	   33 - 33 MHz oscillator, boot from NOR flash
66*4882a593Smuzhiyun	   66 - 66 MHz oscillator, boot from NOR flash
67*4882a593Smuzhiyun	   NAND_33 - 33 MHz oscillator, boot from NAND flash
68*4882a593Smuzhiyun	   NAND_66 - 66 MHz oscillator, boot from NAND flash)
69*4882a593Smuzhiyun	make
70*4882a593Smuzhiyun
71*4882a593Smuzhiyun5.	Downloading and Flashing Images
72*4882a593Smuzhiyun
73*4882a593Smuzhiyun5.1	Reflash U-Boot Image using U-Boot
74*4882a593Smuzhiyun
75*4882a593Smuzhiyun	NOR flash:
76*4882a593Smuzhiyun
77*4882a593Smuzhiyun	=>run tftpflash
78*4882a593Smuzhiyun
79*4882a593Smuzhiyun	You may want to try
80*4882a593Smuzhiyun	=>tftpboot $loadaddr $uboot
81*4882a593Smuzhiyun	first, to make sure that the TFTP load will succeed before it
82*4882a593Smuzhiyun	goes ahead and wipes out your current firmware.  And of course,
83*4882a593Smuzhiyun	have an alternate means of programming the flash available
84*4882a593Smuzhiyun	if the new U-Boot doesn't boot.
85*4882a593Smuzhiyun
86*4882a593Smuzhiyun	NAND flash:
87*4882a593Smuzhiyun
88*4882a593Smuzhiyun	=>tftpboot $loadaddr <filename>
89*4882a593Smuzhiyun	=>nand erase 0 0x80000
90*4882a593Smuzhiyun	=>nand write $loadaddr 0 0x80000
91*4882a593Smuzhiyun
92*4882a593Smuzhiyun	...where 0x80000 is the filesize rounded up to
93*4882a593Smuzhiyun	the next 0x20000 increment.
94*4882a593Smuzhiyun
95*4882a593Smuzhiyun5.2	Downloading and Booting Linux Kernel
96*4882a593Smuzhiyun
97*4882a593Smuzhiyun	Ensure that all networking-related environment variables are set
98*4882a593Smuzhiyun	properly (including ipaddr, serverip, gatewayip (if needed),
99*4882a593Smuzhiyun	netmask, ethaddr, eth1addr, rootpath (if using NFS root),
100*4882a593Smuzhiyun	fdtfile, and bootfile).
101*4882a593Smuzhiyun
102*4882a593Smuzhiyun	Then, do one of the following, depending on whether you
103*4882a593Smuzhiyun	want an NFS root or a ramdisk root:
104*4882a593Smuzhiyun
105*4882a593Smuzhiyun	=>run nfsboot
106*4882a593Smuzhiyun	or
107*4882a593Smuzhiyun	=>run ramboot
108*4882a593Smuzhiyun
109*4882a593Smuzhiyun6	Notes
110*4882a593Smuzhiyun
111*4882a593Smuzhiyun	The console baudrate for MPC8313ERDB is 115200bps.
112