xref: /openbmc/u-boot/board/freescale/mpc8641hpcn/README (revision 57dc53a72460e8e301fa1cc7951b41db8e731485)
1702e6014SWolfgang DenkFreescale MPC8641HPCN board
2702e6014SWolfgang Denk===========================
3702e6014SWolfgang Denk
4702e6014SWolfgang DenkCreated 05/24/2006 Haiying Wang
5702e6014SWolfgang Denk-------------------------------
6702e6014SWolfgang Denk
7702e6014SWolfgang Denk1. Building U-Boot
8702e6014SWolfgang Denk------------------
9702e6014SWolfgang DenkThe 86xx HPCN code base is known to compile using:
10702e6014SWolfgang Denk    Binutils 2.15, Gcc 3.4.3, Glibc 2.3.3
11702e6014SWolfgang Denk
12702e6014SWolfgang Denk    $ make MPC8641HPCN_config
13702e6014SWolfgang Denk    Configuring for MPC8641HPCN board...
14702e6014SWolfgang Denk
15702e6014SWolfgang Denk    $ make
16702e6014SWolfgang Denk
17702e6014SWolfgang Denk
18702e6014SWolfgang Denk2. Switch and Jumper Setting
19702e6014SWolfgang Denk----------------------------
20702e6014SWolfgang DenkJumpers:
21702e6014SWolfgang Denk	J14 Pins 1-2 (near plcc32 socket)
22702e6014SWolfgang Denk
23702e6014SWolfgang DenkSwitches:
24702e6014SWolfgang Denk	SW1(1-5) = 01100	CONFIG_SYS_COREPLL	= 01000 :: CORE =   2:1
25702e6014SWolfgang Denk						  01100 :: CORE = 2.5:1
26702e6014SWolfgang Denk						  10000 :: CORE =   3:1
27702e6014SWolfgang Denk						  11100 :: CORE = 3.5:1
28702e6014SWolfgang Denk						  10100 :: CORE =   4:1
29702e6014SWolfgang Denk						  01110 :: CORE = 4.5:1
30702e6014SWolfgang Denk	SW1(6-8) = 001		CONFIG_SYS_SYSCLK	= 000	:: SYSCLK = 33MHz
31702e6014SWolfgang Denk						  001	:: SYSCLK = 40MHz
32702e6014SWolfgang Denk
33702e6014SWolfgang Denk	SW2(1-4) = 1100		CONFIG_SYS_CCBPLL	= 0010	:: 2X
34702e6014SWolfgang Denk						  0100	:: 4X
35702e6014SWolfgang Denk						  0110	:: 6X
36702e6014SWolfgang Denk						  1000	:: 8X
37702e6014SWolfgang Denk						  1010	:: 10X
38702e6014SWolfgang Denk						  1100	:: 12X
39702e6014SWolfgang Denk						  1110	:: 14X
40702e6014SWolfgang Denk						  0000	:: 16X
41702e6014SWolfgang Denk	SW2(5-8) = 1110		CONFIG_SYS_BOOTLOC	= 1110	:: boot 16-bit localbus
42702e6014SWolfgang Denk
43702e6014SWolfgang Denk	SW3(1-7) = 0011000	CONFIG_SYS_VID		= 0011000 :: VCORE = 1.2V
44702e6014SWolfgang Denk						  0100000 :: VCORE = 1.11V
45702e6014SWolfgang Denk	SW3(8)	 = 0		VCC_PLAT	= 0	:: VCC_PLAT = 1.2V
46702e6014SWolfgang Denk						  1	:: VCC_PLAT = 1.0V
47702e6014SWolfgang Denk
48702e6014SWolfgang Denk	SW4(1-2) = 11		CONFIG_SYS_HOSTMODE	= 11	:: both prots host/root
49702e6014SWolfgang Denk	SW4(3-4) = 11		CONFIG_SYS_BOOTSEQ	= 11	:: no boot seq
50702e6014SWolfgang Denk	SW4(5-8) = 0011		CONFIG_SYS_IOPORT	= 0011	:: both PEX
51702e6014SWolfgang Denk
52702e6014SWolfgang Denk	SW5(1)	 = 1		CONFIG_SYS_FLASHMAP	= 1	:: boot from flash
53702e6014SWolfgang Denk						  0	:: boot from PromJet
54702e6014SWolfgang Denk	SW5(2)	 = 1		CONFIG_SYS_FLASHBANK	= 1	:: swap upper/lower
55702e6014SWolfgang Denk							 halves (virtual banks)
56702e6014SWolfgang Denk						  0	:: normal
57702e6014SWolfgang Denk	SW5(3)	 = 0		CONFIG_SYS_FLASHWP	= 0	:: not protected
58702e6014SWolfgang Denk	SW5(4)	 = 0		CONFIG_SYS_PORTDIV	= 1	:: 2:1 for PD4
59702e6014SWolfgang Denk							   1:1 for PD6
60702e6014SWolfgang Denk	SW5(5-6) = 11		CONFIG_SYS_PIXISOPT	= 11	:: s/w determined
61702e6014SWolfgang Denk	SW5(7-8) = 11		CONFIG_SYS_LADOPT	= 11	:: s/w determined
62702e6014SWolfgang Denk
63702e6014SWolfgang Denk	SW6(1)	 = 1		CONFIG_SYS_CPUBOOT	= 1	:: no boot holdoff
64702e6014SWolfgang Denk	SW6(2)	 = 1		CONFIG_SYS_BOOTADDR	= 1	:: no traslation
65702e6014SWolfgang Denk	SW6(3-5) = 000		CONFIG_SYS_REFCLKSEL	= 000	:: 100MHZ
66702e6014SWolfgang Denk	SW6(6)	 = 1		CONFIG_SYS_SERROM_ADDR= 1	::
67702e6014SWolfgang Denk	SW6(7)	 = 1		CONFIG_SYS_MEMDEBUG	= 1	::
68702e6014SWolfgang Denk	SW6(8)	 = 1		CONFIG_SYS_DDRDEBUG	= 1	::
69702e6014SWolfgang Denk
70702e6014SWolfgang Denk	SW8(1)	 = 1		ACZ_SYNC	= 1	:: 48MHz on TP49
71702e6014SWolfgang Denk	SW8(2)	 = 1		ACB_SYNC	= 1	:: THRMTRIP disabled
72702e6014SWolfgang Denk	SW8(3)	 = 1		ACZ_SDOUT	= 1	:: p4 mode
73702e6014SWolfgang Denk	SW8(4)	 = 1		ACB_SDOUT	= 1	:: PATA freq. = 133MHz
74702e6014SWolfgang Denk	SW8(5)	 = 0		SUSLED		= 0	:: SouthBridge Mode
75702e6014SWolfgang Denk	SW8(6)	 = 0		SPREAD		= 0	:: REFCLK SSCG Disabled
76702e6014SWolfgang Denk	SW8(7)	 = 1		ACPWR		= 1	:: non-battery
77702e6014SWolfgang Denk	SW8(8)	 = 0		CONFIG_SYS_IDWP	= 0	:: write enable
78702e6014SWolfgang Denk
79702e6014SWolfgang Denk
80702e6014SWolfgang Denk3. Flash U-Boot
81702e6014SWolfgang Denk---------------
82702e6014SWolfgang DenkThe flash range 0xEF800000 to 0xEFFFFFFF can be divided into 2 halves.
83*a187559eSBin MengIt is possible to use either half to boot using U-Boot.  Switch 5 bit 2
84702e6014SWolfgang Denkis used for this purpose.
85702e6014SWolfgang Denk
86702e6014SWolfgang Denk0xEF800000 to 0xEFBFFFFF - 4MB
87702e6014SWolfgang Denk0xEFC00000 to 0xEFFFFFFF - 4MB
88702e6014SWolfgang DenkWhen this bit is 0, U-Boot is at 0xEFF00000.
89702e6014SWolfgang DenkWhen this bit is 1, U-Boot is at 0xEFB00000.
90702e6014SWolfgang Denk
91702e6014SWolfgang DenkUse the above mentioned flash commands to program the other half, and
92702e6014SWolfgang Denkuse switch 5, bit 2 to alternate between the halves.  Note: The booting
93702e6014SWolfgang Denkversion of U-Boot will always be at 0xEFF00000.
94702e6014SWolfgang Denk
95702e6014SWolfgang DenkTo Flash U-Boot into the booting bank (0xEFC00000 - 0xEFFFFFFF):
96702e6014SWolfgang Denk
97702e6014SWolfgang Denk	tftp 1000000 u-boot.bin
98702e6014SWolfgang Denk	protect off all
99702e6014SWolfgang Denk	erase eff00000 +$filesize
100702e6014SWolfgang Denk	cp.b 1000000 eff00000 $filesize
101702e6014SWolfgang Denk
102702e6014SWolfgang Denkor use tftpflash command:
103702e6014SWolfgang Denk	run tftpflash
104702e6014SWolfgang Denk
105*a187559eSBin MengTo Flash U-Boot into the alternative bank (0xEF800000 - 0xEFBFFFFF):
106702e6014SWolfgang Denk
107702e6014SWolfgang Denk	tftp 1000000 u-boot.bin
108702e6014SWolfgang Denk	erase efb00000 +$filesize
109702e6014SWolfgang Denk	cp.b 1000000 efb00000 $filesize
110702e6014SWolfgang Denk
111702e6014SWolfgang Denk
112702e6014SWolfgang Denk4. Memory Map
113702e6014SWolfgang Denk-------------
114702e6014SWolfgang DenkNOTE:  RIO and PCI are mutually exclusive, so they share an address
115702e6014SWolfgang Denk
116*a187559eSBin MengFor 32-bit U-Boot, devices are mapped so that the virtual address ==
117702e6014SWolfgang Denkthe physical address, and the map looks liks this:
118702e6014SWolfgang Denk
119702e6014SWolfgang Denk	Memory Range			Device		Size
120702e6014SWolfgang Denk	------------			------		----
121702e6014SWolfgang Denk	0x0000_0000	0x7fff_ffff	DDR		2G
122702e6014SWolfgang Denk	0x8000_0000	0x9fff_ffff	RIO MEM		512M
123702e6014SWolfgang Denk	0x8000_0000	0x9fff_ffff	PCI1/PEX1 MEM	512M
124702e6014SWolfgang Denk	0xa000_0000	0xbfff_ffff	PCI2/PEX2 MEM	512M
125702e6014SWolfgang Denk	0xffe0_0000	0xffef_ffff	CCSR		1M
126702e6014SWolfgang Denk	0xffdf_0000	0xffdf_7fff	PIXIS		8K
127702e6014SWolfgang Denk	0xffdf_8000	0xffdf_ffff	CF		8K
128702e6014SWolfgang Denk	0xf840_0000	0xf840_3fff	Stack space	32K
129702e6014SWolfgang Denk	0xffc0_0000	0xffc0_ffff	PCI1/PEX1 IO	64K
130702e6014SWolfgang Denk	0xffc1_0000	0xffc1_ffff	PCI2/PEX2 IO	64K
131702e6014SWolfgang Denk	0xef80_0000	0xefff_ffff	Flash		8M
132702e6014SWolfgang Denk
133*a187559eSBin MengFor 36-bit-enabled U-Boot, the virtual map is the same as for 32-bit.
134702e6014SWolfgang DenkHowever, the physical map is altered to reside in 36-bit space, as follows.
135702e6014SWolfgang DenkAddresses are no longer mapped with VA == PA.  All accesses from
136702e6014SWolfgang Denksoftware use the VA; the PA is only used for setting up windows
137702e6014SWolfgang Denkand mappings. Note that with the exception of PCI MEM and RIO, the low
138702e6014SWolfgang Denk 32 bits are the same as the VA above; only the top 4 bits vary:
139702e6014SWolfgang Denk
140702e6014SWolfgang Denk	Memory Range			Device		Size
141702e6014SWolfgang Denk	------------			------		----
142702e6014SWolfgang Denk	0x0_0000_0000	0x0_7fff_ffff	DDR		2G
143702e6014SWolfgang Denk	0xc_0000_0000	0xc_1fff_ffff	RIO MEM		512M
144702e6014SWolfgang Denk	0xc_0000_0000	0xc_1fff_ffff	PCI1/PEX1 MEM	512M
145702e6014SWolfgang Denk	0xc_2000_0000	0xc_3fff_ffff	PCI2/PEX2 MEM	512M
146702e6014SWolfgang Denk	0xf_ffe0_0000	0xf_ffef_ffff	CCSR		1M
147702e6014SWolfgang Denk	0xf_ffdf_0000	0xf_ffdf_7fff	PIXIS		8K
148702e6014SWolfgang Denk	0xf_ffdf_8000	0xf_ffdf_ffff	CF		8K
149702e6014SWolfgang Denk	0x0_f840_0000	0xf_f840_3fff	Stack space	32K
150702e6014SWolfgang Denk	0xf_ffc0_0000	0xf_ffc0_ffff	PCI1/PEX1 IO	64K
151702e6014SWolfgang Denk	0xf_ffc1_0000	0xf_ffc1_ffff	PCI2/PEX2 IO	64K
152702e6014SWolfgang Denk	0xf_ef80_0000	0xf_efff_ffff	Flash		8M
153702e6014SWolfgang Denk
154702e6014SWolfgang Denk5. pixis_reset command
155702e6014SWolfgang Denk--------------------
156702e6014SWolfgang DenkA new command, "pixis_reset", is introduced to reset mpc8641hpcn board
157702e6014SWolfgang Denkusing the FPGA sequencer.  When the board restarts, it has the option
158702e6014SWolfgang Denkof using either the current or alternate flash bank as the boot
159702e6014SWolfgang Denkimage, with or without the watchdog timer enabled, and finally with
160702e6014SWolfgang Denkor without frequency changes.
161702e6014SWolfgang Denk
162702e6014SWolfgang DenkUsage is;
163702e6014SWolfgang Denk
164702e6014SWolfgang Denk	pixis_reset
165702e6014SWolfgang Denk	pixis_reset altbank
166702e6014SWolfgang Denk	pixis_reset altbank wd
167702e6014SWolfgang Denk	pixis_reset altbank cf <SYSCLK freq> <COREPLL ratio> <MPXPLL ratio>
168702e6014SWolfgang Denk	pixis_reset cf <SYSCLK freq> <COREPLL ratio> <MPXPLL ratio>
169702e6014SWolfgang Denk
170702e6014SWolfgang DenkExamples;
171702e6014SWolfgang Denk
172702e6014SWolfgang Denk	/* reset to current bank, like "reset" command */
173702e6014SWolfgang Denk	pixis_reset
174702e6014SWolfgang Denk
175702e6014SWolfgang Denk	/* reset board but use the to alternate flash bank */
176702e6014SWolfgang Denk	pixis_reset altbank
177702e6014SWolfgang Denk
178702e6014SWolfgang Denk	/* reset board, use alternate flash bank with watchdog timer enabled*/
179702e6014SWolfgang Denk	pixis_reset altbank wd
180702e6014SWolfgang Denk
181702e6014SWolfgang Denk	/* reset board to alternate bank with frequency changed.
182702e6014SWolfgang Denk	 * 40 is SYSCLK, 2.5 is COREPLL ratio, 10 is MPXPLL ratio
183702e6014SWolfgang Denk	 */
184702e6014SWolfgang Denk	pixis-reset altbank cf 40 2.5 10
185702e6014SWolfgang Denk
186702e6014SWolfgang DenkValid clock choices are in the 8641 Reference Manuals.
187