summaryrefslogtreecommitdiff
path: root/doc/README.IPHASE4539
blob: d3db38ef54a12e9027f0bd974332b20e210fee65 (plain)
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
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
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
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
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
This file contains basic information on the port of U-Boot to IPHASE4539
(Interphase 4539 T1/E1/J1 PMC Communications Controller).
All the changes fit in the common U-Boot infrastructure, providing a new
IPHASE4539-specific entry in makefiles. To build U-Boot for IPHASE4539,
type "make IPHASE4539_config", edit the "include/config_IPHASE4539.h"
file if necessary, then type "make".


Common file modifications:
--------------------------

The following common files have been modified by this project:
(starting from the ppcboot-1.1.5/ directory)

MAKEALL				- IPHASE4539 entry added
Makefile			- IPHASE4539_config entry added


New files:
----------

The following new files have been added by this project:
(starting from the ppcboot-1.1.5/ directory)

board/iphase4539/		- board-specific directory
board/iphase4539/Makefile	- board-specific makefile
board/iphase4539/config.mk	- config file
board/iphase4539/flash.c	- flash driver (for AM29LV033C)
board/iphase4539/ppcboot.lds	- linker script
board/iphase4539/iphase4539.c	- ioport and memory initialization
include/config_IPHASE4539.h	- main configuration file


New configuration options:
--------------------------

CONFIG_IPHASE4539

	Main board-specific option (should be defined for IPHASE4539).


Acceptance criteria tests:
--------------------------

The following tests have been conducted to validate the port of U-Boot
to IPHASE4539:

1. Operation on serial console:

With SMC1 defined as console in the main configuration file, the U-Boot
output appeared on the serial terminal connected to the 2.5mm stereo jack
connector as follows:

------------------------------------------------------------------------------
=> help
autoscr - run script from memory
base    - print or set address offset
bdinfo  - print Board Info structure
bootm   - boot application image from memory
bootp   - boot image via network using BootP/TFTP protocol
bootd   - boot default, i.e., run 'bootcmd'
cmp     - memory compare
coninfo - print console devices and informations
cp      - memory copy
crc32   - checksum calculation
dcache  - enable or disable data cache
echo    - echo args to console
erase   - erase FLASH memory
flinfo  - print FLASH memory information
go      - start application at address 'addr'
help    - print online help
icache  - enable or disable instruction cache
iminfo  - print header information for application image
loadb   - load binary file over serial line (kermit mode)
loads   - load S-Record file over serial line
loop    - infinite loop on address range
md      - memory display
mm      - memory modify (auto-incrementing)
mtest   - simple RAM test
mw      - memory write (fill)
nm      - memory modify (constant address)
printenv- print environment variables
protect - enable or disable FLASH write protection
rarpboot- boot image via network using RARP/TFTP protocol
reset   - Perform RESET of the CPU
run     - run commands in an environment variable
saveenv - save environment variables to persistent storage
setenv  - set environment variables
sleep   - delay execution for some time
tftpboot- boot image via network using TFTP protocol
               and env variables ipaddr and serverip
version - print monitor version
?       - alias for 'help'
=>
------------------------------------------------------------------------------


2. Flash driver operation

The following sequence was performed to test the "flinfo" command:

------------------------------------------------------------------------------
=> flinfo

Bank # 1: AMD AM29LV033C (32 Mbit, uniform sectors)
  Size: 4 MB in 64 Sectors
  Sector Start Addresses:
    FF800000 (RO) FF810000 (RO) FF820000      FF830000      FF840000
    FF850000      FF860000      FF870000      FF880000      FF890000
    FF8A0000      FF8B0000      FF8C0000      FF8D0000      FF8E0000
    FF8F0000      FF900000      FF910000      FF920000      FF930000
    FF940000      FF950000      FF960000      FF970000      FF980000
    FF990000      FF9A0000      FF9B0000      FF9C0000      FF9D0000
    FF9E0000      FF9F0000      FFA00000      FFA10000      FFA20000
    FFA30000      FFA40000      FFA50000      FFA60000      FFA70000
    FFA80000      FFA90000      FFAA0000      FFAB0000      FFAC0000
    FFAD0000      FFAE0000      FFAF0000      FFB00000 (RO) FFB10000 (RO)
    FFB20000 (RO) FFB30000 (RO) FFB40000      FFB50000      FFB60000
    FFB70000      FFB80000      FFB90000      FFBA0000      FFBB0000
    FFBC0000      FFBD0000      FFBE0000      FFBF0000
------------------------------------------------------------------------------

Note: the Hardware Configuration Word (HWC) of the 8260 is on the
first sector of the flash and should not be touched. The U-Boot
environment variables are stored on second sector and U-Boot
starts at the address 0xFFB00000.


The following sequence was performed to test the erase command:

------------------------------------------------------------------------------
=> cp 0 ff880000 10
Copy to Flash... done
=> md ff880000 20
ff880000: ff000000 60000000 60000000 7c7f1b78    ....`...`...|..x
ff880010: 7c9e2378 7cbd2b78 7cdc3378 7cfb3b78    |.#x|.+x|.3x|.;x
ff880020: 3b000000 4811e0f5 48003719 480036a5    ;...H...H.7.H.6.
ff880030: 480036f9 48003731 48005c5d 7c7a1b78    H.6.H.71H.\]|z.x
ff880040: ffffffff ffffffff ffffffff ffffffff    ................
ff880050: ffffffff ffffffff ffffffff ffffffff    ................
ff880060: ffffffff ffffffff ffffffff ffffffff    ................
ff880070: ffffffff ffffffff ffffffff ffffffff    ................
=> erase ff880000 ff88ffff
Erase Flash from 0xff880000 to 0xff88ffff
.. done
Erased 1 sectors
=> md ff880000
ff880000: ffffffff ffffffff ffffffff ffffffff    ................
ff880010: ffffffff ffffffff ffffffff ffffffff    ................
ff880020: ffffffff ffffffff ffffffff ffffffff    ................
ff880030: ffffffff ffffffff ffffffff ffffffff    ................
ff880040: ffffffff ffffffff ffffffff ffffffff    ................
ff880050: ffffffff ffffffff ffffffff ffffffff    ................
ff880060: ffffffff ffffffff ffffffff ffffffff    ................
ff880070: ffffffff ffffffff ffffffff ffffffff    ................
=> cp 0 ff880000 10
Copy to Flash... done
=> md ff880000 20
ff880000: ff000000 60000000 60000000 7c7f1b78    ....`...`...|..x
ff880010: 7c9e2378 7cbd2b78 7cdc3378 7cfb3b78    |.#x|.+x|.3x|.;x
ff880020: 3b000000 4811e0f5 48003719 480036a5    ;...H...H.7.H.6.
ff880030: 480036f9 48003731 48005c5d 7c7a1b78    H.6.H.71H.\]|z.x
ff880040: ffffffff ffffffff ffffffff ffffffff    ................
ff880050: ffffffff ffffffff ffffffff ffffffff    ................
ff880060: ffffffff ffffffff ffffffff ffffffff    ................
ff880070: ffffffff ffffffff ffffffff ffffffff    ................
=> erase 1:8
Erase Flash Sectors 8-8 in Bank # 1
.. done
=> md ff880000 20
ff880000: ffffffff ffffffff ffffffff ffffffff    ................
ff880010: ffffffff ffffffff ffffffff ffffffff    ................
ff880020: ffffffff ffffffff ffffffff ffffffff    ................
ff880030: ffffffff ffffffff ffffffff ffffffff    ................
ff880040: ffffffff ffffffff ffffffff ffffffff    ................
ff880050: ffffffff ffffffff ffffffff ffffffff    ................
ff880060: ffffffff ffffffff ffffffff ffffffff    ................
ff880070: ffffffff ffffffff ffffffff ffffffff    ................
=> cp 0 ff880000 10
Copy to Flash... done
=> cp 0 ff890000 10
=> md ff880000 20
ff880000: ff000000 60000000 60000000 7c7f1b78    ....`...`...|..x
ff880010: 7c9e2378 7cbd2b78 7cdc3378 7cfb3b78    |.#x|.+x|.3x|.;x
ff880020: 3b000000 4811e0f5 48003719 480036a5    ;...H...H.7.H.6.
ff880030: 480036f9 48003731 48005c5d 7c7a1b78    H.6.H.71H.\]|z.x
ff880040: ffffffff ffffffff ffffffff ffffffff    ................
ff880050: ffffffff ffffffff ffffffff ffffffff    ................
ff880060: ffffffff ffffffff ffffffff ffffffff    ................
ff880070: ffffffff ffffffff ffffffff ffffffff    ................
=> md ff890000
ff890000: ff000000 60000000 60000000 7c7f1b78    ....`...`...|..x
ff890010: 7c9e2378 7cbd2b78 7cdc3378 7cfb3b78    |.#x|.+x|.3x|.;x
ff890020: 3b000000 4811e0f5 48003719 480036a5    ;...H...H.7.H.6.
ff890030: 480036f9 48003731 48005c5d 7c7a1b78    H.6.H.71H.\]|z.x
ff890040: ffffffff ffffffff ffffffff ffffffff    ................
ff890050: ffffffff ffffffff ffffffff ffffffff    ................
ff890060: ffffffff ffffffff ffffffff ffffffff    ................
ff890070: ffffffff ffffffff ffffffff ffffffff    ................
=> erase 1:8-9
Erase Flash Sectors 8-9 in Bank # 1
.... done
=> md ff880000 20
ff880000: ffffffff ffffffff ffffffff ffffffff    ................
ff880010: ffffffff ffffffff ffffffff ffffffff    ................
ff880020: ffffffff ffffffff ffffffff ffffffff    ................
ff880030: ffffffff ffffffff ffffffff ffffffff    ................
ff880040: ffffffff ffffffff ffffffff ffffffff    ................
ff880050: ffffffff ffffffff ffffffff ffffffff    ................
ff880060: ffffffff ffffffff ffffffff ffffffff    ................
ff880070: ffffffff ffffffff ffffffff ffffffff    ................
=> md ff890000
ff890000: ffffffff ffffffff ffffffff ffffffff    ................
ff890010: ffffffff ffffffff ffffffff ffffffff    ................
ff890020: ffffffff ffffffff ffffffff ffffffff    ................
ff890030: ffffffff ffffffff ffffffff ffffffff    ................
ff890040: ffffffff ffffffff ffffffff ffffffff    ................
ff890050: ffffffff ffffffff ffffffff ffffffff    ................
ff890060: ffffffff ffffffff ffffffff ffffffff    ................
ff890070: ffffffff ffffffff ffffffff ffffffff    ................
=>
------------------------------------------------------------------------------


The following sequence was performed to test the Flash programming commands:

------------------------------------------------------------------------------
=> erase ff880000 ff88ffff
Erase Flash from 0xff880000 to 0xff88ffff
.. done
Erased 1 sectors
=> cp 0 ff880000 10
Copy to Flash... done
=> md 0 20
00000000: ff000000 60000000 60000000 7c7f1b78    ....`...`...|..x
00000010: 7c9e2378 7cbd2b78 7cdc3378 7cfb3b78    |.#x|.+x|.3x|.;x
00000020: 3b000000 4811e0f5 48003719 480036a5    ;...H...H.7.H.6.
00000030: 480036f9 48003731 48005c5d 7c7a1b78    H.6.H.71H.\]|z.x
00000040: 3c83c000 2c040000 40823378 7c0000a6    <...,...@.3x|...
00000050: 60000030 7c1b03a6 3c00c000 600035ec    `..0|...<...`.5.
00000060: 7c1a03a6 4c000064 00000000 00000000    |...L..d........
00000070: 00000000 00000000 00000000 00000000    ................
=> md ff880000 20
ff880000: ff000000 60000000 60000000 7c7f1b78    ....`...`...|..x
ff880010: 7c9e2378 7cbd2b78 7cdc3378 7cfb3b78    |.#x|.+x|.3x|.;x
ff880020: 3b000000 4811e0f5 48003719 480036a5    ;...H...H.7.H.6.
ff880030: 480036f9 48003731 48005c5d 7c7a1b78    H.6.H.71H.\]|z.x
ff880040: ffffffff ffffffff ffffffff ffffffff    ................
ff880050: ffffffff ffffffff ffffffff ffffffff    ................
ff880060: ffffffff ffffffff ffffffff ffffffff    ................
ff880070: ffffffff ffffffff ffffffff ffffffff    ................
=>
------------------------------------------------------------------------------


The following sequence was performed to test storage of the environment
variables in Flash:

------------------------------------------------------------------------------
=> setenv foo bar
=> saveenv
Un-Protected 1 sectors
Erasing Flash...
.. done
Erased 1 sectors
Saving Environment to Flash...
Protected 1 sectors
=> reset
...
=> printenv
...
foo=bar
...
Environment size: 339/65532 bytes
=>
------------------------------------------------------------------------------


The following sequence was performed to test image download and run over
Ethernet interface (both interfaces were tested):

------------------------------------------------------------------------------
=> tftpboot 40000 hello_world.bin
ARP broadcast 1
TFTP from server 10.0.0.1; our IP address is 10.0.0.8
Filename 'hello_world.bin'.
Load address: 0x40000
Loading: #############
done
Bytes transferred = 65932 (1018c hex)
=> go 40004
## Starting application at 0x00040004 ...
Hello World
argc = 1
argv[0] = "40004"
argv[1] = "<NULL>"
Hit any key to exit ...

## Application terminated, rc = 0x0
=>
------------------------------------------------------------------------------


3. Known Problems

None for the moment.


----------------------------------------------------------------------------
U-Boot and Linux for Interphase 4539 T1/E1/J1 PMC Communications Controller
----------------------------------------------------------------------------

U-Boot:

	Configure and make U-Boot:

	$ cd <path>/u-boot
	$ make IPHASE4539_config
	$ make dep
	$ make
	$ cp -p u-boot.bin /tftpboot

	Load u-boot.bin into the Flash memory at 0xffb00000.


Linux:

	Configure and make Linux:

	$ cd <patch>/linux-2.4
	$ make IPHASE4539_config
	$ make oldconfig
	$ make dep
	$ make pImage
	$ cp -p arch/ppc/mbxboot/pImage /tftpboot

	Load pImage via tftp and boot it.


Flash organisation:

	The following preliminary layout of the Flash memory
	is defined:

	0xff800000 (   0    -   64 kB): Hardware Configuration Word.
	0xff810000 (  64 kB -  128 kB): U-Boot Environment.
	0xff820000 ( 128 kB -    3 MB): RAMdisk.
	0xffb00000 (   3 MB - 3328 kB): U-Boot.
	0xffb40000 (3328 KB -    4 MB): Linux Kernel.


For further information concerning U-Boot and Linux please consult
the "DENX U-Boot and Linux Guide".


(C) 2002 Wolfgang Grandegger, DENX Software Engineering, wg@denx.de
===================================================================