Compare commits
465 Commits
U-Boot-1_1
...
U-Boot-1_1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ba999c531e | ||
|
|
f836e41460 | ||
|
|
f641471498 | ||
|
|
6a0766ed22 | ||
|
|
43a2b0e76a | ||
|
|
73652699dd | ||
|
|
a0d3518460 | ||
|
|
fcfed4f2f2 | ||
|
|
3231ea64f4 | ||
|
|
82165a334b | ||
|
|
edf0b54338 | ||
|
|
4707fb50cc | ||
|
|
d7762337cb | ||
|
|
e0a46554c3 | ||
|
|
87621bc247 | ||
|
|
5c34eee94d | ||
|
|
ea237a4d25 | ||
|
|
c668670391 | ||
|
|
752d6837c3 | ||
|
|
2255b2d204 | ||
|
|
a3bb7bfc06 | ||
|
|
1a1b7374b8 | ||
|
|
d262a92f0f | ||
|
|
d82718fed0 | ||
|
|
1d92b2e550 | ||
|
|
2b208f5308 | ||
|
|
7ce343e499 | ||
|
|
511d0c72b8 | ||
|
|
8d4ac79436 | ||
|
|
9444b8818f | ||
|
|
eac5ba3e59 | ||
|
|
56fb6ba179 | ||
|
|
d373325efd | ||
|
|
7299712c86 | ||
|
|
ac611700e5 | ||
|
|
854bc8da75 | ||
|
|
aeec782b02 | ||
|
|
d214fbbd87 | ||
|
|
5d5269f87f | ||
|
|
a87d46f732 | ||
|
|
d12ae80889 | ||
|
|
a73c8dbb43 | ||
|
|
98e43917dc | ||
|
|
baf3124953 | ||
|
|
2d658967e1 | ||
|
|
efa20585b3 | ||
|
|
8cacfb85a8 | ||
|
|
5e09054af6 | ||
|
|
4f0645eb79 | ||
|
|
887e2ec9ec | ||
|
|
0dab03ba8f | ||
|
|
f60ba0d35e | ||
|
|
6741ae92f3 | ||
|
|
360b410367 | ||
|
|
fc43de0d4a | ||
|
|
f93286397e | ||
|
|
24d3d37546 | ||
|
|
6608043fd4 | ||
|
|
4c15ef55a2 | ||
|
|
bfdfd7c26c | ||
|
|
2c05165173 | ||
|
|
ec0f7277cb | ||
|
|
d7c2a02dea | ||
|
|
43835aac48 | ||
|
|
7d0432c9e4 | ||
|
|
e8143e72e1 | ||
|
|
0fd30252c8 | ||
|
|
2b75062a0f | ||
|
|
21a9cc028d | ||
|
|
2b393b0f0a | ||
|
|
f5577aae4a | ||
|
|
16850919ff | ||
|
|
3b0ff842bf | ||
|
|
113f64e09a | ||
|
|
15f29f06ed | ||
|
|
ed1cf8456f | ||
|
|
ddde6b7cf8 | ||
|
|
5196a7a03b | ||
|
|
6d3bc9b8cf | ||
|
|
c5185470fe | ||
|
|
4bfb632077 | ||
|
|
6fe16a8769 | ||
|
|
0a0f3a46fb | ||
|
|
6183bb9e5b | ||
|
|
463764c893 | ||
|
|
94568b600a | ||
|
|
2f6fa46d41 | ||
|
|
ddd5d9daf0 | ||
|
|
80f0c0f58f | ||
|
|
d689e3462c | ||
|
|
c72d9c5285 | ||
|
|
7213859d11 | ||
|
|
d8519dc718 | ||
|
|
015c200b1f | ||
|
|
36b904a7fd | ||
|
|
d10afb3916 | ||
|
|
692519b1ed | ||
|
|
a3d9181e00 | ||
|
|
6587f7e1e9 | ||
|
|
d8f961bbda | ||
|
|
4f92ed5fc0 | ||
|
|
9ede3cc511 | ||
|
|
e335496a32 | ||
|
|
e51aae3829 | ||
|
|
7455af41d1 | ||
|
|
a2c95a7224 | ||
|
|
fc6c4a67ae | ||
|
|
193dd95834 | ||
|
|
3ca9122fec | ||
|
|
4c4aca8166 | ||
|
|
4819fad905 | ||
|
|
fd27996dac | ||
|
|
135ae0062f | ||
|
|
048f6b436b | ||
|
|
fc1840e881 | ||
|
|
966083e95f | ||
|
|
144f7795ee | ||
|
|
b9365a26a1 | ||
|
|
87a5c73d66 | ||
|
|
029b6dc77c | ||
|
|
2c33a38bac | ||
|
|
aa0c71acad | ||
|
|
dd9f06f0d5 | ||
|
|
501090aaa6 | ||
|
|
32cb2c70c4 | ||
|
|
e644670b68 | ||
|
|
53dd6ce4f0 | ||
|
|
8623c11e08 | ||
|
|
0352f17687 | ||
|
|
311d802790 | ||
|
|
5078cce81c | ||
|
|
978b10964c | ||
|
|
45a212c4d7 | ||
|
|
bd3143f040 | ||
|
|
edd0b509ba | ||
|
|
c786f427f9 | ||
|
|
d053ce62cd | ||
|
|
8936601084 | ||
|
|
5a3dfef732 | ||
|
|
0de7fa5939 | ||
|
|
b87dfd2854 | ||
|
|
f3e06df7e8 | ||
|
|
ae1d7d4b2e | ||
|
|
dbba399be0 | ||
|
|
cf8f60f0ea | ||
|
|
d22d102808 | ||
|
|
f88a0ae6d7 | ||
|
|
090eb73510 | ||
|
|
d6cc73e4e7 | ||
|
|
b02d0177c1 | ||
|
|
87791f3bf2 | ||
|
|
985b950a9b | ||
|
|
9d40799551 | ||
|
|
a874c8c65f | ||
|
|
edd6cf20e1 | ||
|
|
caaeaf925f | ||
|
|
0095b787fe | ||
|
|
ce05de2950 | ||
|
|
d19206b9a5 | ||
|
|
fbb0b559ae | ||
|
|
fe84b48a94 | ||
|
|
3f7a63e6a3 | ||
|
|
3b5f61a025 | ||
|
|
bba6837732 | ||
|
|
971a5dd11a | ||
|
|
f6e5739a68 | ||
|
|
6c5879f380 | ||
|
|
bb105f24cc | ||
|
|
a63c31cff5 | ||
|
|
f73e73ba0e | ||
|
|
f5e0d03970 | ||
|
|
8d352247ec | ||
|
|
a650cfa286 | ||
|
|
0c32d96ddd | ||
|
|
c12cffc543 | ||
|
|
30a43cc2ae | ||
|
|
10af6d53bc | ||
|
|
14d9ab351c | ||
|
|
1ac7e17e86 | ||
|
|
bc8bb6d458 | ||
|
|
cebd1fcec0 | ||
|
|
cd65a3dc87 | ||
|
|
4bdb53cafb | ||
|
|
b9fff8ee83 | ||
|
|
3e9a299231 | ||
|
|
e00f41eb81 | ||
|
|
3332240318 | ||
|
|
9e18a4bc6c | ||
|
|
df02bd1b3f | ||
|
|
ed4633c93a | ||
|
|
b1d71358a9 | ||
|
|
4176c79964 | ||
|
|
9d4d3e3833 | ||
|
|
5d7022b041 | ||
|
|
9cc8337832 | ||
|
|
1f6ce8f5ba | ||
|
|
3d22d0b89b | ||
|
|
c2ced000f4 | ||
|
|
e461a24113 | ||
|
|
4526c87eec | ||
|
|
2fd9eb509d | ||
|
|
5abc2c5d4c | ||
|
|
e15cd6fdbe | ||
|
|
a4c8d1389f | ||
|
|
62b8f54877 | ||
|
|
392c252efd | ||
|
|
b9b2480f4f | ||
|
|
d945527305 | ||
|
|
ba94a1bba3 | ||
|
|
5770a1e488 | ||
|
|
b62fa913d4 | ||
|
|
27333f8c34 | ||
|
|
df3eece32d | ||
|
|
56ced709af | ||
|
|
6516525083 | ||
|
|
319b9a5467 | ||
|
|
8cba090c58 | ||
|
|
977b50f868 | ||
|
|
278bc4b37f | ||
|
|
f90a39213e | ||
|
|
512f8d5d78 | ||
|
|
d1dd22f92e | ||
|
|
77f633425b | ||
|
|
6080a0eb63 | ||
|
|
4af099bda9 | ||
|
|
1cfefe8cb6 | ||
|
|
67a9468522 | ||
|
|
78b123cd69 | ||
|
|
6f5155a95c | ||
|
|
b75ef85f42 | ||
|
|
b4853b779e | ||
|
|
0c056f0e27 | ||
|
|
483a0cf804 | ||
|
|
f149d8643e | ||
|
|
0cf7d8aa0b | ||
|
|
cb0fdf3cfa | ||
|
|
610cf3676e | ||
|
|
da4849fb30 | ||
|
|
983bebbea3 | ||
|
|
ac2e2b82bc | ||
|
|
5720df78ad | ||
|
|
8546e23902 | ||
|
|
3577d3a33b | ||
|
|
7a635e004e | ||
|
|
0e0ef590b2 | ||
|
|
d860c34ff0 | ||
|
|
7c93b2443c | ||
|
|
71ae411a63 | ||
|
|
76544f80e4 | ||
|
|
6ca24c64a5 | ||
|
|
8fe9bf61ef | ||
|
|
b86d7622b3 | ||
|
|
a83531bb62 | ||
|
|
7fd392c2d0 | ||
|
|
60e270a490 | ||
|
|
9acb626fc1 | ||
|
|
56a4a63c10 | ||
|
|
a367d42640 | ||
|
|
8419c01304 | ||
|
|
cf48eb9abd | ||
|
|
807522fc9a | ||
|
|
b81a4630a3 | ||
|
|
b28a31ca02 | ||
|
|
ad88297e2f | ||
|
|
bb74140def | ||
|
|
6db3970811 | ||
|
|
3a5e21881a | ||
|
|
5fbb2cd3b1 | ||
|
|
9bc97a3d91 | ||
|
|
71b405df4e | ||
|
|
197b049b8b | ||
|
|
2fc000d756 | ||
|
|
1707626650 | ||
|
|
db28ddb4da | ||
|
|
534ff676a9 | ||
|
|
2662b40cac | ||
|
|
d87080b721 | ||
|
|
3511853943 | ||
|
|
62534beb2f | ||
|
|
9e7b5ce61b | ||
|
|
f2841d3770 | ||
|
|
eeaab720f6 | ||
|
|
89f2dfa4c3 | ||
|
|
b66a938342 | ||
|
|
c855ef6768 | ||
|
|
f6dbbe9864 | ||
|
|
2770bcb21c | ||
|
|
0b953ffc65 | ||
|
|
40b0bafbb2 | ||
|
|
ba70d6a417 | ||
|
|
05d8dce9d0 | ||
|
|
5725f94aac | ||
|
|
552fc624f2 | ||
|
|
e443c944cf | ||
|
|
f8edca2e9a | ||
|
|
0b6ba547fa | ||
|
|
7b4fd36b03 | ||
|
|
0a112d8696 | ||
|
|
09e4b0c5d3 | ||
|
|
dc9e499c62 | ||
|
|
d326f4a242 | ||
|
|
97f98001a3 | ||
|
|
991425fe05 | ||
|
|
4c8d1ecce2 | ||
|
|
61f25155ac | ||
|
|
6d8ae5abb5 | ||
|
|
e24e0f0744 | ||
|
|
cd94ba397e | ||
|
|
a7c66ad2e5 | ||
|
|
6e53e27c50 | ||
|
|
ff7fefe679 | ||
|
|
86f5f0342d | ||
|
|
15940c9af3 | ||
|
|
f3fecfe6d7 | ||
|
|
9a7b408c11 | ||
|
|
9551530615 | ||
|
|
c15f80eaef | ||
|
|
b38dbd4622 | ||
|
|
f07217c9e2 | ||
|
|
84c960ce6d | ||
|
|
763b5f34c3 | ||
|
|
be5048f166 | ||
|
|
ca27381df1 | ||
|
|
8123eee875 | ||
|
|
7c60908ffb | ||
|
|
47705af5da | ||
|
|
795bee8496 | ||
|
|
7b230f61db | ||
|
|
a3f0169880 | ||
|
|
3b2e4fd9b0 | ||
|
|
0346983290 | ||
|
|
d8169c9f3b | ||
|
|
0a3471fc78 | ||
|
|
993a22756e | ||
|
|
953c5b6f8b | ||
|
|
23466d6a33 | ||
|
|
74f92e6a3f | ||
|
|
8e7b703a62 | ||
|
|
1264b4050c | ||
|
|
6cb142fa3b | ||
|
|
0afe519a43 | ||
|
|
dc013d4640 | ||
|
|
8ff0208d31 | ||
|
|
f47b661141 | ||
|
|
aba9f1af60 | ||
|
|
5797b821dc | ||
|
|
7c54c7018e | ||
|
|
92b197f0da | ||
|
|
82d716fd0d | ||
|
|
611125a292 | ||
|
|
2281490485 | ||
|
|
d509b81210 | ||
|
|
84ef51a632 | ||
|
|
d2ed2f661b | ||
|
|
8de7ed3abe | ||
|
|
d52fb7e3d1 | ||
|
|
4367a01036 | ||
|
|
5536b2b5a9 | ||
|
|
83784bf63f | ||
|
|
e4558768ae | ||
|
|
3d65390e21 | ||
|
|
8371a2c0d4 | ||
|
|
3c4eb0880b | ||
|
|
9c575e51de | ||
|
|
1f62bc2d08 | ||
|
|
0be248fa9a | ||
|
|
951a954b77 | ||
|
|
ac7d97dcbb | ||
|
|
43638c674a | ||
|
|
f9e029184b | ||
|
|
bfc81252c0 | ||
|
|
4e3ccd2692 | ||
|
|
addb2e1650 | ||
|
|
bf7cac033b | ||
|
|
f1ee982506 | ||
|
|
f8785e96c9 | ||
|
|
24e1217be3 | ||
|
|
9187a35b6c | ||
|
|
19fdeff433 | ||
|
|
e2053f9c7a | ||
|
|
aed9e2269c | ||
|
|
bb1ff049fb | ||
|
|
4f71866470 | ||
|
|
481911c78c | ||
|
|
f18e874ad5 | ||
|
|
e8cd00835e | ||
|
|
00c35bd214 | ||
|
|
82f2e33a8d | ||
|
|
6949328d7d | ||
|
|
f6c0068fc1 | ||
|
|
36d2c5387d | ||
|
|
58ad497833 | ||
|
|
79b4cda076 | ||
|
|
0377dca227 | ||
|
|
7d4d1ce48c | ||
|
|
038ccac511 | ||
|
|
c81eb1f5f5 | ||
|
|
7958202031 | ||
|
|
599f52253a | ||
|
|
ff3c2a9478 | ||
|
|
6624b687bc | ||
|
|
5f0be01356 | ||
|
|
9cdc838613 | ||
|
|
86ea5f93d7 | ||
|
|
48b6242aa1 | ||
|
|
881a87ecba | ||
|
|
654c2d2836 | ||
|
|
075866d840 | ||
|
|
4f7a0e3671 | ||
|
|
8fb1857b40 | ||
|
|
57dc57f14d | ||
|
|
230b31febf | ||
|
|
2688e2f972 | ||
|
|
bf5988e533 | ||
|
|
6ece03f267 | ||
|
|
b2b43463af | ||
|
|
b3c36e6b94 | ||
|
|
9d803d8c0b | ||
|
|
79830d591a | ||
|
|
af646e865f | ||
|
|
e0269579a5 | ||
|
|
48a05a5188 | ||
|
|
84e106c09d | ||
|
|
57cac1fa54 | ||
|
|
f8c3b4f310 | ||
|
|
3a108ed868 | ||
|
|
eacbd31775 | ||
|
|
b636d32261 | ||
|
|
c99f384dce | ||
|
|
27afa7d966 | ||
|
|
b970480948 | ||
|
|
18c5e64c5b | ||
|
|
a7b9fb9110 | ||
|
|
2076d0a15f | ||
|
|
c4b465f63e | ||
|
|
b443f7b628 | ||
|
|
86902b8e36 | ||
|
|
06508f1c9b | ||
|
|
d5e78b7bf4 | ||
|
|
bc680b12d0 | ||
|
|
dffb70f330 | ||
|
|
1e8f1da65b | ||
|
|
19ab485189 | ||
|
|
21a3cbd0d8 | ||
|
|
304ad60f7d | ||
|
|
62ec6418d4 | ||
|
|
e559a6901a | ||
|
|
c2871f0380 | ||
|
|
4e2531378f | ||
|
|
e4f880eddd | ||
|
|
3411d11761 | ||
|
|
a179012e37 | ||
|
|
ec00c33578 | ||
|
|
a15b44dbfa | ||
|
|
ce574ff506 | ||
|
|
9260a56151 | ||
|
|
756ceb8935 | ||
|
|
3bb6680655 | ||
|
|
c7428d49ac | ||
|
|
97c8d0bbbd | ||
|
|
27e166b875 | ||
|
|
8e9655f863 | ||
|
|
ac7eb8a315 | ||
|
|
05b47540aa | ||
|
|
932394ac43 |
11
CREDITS
11
CREDITS
@@ -105,6 +105,10 @@ N: Magnus Damm
|
||||
E: damm@opensource.se
|
||||
D: 8xxrom
|
||||
|
||||
N: Richard Danter
|
||||
E: richard.danter@windriver.com
|
||||
D: Support for Wind River PPMC 7xx/74xx boards
|
||||
|
||||
N: George G. Davis
|
||||
E: gdavis@mvista.com
|
||||
D: Board ports for ADS GraphicsClient+ and Intel Assabet
|
||||
@@ -229,6 +233,7 @@ D: Port to Windriver ppmc8260 board
|
||||
N: Sangmoon Kim
|
||||
E: dogoil@etinsys.com
|
||||
D: Support for debris board
|
||||
D: Support for KVME080 board
|
||||
|
||||
N: Frederick W. Klatt
|
||||
E: fred.klatt@windriver.com
|
||||
@@ -253,7 +258,7 @@ D Support for Intrinsyc CERF PXA250 board.
|
||||
|
||||
N: Thomas Lange
|
||||
E: thomas@corelatus.se
|
||||
D: Support for GTH and dbau1x00 boards; lots of PCMCIA fixes
|
||||
D: Support for GTH, GTH2 and dbau1x00 boards; lots of PCMCIA fixes
|
||||
|
||||
N: Marc Leeman
|
||||
E: marc.leeman@barco.com
|
||||
@@ -381,6 +386,10 @@ N: Robert Schwebel
|
||||
E: r.schwebel@pengutronix.de
|
||||
D: Support for csb226, logodl and innokom boards (PXA2xx)
|
||||
|
||||
N: Aaron Sells
|
||||
E: sellsa@embeddedplanet.com
|
||||
D: Support for EP82xxM
|
||||
|
||||
N: Art Shipkowski
|
||||
E: art@videon-central.com
|
||||
D: Support for NetSilicon NS7520
|
||||
|
||||
22
MAINTAINERS
22
MAINTAINERS
@@ -197,6 +197,7 @@ Brad Kemp <Brad.Kemp@seranoa.com>
|
||||
Sangmoon Kim <dogoil@etinsys.com>
|
||||
|
||||
debris MPC8245
|
||||
KVME080 MPC8245
|
||||
|
||||
Thomas Lange <thomas@corelatus.se>
|
||||
|
||||
@@ -283,6 +284,8 @@ Stefan Roese <sr@denx.de>
|
||||
ebony PPC440GP
|
||||
ocotea PPC440GX
|
||||
p3p440 PPC440GP
|
||||
pcs440ep PPC440EP
|
||||
sequoia PPC440EPx
|
||||
sycamore PPC405GPr
|
||||
walnut PPC405GP
|
||||
yellowstone PPC440GR
|
||||
@@ -316,6 +319,11 @@ Rune Torgersen <runet@innovsys.com>
|
||||
|
||||
MPC8266ADS MPC8266
|
||||
|
||||
|
||||
David Updegraff <dave@cray.com>
|
||||
|
||||
CRAYL1 PPC4xx
|
||||
|
||||
Josef Wagner <Wagner@Microsys.de>
|
||||
|
||||
CPC45 MPC8245
|
||||
@@ -345,7 +353,6 @@ Unknown / orphaned boards:
|
||||
RPXClassic MPC8xx
|
||||
RPXlite MPC8xx
|
||||
|
||||
CRAYL1 PPC4xx
|
||||
ERIC PPC4xx
|
||||
|
||||
MOUSSE MPC824x
|
||||
@@ -434,6 +441,11 @@ Dave Peverley <dpeverley@mpc-data.co.uk>
|
||||
|
||||
omap730p2 ARM926EJS
|
||||
|
||||
Stefan Roese <sr@denx.de>
|
||||
|
||||
ixdpg425 xscale
|
||||
pdnb3 xscale
|
||||
|
||||
Robert Schwebel <r.schwebel@pengutronix.de>
|
||||
|
||||
csb226 xscale
|
||||
@@ -483,6 +495,7 @@ Wolfgang Denk <wd@denx.de>
|
||||
|
||||
Thomas Lange <thomas@corelatus.se>
|
||||
dbau1x00 MIPS32 Au1000
|
||||
gth2 MIPS32 Au1000
|
||||
|
||||
#########################################################################
|
||||
# Nios-32 Systems: #
|
||||
@@ -511,6 +524,9 @@ Scott McNutt <smcnutt@psyent.com>
|
||||
|
||||
PCI5441 Nios-II
|
||||
PK1C20 Nios-II
|
||||
EP1C20 Nios-II
|
||||
EP1S10 Nios-II
|
||||
EP1S40 Nios-II
|
||||
|
||||
#########################################################################
|
||||
# MicroBlaze Systems: #
|
||||
@@ -534,6 +550,10 @@ Matthias Fuchs <matthias.fuchs@esd-electronics.com>
|
||||
|
||||
TASREG MCF5249
|
||||
|
||||
Zachary P. Landau <zachary.landau@labxtechnologies.com>
|
||||
|
||||
r5200 mcf52x2
|
||||
|
||||
#########################################################################
|
||||
# End of MAINTAINERS list #
|
||||
#########################################################################
|
||||
|
||||
142
MAKEALL
142
MAKEALL
@@ -8,7 +8,17 @@ else
|
||||
MAKE=make
|
||||
fi
|
||||
|
||||
[ -d LOG ] || mkdir LOG || exit 1
|
||||
if [ "${MAKEALL_LOGDIR}" ] ; then
|
||||
LOG_DIR=${MAKEALL_LOGDIR}
|
||||
else
|
||||
LOG_DIR="LOG"
|
||||
fi
|
||||
|
||||
if [ ! "${BUILD_DIR}" ] ; then
|
||||
BUILD_DIR="."
|
||||
fi
|
||||
|
||||
[ -d ${LOG_DIR} ] || mkdir ${LOG_DIR} || exit 1
|
||||
|
||||
LIST=""
|
||||
|
||||
@@ -25,15 +35,16 @@ LIST_5xx=" \
|
||||
#########################################################################
|
||||
|
||||
LIST_5xxx=" \
|
||||
cpci5200 icecube_5100 icecube_5200 EVAL5200 \
|
||||
pf5200 PM520 Total5100 Total5200 \
|
||||
Total5200_Rev2 TQM5200_auto o2dnt \
|
||||
BC3450 cpci5200 EVAL5200 fo300 \
|
||||
icecube_5100 icecube_5200 lite5200b mcc200 \
|
||||
o2dnt pf5200 PM520 TB5200 \
|
||||
Total5100 Total5200 Total5200_Rev2 TQM5200 \
|
||||
TQM5200_B TQM5200S v38b \
|
||||
"
|
||||
|
||||
#########################################################################
|
||||
## MPC8xx Systems
|
||||
#########################################################################
|
||||
|
||||
LIST_8xx=" \
|
||||
Adder87x GENIETV MBX860T R360MPI \
|
||||
AdderII GTH MHPC RBC823 \
|
||||
@@ -43,15 +54,17 @@ LIST_8xx=" \
|
||||
CCM IP860 NETPHONE RPXlite_DW \
|
||||
cogent_mpc8xx IVML24 NETTA RRvision \
|
||||
ELPT860 IVML24_128 NETTA2 SM850 \
|
||||
ESTEEM192E IVML24_256 NETTA_ISDN SPD823TS \
|
||||
ETX094 IVMS8 NETVIA svm_sc8xx \
|
||||
FADS823 IVMS8_128 NETVIA_V2 SXNI855T \
|
||||
FADS850SAR IVMS8_256 NX823 TOP860 \
|
||||
FADS860T KUP4K pcu_e TQM823L \
|
||||
FLAGADM KUP4X QS823 TQM823L_LCD \
|
||||
FPS850L LANTEC QS850 TQM850L \
|
||||
GEN860T lwmon QS860T TQM855L \
|
||||
GEN860T_SC MBX quantum TQM860L \
|
||||
EP88x IVML24_256 NETTA_ISDN spc1920 \
|
||||
ESTEEM192E IVMS8 NETVIA SPD823TS \
|
||||
ETX094 IVMS8_128 NETVIA_V2 svm_sc8xx \
|
||||
FADS823 IVMS8_256 NX823 SXNI855T \
|
||||
FADS850SAR KUP4K pcu_e TOP860 \
|
||||
FADS860T KUP4X QS823 TQM823L \
|
||||
FLAGADM LANTEC QS850 TQM823L_LCD \
|
||||
FPS850L lwmon QS860T TQM850L \
|
||||
GEN860T MBX quantum TQM855L \
|
||||
GEN860T_SC TQM860L \
|
||||
TQM885D \
|
||||
uc100 \
|
||||
v37 \
|
||||
"
|
||||
@@ -62,19 +75,20 @@ LIST_8xx=" \
|
||||
|
||||
LIST_4xx=" \
|
||||
ADCIOP AP1000 AR405 ASH405 \
|
||||
bubinga CANBT CMS700 CPCI2DP \
|
||||
CPCI405 CPCI4052 CPCI405AB CPCI405DT \
|
||||
CPCI440 CPCIISER4 CRAYL1 csb272 \
|
||||
csb472 DASA_SIM DP405 DU405 \
|
||||
ebony ERIC EXBITGEN G2000 \
|
||||
HH405 HUB405 JSE KAREF \
|
||||
luan METROBOX MIP405 MIP405T \
|
||||
ML2 ml300 ocotea OCRTC \
|
||||
ORSG p3p440 PCI405 PIP405 \
|
||||
PLU405 PMC405 PPChameleonEVB sbc405 \
|
||||
VOH405 VOM405 W7OLMC W7OLMG \
|
||||
bamboo bubinga CANBT CMS700 \
|
||||
CPCI2DP CPCI405 CPCI4052 CPCI405AB \
|
||||
CPCI405DT CPCI440 CPCIISER4 CRAYL1 \
|
||||
csb272 csb472 DASA_SIM DP405 \
|
||||
DU405 ebony ERIC EXBITGEN \
|
||||
G2000 HH405 HUB405 JSE \
|
||||
KAREF luan METROBOX MIP405 \
|
||||
MIP405T ML2 ml300 ocotea \
|
||||
OCRTC ORSG p3p440 PCI405 \
|
||||
pcs440ep PIP405 PLU405 PMC405 \
|
||||
PPChameleonEVB sbc405 sequoia sequoia_nand \
|
||||
VOH405 VOM405 W7OLMC W7OLMG \
|
||||
walnut WUH405 XPEDITE1K yellowstone \
|
||||
yosemite \
|
||||
yosemite yucca bamboo \
|
||||
"
|
||||
|
||||
#########################################################################
|
||||
@@ -92,9 +106,9 @@ LIST_8220=" \
|
||||
LIST_824x=" \
|
||||
A3000 barco BMW CPC45 \
|
||||
CU824 debris eXalion HIDDEN_DRAGON \
|
||||
MOUSSE MUSENKI MVBLUE OXC \
|
||||
PN62 Sandpoint8240 Sandpoint8245 sbc8240 \
|
||||
SL8245 utx8245 \
|
||||
MOUSSE MUSENKI MVBLUE \
|
||||
OXC PN62 Sandpoint8240 Sandpoint8245 \
|
||||
sbc8240 SL8245 utx8245 \
|
||||
"
|
||||
|
||||
#########################################################################
|
||||
@@ -103,12 +117,12 @@ LIST_824x=" \
|
||||
|
||||
LIST_8260=" \
|
||||
atc cogent_mpc8260 CPU86 CPU87 \
|
||||
ep8248 ep8260 gw8260 hymod \
|
||||
IPHASE4539 ISPAN MPC8260ADS MPC8266ADS \
|
||||
MPC8272ADS PM826 PM828 ppmc8260 \
|
||||
Rattler8248 RPXsuper rsdproto sacsng \
|
||||
sbc8260 SCM TQM8260_AC TQM8260_AD \
|
||||
TQM8260_AE ZPC1900 \
|
||||
ep8248 ep8260 ep82xxm gw8260 \
|
||||
hymod IPHASE4539 ISPAN MPC8260ADS \
|
||||
MPC8266ADS MPC8272ADS PM826 PM828 \
|
||||
ppmc8260 Rattler8248 RPXsuper rsdproto \
|
||||
sacsng sbc8260 SCM TQM8260_AC \
|
||||
TQM8260_AD TQM8260_AE ZPC1900 \
|
||||
"
|
||||
|
||||
#########################################################################
|
||||
@@ -116,7 +130,7 @@ LIST_8260=" \
|
||||
#########################################################################
|
||||
|
||||
LIST_83xx=" \
|
||||
MPC8349ADS TQM834x\
|
||||
TQM834x MPC8349EMDS \
|
||||
"
|
||||
|
||||
|
||||
@@ -141,7 +155,7 @@ LIST_74xx=" \
|
||||
"
|
||||
|
||||
LIST_7xx=" \
|
||||
BAB7xx CPCI750 ELPPC \
|
||||
BAB7xx CPCI750 ELPPC ppmc7xx \
|
||||
"
|
||||
|
||||
LIST_ppc="${LIST_5xx} ${LIST_5xxx} \
|
||||
@@ -177,10 +191,11 @@ LIST_ARM9=" \
|
||||
ap920t ap922_XA10 ap926ejs ap946es \
|
||||
ap966 cp920t cp922_XA10 cp926ejs \
|
||||
cp946es cp966 lpd7a400 mp2usb \
|
||||
mx1ads mx1fs2 omap1510inn omap1610h2 \
|
||||
omap1610inn omap730p2 scb9328 smdk2400 \
|
||||
smdk2410 trab VCMA9 versatile \
|
||||
versatileab versatilepb voiceblue
|
||||
mx1ads mx1fs2 netstar omap1510inn \
|
||||
omap1610h2 omap1610inn omap730p2 sbc2410x \
|
||||
scb9328 smdk2400 smdk2410 trab \
|
||||
VCMA9 versatile versatileab versatilepb \
|
||||
voiceblue \
|
||||
"
|
||||
|
||||
#########################################################################
|
||||
@@ -203,11 +218,12 @@ LIST_ARM11=" \
|
||||
|
||||
LIST_pxa=" \
|
||||
adsvix cerf250 cradle csb226 \
|
||||
innokom lubbock pxa255_idp wepep250 \
|
||||
xaeniax xm250 xsengine \
|
||||
delta innokom lubbock pleb2 \
|
||||
pxa255_idp wepep250 xaeniax xm250 \
|
||||
xsengine zylonite \
|
||||
"
|
||||
|
||||
LIST_ixp="ixdp425"
|
||||
LIST_ixp="ixdp425 ixdpg425 pdnb3"
|
||||
|
||||
|
||||
LIST_arm=" \
|
||||
@@ -224,7 +240,7 @@ LIST_mips4kc="incaip"
|
||||
|
||||
LIST_mips5kc="purple"
|
||||
|
||||
LIST_au1xx0="dbau1000 dbau1100 dbau1500 dbau1550 dbau1550_el"
|
||||
LIST_au1xx0="dbau1000 dbau1100 dbau1500 dbau1550 dbau1550_el gth2"
|
||||
|
||||
LIST_mips="${LIST_mips4kc} ${LIST_mips5kc} ${LIST_au1xx0}"
|
||||
|
||||
@@ -253,23 +269,38 @@ LIST_x86="${LIST_I486}"
|
||||
#########################################################################
|
||||
|
||||
LIST_nios=" \
|
||||
ADNPESC1 ADNPESC1_base_32 \
|
||||
ADNPESC1 ADNPESC1_base_32 \
|
||||
ADNPESC1_DNPEVA2_base_32 \
|
||||
DK1C20 DK1C20_standard_32 \
|
||||
DK1S10 DK1S10_standard_32 DK1S10_mtx_ldk_20 \
|
||||
DK1C20 DK1C20_standard_32 \
|
||||
DK1S10 DK1S10_standard_32 DK1S10_mtx_ldk_20 \
|
||||
"
|
||||
|
||||
#########################################################################
|
||||
## Nios-II Systems
|
||||
#########################################################################
|
||||
|
||||
LIST_nios2="PCI5441 PK1C20"
|
||||
LIST_nios2=" \
|
||||
EP1C20 EP1S10 EP1S40 \
|
||||
PCI5441 PK1C20 \
|
||||
"
|
||||
|
||||
#########################################################################
|
||||
## MicroBlaze Systems
|
||||
#########################################################################
|
||||
|
||||
LIST_microblaze="suzaku"
|
||||
LIST_microblaze=" \
|
||||
suzaku
|
||||
"
|
||||
|
||||
#########################################################################
|
||||
## ColdFire Systems
|
||||
#########################################################################
|
||||
|
||||
LIST_coldfire=" \
|
||||
cobra5272 EB+MCF-EV123 EB+MCF-EV123_internal \
|
||||
M5271EVB M5272C3 M5282EVB TASREG \
|
||||
r5200 M5271EVB \
|
||||
"
|
||||
|
||||
#-----------------------------------------------------------------------
|
||||
|
||||
@@ -283,8 +314,12 @@ build_target() {
|
||||
|
||||
${MAKE} distclean >/dev/null
|
||||
${MAKE} ${target}_config
|
||||
${MAKE} ${JOBS} all 2>&1 >LOG/$target.MAKELOG | tee LOG/$target.ERR
|
||||
${CROSS_COMPILE:-ppc_8xx-}size u-boot | tee -a LOG/$target.MAKELOG
|
||||
|
||||
${MAKE} ${JOBS} all 2>&1 >${LOG_DIR}/$target.MAKELOG \
|
||||
| tee ${LOG_DIR}/$target.ERR
|
||||
|
||||
${CROSS_COMPILE:-ppc_8xx-}size ${BUILD_DIR}/u-boot \
|
||||
| tee -a ${LOG_DIR}/$target.MAKELOG
|
||||
}
|
||||
|
||||
#-----------------------------------------------------------------------
|
||||
@@ -298,7 +333,8 @@ do
|
||||
microblaze| \
|
||||
mips|mips_el| \
|
||||
nios|nios2| \
|
||||
x86|I486)
|
||||
x86|I486| \
|
||||
coldfire)
|
||||
for target in `eval echo '$LIST_'${arg}`
|
||||
do
|
||||
build_target ${target}
|
||||
|
||||
204
README
204
README
@@ -246,6 +246,7 @@ The following options need to be configured:
|
||||
CONFIG_SA1110
|
||||
CONFIG_ARM7
|
||||
CONFIG_PXA250
|
||||
CONFIG_CPU_MONAHANS
|
||||
|
||||
MicroBlaze based CPUs:
|
||||
----------------------
|
||||
@@ -261,56 +262,57 @@ The following options need to be configured:
|
||||
PowerPC based boards:
|
||||
---------------------
|
||||
|
||||
CONFIG_ADCIOP CONFIG_GEN860T CONFIG_PCIPPC2
|
||||
CONFIG_ADS860 CONFIG_GENIETV CONFIG_PCIPPC6
|
||||
CONFIG_AMX860 CONFIG_GTH CONFIG_pcu_e
|
||||
CONFIG_AP1000 CONFIG_gw8260 CONFIG_PIP405
|
||||
CONFIG_AR405 CONFIG_hermes CONFIG_PM826
|
||||
CONFIG_BAB7xx CONFIG_hymod CONFIG_ppmc8260
|
||||
CONFIG_c2mon CONFIG_IAD210 CONFIG_QS823
|
||||
CONFIG_CANBT CONFIG_ICU862 CONFIG_QS850
|
||||
CONFIG_CCM CONFIG_IP860 CONFIG_QS860T
|
||||
CONFIG_CMI CONFIG_IPHASE4539 CONFIG_RBC823
|
||||
CONFIG_cogent_mpc8260 CONFIG_IVML24 CONFIG_RPXClassic
|
||||
CONFIG_cogent_mpc8xx CONFIG_IVML24_128 CONFIG_RPXlite
|
||||
CONFIG_CPCI405 CONFIG_IVML24_256 CONFIG_RPXsuper
|
||||
CONFIG_CPCI4052 CONFIG_IVMS8 CONFIG_rsdproto
|
||||
CONFIG_CPCIISER4 CONFIG_IVMS8_128 CONFIG_sacsng
|
||||
CONFIG_CPU86 CONFIG_IVMS8_256 CONFIG_Sandpoint8240
|
||||
CONFIG_CRAYL1 CONFIG_JSE CONFIG_Sandpoint8245
|
||||
CONFIG_CSB272 CONFIG_LANTEC CONFIG_sbc8260
|
||||
CONFIG_CU824 CONFIG_lwmon CONFIG_sbc8560
|
||||
CONFIG_DASA_SIM CONFIG_MBX CONFIG_SM850
|
||||
CONFIG_DB64360 CONFIG_MBX860T CONFIG_SPD823TS
|
||||
CONFIG_DB64460 CONFIG_MHPC CONFIG_STXGP3
|
||||
CONFIG_DU405 CONFIG_MIP405 CONFIG_SXNI855T
|
||||
CONFIG_DUET_ADS CONFIG_MOUSSE CONFIG_TQM823L
|
||||
CONFIG_EBONY CONFIG_MPC8260ADS CONFIG_TQM8260
|
||||
CONFIG_ELPPC CONFIG_MPC8540ADS CONFIG_TQM850L
|
||||
CONFIG_ELPT860 CONFIG_MPC8540EVAL CONFIG_TQM855L
|
||||
CONFIG_ep8260 CONFIG_MPC8560ADS CONFIG_TQM860L
|
||||
CONFIG_ERIC CONFIG_MUSENKI CONFIG_TTTech
|
||||
CONFIG_ESTEEM192E CONFIG_MVS1 CONFIG_UTX8245
|
||||
CONFIG_ETX094 CONFIG_NETPHONE CONFIG_V37
|
||||
CONFIG_EVB64260 CONFIG_NETTA CONFIG_W7OLMC
|
||||
CONFIG_FADS823 CONFIG_NETVIA CONFIG_W7OLMG
|
||||
CONFIG_FADS850SAR CONFIG_NX823 CONFIG_WALNUT
|
||||
CONFIG_FADS860T CONFIG_OCRTC CONFIG_ZPC1900
|
||||
CONFIG_FLAGADM CONFIG_ORSG CONFIG_ZUMA
|
||||
CONFIG_FPS850L CONFIG_OXC
|
||||
CONFIG_FPS860L CONFIG_PCI405
|
||||
CONFIG_ADCIOP CONFIG_FPS860L CONFIG_OXC
|
||||
CONFIG_ADS860 CONFIG_GEN860T CONFIG_PCI405
|
||||
CONFIG_AMX860 CONFIG_GENIETV CONFIG_PCIPPC2
|
||||
CONFIG_AP1000 CONFIG_GTH CONFIG_PCIPPC6
|
||||
CONFIG_AR405 CONFIG_gw8260 CONFIG_pcu_e
|
||||
CONFIG_BAB7xx CONFIG_hermes CONFIG_PIP405
|
||||
CONFIG_BC3450 CONFIG_hymod CONFIG_PM826
|
||||
CONFIG_c2mon CONFIG_IAD210 CONFIG_ppmc8260
|
||||
CONFIG_CANBT CONFIG_ICU862 CONFIG_QS823
|
||||
CONFIG_CCM CONFIG_IP860 CONFIG_QS850
|
||||
CONFIG_CMI CONFIG_IPHASE4539 CONFIG_QS860T
|
||||
CONFIG_cogent_mpc8260 CONFIG_IVML24 CONFIG_RBC823
|
||||
CONFIG_cogent_mpc8xx CONFIG_IVML24_128 CONFIG_RPXClassic
|
||||
CONFIG_CPCI405 CONFIG_IVML24_256 CONFIG_RPXlite
|
||||
CONFIG_CPCI4052 CONFIG_IVMS8 CONFIG_RPXsuper
|
||||
CONFIG_CPCIISER4 CONFIG_IVMS8_128 CONFIG_rsdproto
|
||||
CONFIG_CPU86 CONFIG_IVMS8_256 CONFIG_sacsng
|
||||
CONFIG_CRAYL1 CONFIG_JSE CONFIG_Sandpoint8240
|
||||
CONFIG_CSB272 CONFIG_LANTEC CONFIG_Sandpoint8245
|
||||
CONFIG_CU824 CONFIG_LITE5200B CONFIG_sbc8260
|
||||
CONFIG_DASA_SIM CONFIG_lwmon CONFIG_sbc8560
|
||||
CONFIG_DB64360 CONFIG_MBX CONFIG_SM850
|
||||
CONFIG_DB64460 CONFIG_MBX860T CONFIG_SPD823TS
|
||||
CONFIG_DU405 CONFIG_MHPC CONFIG_STXGP3
|
||||
CONFIG_DUET_ADS CONFIG_MIP405 CONFIG_SXNI855T
|
||||
CONFIG_EBONY CONFIG_MOUSSE CONFIG_TQM823L
|
||||
CONFIG_ELPPC CONFIG_MPC8260ADS CONFIG_TQM8260
|
||||
CONFIG_ELPT860 CONFIG_MPC8540ADS CONFIG_TQM850L
|
||||
CONFIG_ep8260 CONFIG_MPC8540EVAL CONFIG_TQM855L
|
||||
CONFIG_ERIC CONFIG_MPC8560ADS CONFIG_TQM860L
|
||||
CONFIG_ESTEEM192E CONFIG_MUSENKI CONFIG_TTTech
|
||||
CONFIG_ETX094 CONFIG_MVS1 CONFIG_UTX8245
|
||||
CONFIG_EVB64260 CONFIG_NETPHONE CONFIG_V37
|
||||
CONFIG_FADS823 CONFIG_NETTA CONFIG_W7OLMC
|
||||
CONFIG_FADS850SAR CONFIG_NETVIA CONFIG_W7OLMG
|
||||
CONFIG_FADS860T CONFIG_NX823 CONFIG_WALNUT
|
||||
CONFIG_FLAGADM CONFIG_OCRTC CONFIG_ZPC1900
|
||||
CONFIG_FPS850L CONFIG_ORSG CONFIG_ZUMA
|
||||
|
||||
ARM based boards:
|
||||
-----------------
|
||||
|
||||
CONFIG_ARMADILLO, CONFIG_AT91RM9200DK, CONFIG_CERF250,
|
||||
CONFIG_CSB637, CONFIG_DNP1110, CONFIG_EP7312,
|
||||
CONFIG_H2_OMAP1610, CONFIG_HHP_CRADLE, CONFIG_IMPA7,
|
||||
CONFIG_INNOVATOROMAP1510, CONFIG_INNOVATOROMAP1610, CONFIG_KB9202,
|
||||
CONFIG_LART, CONFIG_LPD7A400, CONFIG_LUBBOCK,
|
||||
CONFIG_OSK_OMAP5912, CONFIG_OMAP2420H4, CONFIG_SHANNON,
|
||||
CONFIG_P2_OMAP730, CONFIG_SMDK2400, CONFIG_SMDK2410,
|
||||
CONFIG_TRAB, CONFIG_VCMA9
|
||||
CONFIG_CSB637, CONFIG_DELTA, CONFIG_DNP1110,
|
||||
CONFIG_EP7312, CONFIG_H2_OMAP1610, CONFIG_HHP_CRADLE,
|
||||
CONFIG_IMPA7, CONFIG_INNOVATOROMAP1510, CONFIG_INNOVATOROMAP1610,
|
||||
CONFIG_KB9202, CONFIG_LART, CONFIG_LPD7A400,
|
||||
CONFIG_LUBBOCK, CONFIG_OSK_OMAP5912, CONFIG_OMAP2420H4,
|
||||
CONFIG_PLEB2, CONFIG_SHANNON, CONFIG_P2_OMAP730,
|
||||
CONFIG_SMDK2400, CONFIG_SMDK2410, CONFIG_TRAB,
|
||||
CONFIG_VCMA9
|
||||
|
||||
MicroBlaze based boards:
|
||||
------------------------
|
||||
@@ -321,6 +323,7 @@ The following options need to be configured:
|
||||
------------------------
|
||||
|
||||
CONFIG_PCI5441 CONFIG_PK1C20
|
||||
CONFIG_EP1C20 CONFIG_EP1S10 CONFIG_EP1S40
|
||||
|
||||
|
||||
- CPU Module Type: (if CONFIG_COGENT is defined)
|
||||
@@ -379,6 +382,20 @@ The following options need to be configured:
|
||||
that this requires a (stable) reference clock (32 kHz
|
||||
RTC clock or CFG_8XX_XIN)
|
||||
|
||||
- Intel Monahans options:
|
||||
CFG_MONAHANS_RUN_MODE_OSC_RATIO
|
||||
|
||||
Defines the Monahans run mode to oscillator
|
||||
ratio. Valid values are 8, 16, 24, 31. The core
|
||||
frequency is this value multiplied by 13 MHz.
|
||||
|
||||
CFG_MONAHANS_TURBO_RUN_MODE_RATIO
|
||||
|
||||
Defines the Monahans turbo mode to oscillator
|
||||
ratio. Valid values are 1 (default if undefined) and
|
||||
2. The core frequency as calculated above is multiplied
|
||||
by this value.
|
||||
|
||||
- Linux Kernel Interface:
|
||||
CONFIG_CLOCKS_IN_MHZ
|
||||
|
||||
@@ -411,7 +428,24 @@ The following options need to be configured:
|
||||
The maximum size of the constructed OF tree.
|
||||
|
||||
OF_CPU - The proper name of the cpus node.
|
||||
OF_SOC - The proper name of the soc node.
|
||||
OF_TBCLK - The timebase frequency.
|
||||
OF_STDOUT_PATH - The path to the console device
|
||||
|
||||
CONFIG_OF_HAS_BD_T
|
||||
|
||||
The resulting flat device tree will have a copy of the bd_t.
|
||||
Space should be pre-allocated in the dts for the bd_t.
|
||||
|
||||
CONFIG_OF_HAS_UBOOT_ENV
|
||||
|
||||
The resulting flat device tree will have a copy of u-boot's
|
||||
environment variables
|
||||
|
||||
CONFIG_OF_BOARD_SETUP
|
||||
|
||||
Board code has addition modification that it wants to make
|
||||
to the flat device tree before handing it off to the kernel
|
||||
|
||||
- Serial Ports:
|
||||
CFG_PL010_SERIAL
|
||||
@@ -606,7 +640,7 @@ The following options need to be configured:
|
||||
CFG_CMD_DIAG * Diagnostics
|
||||
CFG_CMD_DOC * Disk-On-Chip Support
|
||||
CFG_CMD_DTT * Digital Therm and Thermostat
|
||||
CFG_CMD_ECHO * echo arguments
|
||||
CFG_CMD_ECHO echo arguments
|
||||
CFG_CMD_EEPROM * EEPROM read/write support
|
||||
CFG_CMD_ELF * bootelf, bootvx
|
||||
CFG_CMD_ENV saveenv
|
||||
@@ -1456,6 +1490,12 @@ The following options need to be configured:
|
||||
of the backslashes before semicolons and special
|
||||
symbols.
|
||||
|
||||
- Commandline Editing and History:
|
||||
CONFIG_CMDLINE_EDITING
|
||||
|
||||
Enable editiong and History functions for interactive
|
||||
commandline input operations
|
||||
|
||||
- Default Environment:
|
||||
CONFIG_EXTRA_ENV_SETTINGS
|
||||
|
||||
@@ -1717,6 +1757,12 @@ Configuration Settings:
|
||||
- CFG_MALLOC_LEN:
|
||||
Size of DRAM reserved for malloc() use.
|
||||
|
||||
- CFG_BOOTM_LEN:
|
||||
Normally compressed uImages are limited to an
|
||||
uncompressed size of 8 MBytes. If this is not enough,
|
||||
you can define CFG_BOOTM_LEN in your board config file
|
||||
to adjust this setting to your needs.
|
||||
|
||||
- CFG_BOOTMAPSZ:
|
||||
Maximum size of memory mapped by the startup code of
|
||||
the Linux kernel; all data that must be processed by
|
||||
@@ -1946,6 +1992,17 @@ to save the current settings.
|
||||
These two #defines specify the offset and size of the environment
|
||||
area within the first NAND device.
|
||||
|
||||
- CFG_ENV_OFFSET_REDUND
|
||||
|
||||
This setting describes a second storage area of CFG_ENV_SIZE
|
||||
size used to hold a redundant copy of the environment data,
|
||||
so that there is a valid backup copy in case there is a
|
||||
power failure during a "saveenv" operation.
|
||||
|
||||
Note: CFG_ENV_OFFSET and CFG_ENV_OFFSET_REDUND must be aligned
|
||||
to a block boundary, and CFG_ENV_SIZE must be a multiple of
|
||||
the NAND devices block size.
|
||||
|
||||
- CFG_SPI_INIT_OFFSET
|
||||
|
||||
Defines offset to the initial SPI buffer area in DPRAM. The
|
||||
@@ -2266,6 +2323,26 @@ images ready for download to / installation on your system:
|
||||
- "u-boot" is an image in ELF binary format
|
||||
- "u-boot.srec" is in Motorola S-Record format
|
||||
|
||||
By default the build is performed locally and the objects are saved
|
||||
in the source directory. One of the two methods can be used to change
|
||||
this behavior and build U-Boot to some external directory:
|
||||
|
||||
1. Add O= to the make command line invocations:
|
||||
|
||||
make O=/tmp/build distclean
|
||||
make O=/tmp/build NAME_config
|
||||
make O=/tmp/build all
|
||||
|
||||
2. Set environment variable BUILD_DIR to point to the desired location:
|
||||
|
||||
export BUILD_DIR=/tmp/build
|
||||
make distclean
|
||||
make NAME_config
|
||||
make all
|
||||
|
||||
Note that the command line "O=" setting overrides the BUILD_DIR environment
|
||||
variable.
|
||||
|
||||
|
||||
Please be aware that the Makefiles assume you are using GNU make, so
|
||||
for instance on NetBSD you might need to use "gmake" instead of
|
||||
@@ -2319,6 +2396,22 @@ or to build on a native PowerPC system you can type
|
||||
|
||||
CROSS_COMPILE=' ' MAKEALL
|
||||
|
||||
When using the MAKEALL script, the default behaviour is to build U-Boot
|
||||
in the source directory. This location can be changed by setting the
|
||||
BUILD_DIR environment variable. Also, for each target built, the MAKEALL
|
||||
script saves two log files (<target>.ERR and <target>.MAKEALL) in the
|
||||
<source dir>/LOG directory. This default location can be changed by
|
||||
setting the MAKEALL_LOGDIR environment variable. For example:
|
||||
|
||||
export BUILD_DIR=/tmp/build
|
||||
export MAKEALL_LOGDIR=/tmp/log
|
||||
CROSS_COMPILE=ppc_8xx- MAKEALL
|
||||
|
||||
With the above settings build objects are saved in the /tmp/build, log
|
||||
files are saved in the /tmp/log and the source tree remains clean during
|
||||
the whole build process.
|
||||
|
||||
|
||||
See also "U-Boot Porting Guide" below.
|
||||
|
||||
|
||||
@@ -3260,6 +3353,8 @@ On ARM, the following registers are used:
|
||||
|
||||
==> U-Boot will use R8 to hold a pointer to the global data
|
||||
|
||||
NOTE: DECLARE_GLOBAL_DATA_PTR must be used with file-global scope,
|
||||
or current versions of GCC may "optimize" the code too much.
|
||||
|
||||
Memory Management:
|
||||
------------------
|
||||
@@ -3410,12 +3505,19 @@ Coding Standards:
|
||||
-----------------
|
||||
|
||||
All contributions to U-Boot should conform to the Linux kernel
|
||||
coding style; see the file "Documentation/CodingStyle" in your Linux
|
||||
kernel source directory.
|
||||
coding style; see the file "Documentation/CodingStyle" and the script
|
||||
"scripts/Lindent" in your Linux kernel source directory. In sources
|
||||
originating from U-Boot a style corresponding to "Lindent -pcs" (adding
|
||||
spaces before parameters to function calls) is actually used.
|
||||
|
||||
Please note that U-Boot is implemented in C (and to some small parts
|
||||
in Assembler); no C++ is used, so please do not use C++ style
|
||||
comments (//) in your code.
|
||||
Source files originating from a different project (for example the
|
||||
MTD subsystem) are generally exempt from these guidelines and are not
|
||||
reformated to ease subsequent migration to newer versions of those
|
||||
sources.
|
||||
|
||||
Please note that U-Boot is implemented in C (and to some small parts in
|
||||
Assembler); no C++ is used, so please do not use C++ style comments (//)
|
||||
in your code.
|
||||
|
||||
Please also stick to the following formatting rules:
|
||||
- remove any trailing white space
|
||||
|
||||
24
blackfin_config.mk
Normal file
24
blackfin_config.mk
Normal file
@@ -0,0 +1,24 @@
|
||||
#
|
||||
# (C) Copyright 2000-2002
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
PLATFORM_CPPFLAGS += -DCONFIG_BLACKFIN -D__blackfin__
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2003
|
||||
# (C) Copyright 2003-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,18 +23,22 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
|
||||
$(LIB): .depend $(OBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
162
board/BuS/EB+MCF-EV123/EB+MCF-EV123.c
Normal file
162
board/BuS/EB+MCF-EV123/EB+MCF-EV123.c
Normal file
@@ -0,0 +1,162 @@
|
||||
/*
|
||||
* (C) Copyright 2005
|
||||
* BuS Elektronik GmbH & Co.KG <esw@bus-elektonik.de>
|
||||
*
|
||||
* (C) Copyright 2000-2003
|
||||
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <command.h>
|
||||
#include "asm/m5282.h"
|
||||
#include "VCxK.h"
|
||||
|
||||
int checkboard (void)
|
||||
{
|
||||
puts ("Board: MCF-EV1 + MCF-EV23 (BuS Elektronik GmbH & Co. KG)\n");
|
||||
#if (TEXT_BASE == CFG_INT_FLASH_BASE)
|
||||
puts (" Boot from Internal FLASH\n");
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
long int initdram (int board_type)
|
||||
{
|
||||
int size,i;
|
||||
|
||||
size = 0;
|
||||
MCFSDRAMC_DCR = MCFSDRAMC_DCR_RTIM_6
|
||||
| MCFSDRAMC_DCR_RC((15 * CFG_CLK)>>4);
|
||||
#ifdef CFG_SDRAM_BASE0
|
||||
|
||||
MCFSDRAMC_DACR0 = MCFSDRAMC_DACR_BASE(CFG_SDRAM_BASE0)
|
||||
| MCFSDRAMC_DACR_CASL(1)
|
||||
| MCFSDRAMC_DACR_CBM(3)
|
||||
| MCFSDRAMC_DACR_PS_16);
|
||||
|
||||
MCFSDRAMC_DMR0 = MCFSDRAMC_DMR_BAM_16M
|
||||
| MCFSDRAMC_DMR_V;
|
||||
|
||||
MCFSDRAMC_DACR0 |= MCFSDRAMC_DACR_IP;
|
||||
|
||||
*(unsigned short *)(CFG_SDRAM_BASE0) = 0xA5A5;
|
||||
MCFSDRAMC_DACR0 |= MCFSDRAMC_DACR_RE;
|
||||
for (i=0; i < 2000; i++)
|
||||
asm(" nop");
|
||||
mbar_writeLong(MCFSDRAMC_DACR0, mbar_readLong(MCFSDRAMC_DACR0)
|
||||
| MCFSDRAMC_DACR_IMRS);
|
||||
*(unsigned int *)(CFG_SDRAM_BASE0 + 0x220) = 0xA5A5;
|
||||
size += CFG_SDRAM_SIZE * 1024 * 1024;
|
||||
#endif
|
||||
#ifdef CFG_SDRAM_BASE1
|
||||
MCFSDRAMC_DACR1 = MCFSDRAMC_DACR_BASE(CFG_SDRAM_BASE1)
|
||||
| MCFSDRAMC_DACR_CASL(1)
|
||||
| MCFSDRAMC_DACR_CBM(3)
|
||||
| MCFSDRAMC_DACR_PS_16;
|
||||
|
||||
MCFSDRAMC_DMR1 = MCFSDRAMC_DMR_BAM_16M
|
||||
| MCFSDRAMC_DMR_V;
|
||||
|
||||
MCFSDRAMC_DACR1 |= MCFSDRAMC_DACR_IP;
|
||||
|
||||
*(unsigned short *)(CFG_SDRAM_BASE1) = 0xA5A5;
|
||||
MCFSDRAMC_DACR1 |= MCFSDRAMC_DACR_RE;
|
||||
for (i=0; i < 2000; i++)
|
||||
asm(" nop");
|
||||
MCFSDRAMC_DACR1 |= MCFSDRAMC_DACR_IMRS;
|
||||
*(unsigned int *)(CFG_SDRAM_BASE1 + 0x220) = 0xA5A5;
|
||||
size += CFG_SDRAM_SIZE1 * 1024 * 1024;
|
||||
#endif
|
||||
return size;
|
||||
}
|
||||
|
||||
|
||||
#if defined(CFG_DRAM_TEST)
|
||||
int testdram (void)
|
||||
{
|
||||
uint *pstart = (uint *) CFG_MEMTEST_START;
|
||||
uint *pend = (uint *) CFG_MEMTEST_END;
|
||||
uint *p;
|
||||
|
||||
printf("SDRAM test phase 1:\n");
|
||||
for (p = pstart; p < pend; p++)
|
||||
*p = 0xaaaaaaaa;
|
||||
|
||||
for (p = pstart; p < pend; p++) {
|
||||
if (*p != 0xaaaaaaaa) {
|
||||
printf ("SDRAM test fails at: %08x\n", (uint) p);
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
printf("SDRAM test phase 2:\n");
|
||||
for (p = pstart; p < pend; p++)
|
||||
*p = 0x55555555;
|
||||
|
||||
for (p = pstart; p < pend; p++) {
|
||||
if (*p != 0x55555555) {
|
||||
printf ("SDRAM test fails at: %08x\n", (uint) p);
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
printf("SDRAM test passed.\n");
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
int misc_init_r(void)
|
||||
{
|
||||
init_vcxk();
|
||||
return 1;
|
||||
}
|
||||
|
||||
/*---------------------------------------------------------------------------*/
|
||||
|
||||
int do_vcimage (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
|
||||
{
|
||||
int rcode = 0;
|
||||
ulong source;
|
||||
|
||||
switch (argc) {
|
||||
case 2:
|
||||
source = simple_strtoul(argv[1],NULL,16);
|
||||
vcxk_loadimage(source);
|
||||
rcode = 0;
|
||||
break;
|
||||
default:
|
||||
printf ("Usage:\n%s\n", cmdtp->usage);
|
||||
rcode = 1;
|
||||
break;
|
||||
}
|
||||
return rcode;
|
||||
}
|
||||
|
||||
/***************************************************/
|
||||
|
||||
U_BOOT_CMD(
|
||||
vcimage, 2, 0, do_vcimage,
|
||||
"vcimage - loads an image to Display\n",
|
||||
"vcimage addr\n"
|
||||
);
|
||||
|
||||
/* EOF EB+MCF-EV123c */
|
||||
44
board/BuS/EB+MCF-EV123/Makefile
Normal file
44
board/BuS/EB+MCF-EV123/Makefile
Normal file
@@ -0,0 +1,44 @@
|
||||
#
|
||||
# (C) Copyright 2000-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
COBJS = $(BOARD).o cfm_flash.o flash.o VCxK.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
#########################################################################
|
||||
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
136
board/BuS/EB+MCF-EV123/VCxK.c
Normal file
136
board/BuS/EB+MCF-EV123/VCxK.c
Normal file
@@ -0,0 +1,136 @@
|
||||
/*
|
||||
* (C) Copyright 2005
|
||||
* BuS Elektronik GmbH & Co.KG <esw@bus-elektonik.de>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <asm/m5282.h>
|
||||
#include "VCxK.h"
|
||||
|
||||
vu_char *vcxk_bws = (vu_char *)(CFG_CS3_BASE);
|
||||
#define VCXK_BWS vcxk_bws
|
||||
|
||||
static ulong vcxk_driver;
|
||||
|
||||
|
||||
ulong search_vcxk_driver(void);
|
||||
void vcxk_cls(void);
|
||||
void vcxk_setbrightness(short brightness);
|
||||
int vcxk_request(void);
|
||||
int vcxk_acknowledge_wait(void);
|
||||
void vcxk_clear(void);
|
||||
|
||||
int init_vcxk(void)
|
||||
{
|
||||
VIDEO_Invert_CFG &= ~VIDEO_Invert_IO;
|
||||
VIDEO_INVERT_PORT |= VIDEO_INVERT_PIN;
|
||||
VIDEO_INVERT_DDR |= VIDEO_INVERT_PIN;
|
||||
|
||||
VIDEO_REQUEST_PORT |= VIDEO_REQUEST_PIN;
|
||||
VIDEO_REQUEST_DDR |= VIDEO_REQUEST_PIN;
|
||||
|
||||
VIDEO_ACKNOWLEDGE_DDR &= ~VIDEO_ACKNOWLEDGE_PIN;
|
||||
|
||||
vcxk_driver = search_vcxk_driver();
|
||||
if (vcxk_driver)
|
||||
{
|
||||
/* use flash resist driver */
|
||||
}
|
||||
else
|
||||
{
|
||||
vcxk_cls();
|
||||
vcxk_cls();
|
||||
vcxk_setbrightness(1000);
|
||||
}
|
||||
VIDEO_ENABLE_DDR |= VIDEO_ENABLE_PIN;
|
||||
VIDEO_ENABLE_PORT |= VIDEO_ENABLE_PIN;
|
||||
VIDEO_ENABLE_PORT &= ~VIDEO_ENABLE_PIN;
|
||||
return 1;
|
||||
}
|
||||
|
||||
void vcxk_loadimage(ulong source)
|
||||
{
|
||||
int cnt;
|
||||
vcxk_acknowledge_wait();
|
||||
for (cnt=0; cnt<16384; cnt++)
|
||||
{
|
||||
VCXK_BWS[cnt*2] = (*(vu_char*) source);
|
||||
source++;
|
||||
}
|
||||
vcxk_request();
|
||||
}
|
||||
|
||||
void vcxk_cls(void)
|
||||
{
|
||||
vcxk_acknowledge_wait();
|
||||
vcxk_clear();
|
||||
vcxk_request();
|
||||
}
|
||||
|
||||
void vcxk_clear(void)
|
||||
{
|
||||
int cnt;
|
||||
for (cnt=0; cnt<16384; cnt++)
|
||||
{
|
||||
VCXK_BWS[cnt*2] = 0x00;
|
||||
}
|
||||
}
|
||||
|
||||
void vcxk_setbrightness(short brightness)
|
||||
{
|
||||
VCXK_BWS[0x8000]=(brightness >> 4) +2;
|
||||
VCXK_BWS[0xC000]= (brightness + 23) >> 8;
|
||||
VCXK_BWS[0xC001]= (brightness + 23) & 0xFF;
|
||||
}
|
||||
|
||||
int vcxk_request(void)
|
||||
{
|
||||
if (vcxk_driver)
|
||||
{
|
||||
/* use flash resist driver */
|
||||
}
|
||||
else
|
||||
{
|
||||
VIDEO_REQUEST_PORT &= ~VIDEO_REQUEST_PIN;
|
||||
VIDEO_REQUEST_PORT |= VIDEO_REQUEST_PIN;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
int vcxk_acknowledge_wait(void)
|
||||
{
|
||||
if (vcxk_driver)
|
||||
{
|
||||
/* use flash resist driver */
|
||||
}
|
||||
else
|
||||
{
|
||||
while (!(VIDEO_ACKNOWLEDGE_PORT & VIDEO_ACKNOWLEDGE_PIN));
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
ulong search_vcxk_driver(void)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* eof */
|
||||
48
board/BuS/EB+MCF-EV123/VCxK.h
Normal file
48
board/BuS/EB+MCF-EV123/VCxK.h
Normal file
@@ -0,0 +1,48 @@
|
||||
/*
|
||||
* (C) Copyright 2005
|
||||
* BuS Elektronik GmbH & Co.KG <esw@bus-elektonik.de>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#ifndef __VCXK_H_
|
||||
#define __VCXK_H_
|
||||
|
||||
extern int init_vcxk(void);
|
||||
void vcxk_loadimage(ulong source);
|
||||
|
||||
#define VIDEO_ACKNOWLEDGE_PORT MCFGPTB_GPTPORT
|
||||
#define VIDEO_ACKNOWLEDGE_DDR MCFGPTB_GPTDDR
|
||||
#define VIDEO_ACKNOWLEDGE_PIN 0x0001
|
||||
|
||||
#define VIDEO_ENABLE_PORT MCFGPTB_GPTPORT
|
||||
#define VIDEO_ENABLE_DDR MCFGPTB_GPTDDR
|
||||
#define VIDEO_ENABLE_PIN 0x0002
|
||||
|
||||
#define VIDEO_REQUEST_PORT MCFGPTB_GPTPORT
|
||||
#define VIDEO_REQUEST_DDR MCFGPTB_GPTDDR
|
||||
#define VIDEO_REQUEST_PIN 0x0004
|
||||
|
||||
#define VIDEO_Invert_CFG MCFGPIO_PEPAR
|
||||
#define VIDEO_Invert_IO MCFGPIO_PEPAR_PEPA2
|
||||
#define VIDEO_INVERT_PORT MCFGPIO_PORTE
|
||||
#define VIDEO_INVERT_DDR MCFGPIO_DDRE
|
||||
#define VIDEO_INVERT_PIN MCFGPIO_PORT2
|
||||
|
||||
#endif
|
||||
212
board/BuS/EB+MCF-EV123/cfm_flash.c
Normal file
212
board/BuS/EB+MCF-EV123/cfm_flash.c
Normal file
@@ -0,0 +1,212 @@
|
||||
/*
|
||||
* Basic Flash Driver for Freescale MCF 5281/5282 internal FLASH
|
||||
*
|
||||
* (C) Copyright 2005 BuS Elektronik GmbH & Co.KG <esw@bus-elektonik.de>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <asm/m5282.h>
|
||||
#include "cfm_flash.h"
|
||||
|
||||
#if defined(CONFIG_M5281) || defined(CONFIG_M5282)
|
||||
|
||||
#if (CFG_CLK>20000000)
|
||||
#define CFM_CLK (((long) CFG_CLK / (400000 * 8) + 1) | 0x40)
|
||||
#else
|
||||
#define CFM_CLK ((long) CFG_CLK / 400000 + 1)
|
||||
#endif
|
||||
|
||||
#define cmf_backdoor_address(addr) (((addr) & 0x0007FFFF) | 0x04000000 | \
|
||||
(CFG_MBAR & 0xC0000000))
|
||||
|
||||
void cfm_flash_print_info (flash_info_t * info)
|
||||
{
|
||||
printf ("Freescale: ");
|
||||
switch (info->flash_id & FLASH_TYPEMASK) {
|
||||
case FREESCALE_ID_MCF5281 & FLASH_TYPEMASK:
|
||||
printf ("MCF5281 internal FLASH\n");
|
||||
break;
|
||||
case FREESCALE_ID_MCF5282 & FLASH_TYPEMASK:
|
||||
printf ("MCF5282 internal FLASH\n");
|
||||
break;
|
||||
default:
|
||||
printf ("Unknown Chip Type\n");
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void cfm_flash_init (flash_info_t * info)
|
||||
{
|
||||
int sector;
|
||||
ulong protection;
|
||||
MCFCFM_MCR = 0;
|
||||
MCFCFM_CLKD = CFM_CLK;
|
||||
debug ("CFM Clock divider: %ld (%d Hz @ %ld Hz)\n",CFM_CLK,\
|
||||
CFG_CLK / (2* ((CFM_CLK & 0x3F)+1) * (1+((CFM_CLK & 0x40)>>6)*7)),\
|
||||
CFG_CLK);
|
||||
MCFCFM_SACC = 0;
|
||||
MCFCFM_DACC = 0;
|
||||
|
||||
if (MCFCFM_SEC & MCFCFM_SEC_KEYEN)
|
||||
puts("CFM backdoor access is enabled\n");
|
||||
if (MCFCFM_SEC & MCFCFM_SEC_SECSTAT)
|
||||
puts("CFM securety is enabled\n");
|
||||
|
||||
#ifdef CONFIG_M5281
|
||||
info->flash_id = (FREESCALE_MANUFACT & FLASH_VENDMASK) |
|
||||
(FREESCALE_ID_MCF5281 & FLASH_TYPEMASK);
|
||||
info->size = 256*1024;
|
||||
info->sector_count = 16;
|
||||
#else
|
||||
info->flash_id = (FREESCALE_MANUFACT & FLASH_VENDMASK) |
|
||||
(FREESCALE_ID_MCF5282 & FLASH_TYPEMASK);
|
||||
info->size = 512*1024;
|
||||
info->sector_count = 32;
|
||||
#endif
|
||||
protection = MCFCFM_PROT;
|
||||
for (sector = 0; sector < info->sector_count; sector++)
|
||||
{
|
||||
if (sector == 0)
|
||||
{
|
||||
info->start[sector] = CFG_INT_FLASH_BASE;
|
||||
}
|
||||
else
|
||||
{
|
||||
info->start[sector] = info->start[sector-1] + 0x04000;
|
||||
}
|
||||
info->protect[sector] = protection & 1;
|
||||
protection >>= 1;
|
||||
}
|
||||
}
|
||||
|
||||
int cfm_flash_readycheck(int checkblank)
|
||||
{
|
||||
int rc;
|
||||
unsigned char state;
|
||||
|
||||
rc = ERR_OK;
|
||||
while (!(MCFCFM_USTAT & MCFCFM_USTAT_CCIF));
|
||||
state = MCFCFM_USTAT;
|
||||
if (state & MCFCFM_USTAT_ACCERR)
|
||||
{
|
||||
debug ("%s(): CFM access error",__FUNCTION__);
|
||||
rc = ERR_PROG_ERROR;
|
||||
}
|
||||
if (state & MCFCFM_USTAT_PVIOL)
|
||||
{
|
||||
debug ("%s(): CFM protection violation",__FUNCTION__);
|
||||
rc = ERR_PROTECTED;
|
||||
}
|
||||
if (checkblank)
|
||||
{
|
||||
if (!(state & MCFCFM_USTAT_BLANK))
|
||||
{
|
||||
debug ("%s(): CFM erras error",__FUNCTION__);
|
||||
rc = ERR_NOT_ERASED;
|
||||
}
|
||||
}
|
||||
MCFCFM_USTAT = state & 0x34; /* reset state */
|
||||
return rc;
|
||||
}
|
||||
|
||||
/* Erase 16KiB = 8 2KiB pages */
|
||||
|
||||
int cfm_flash_erase_sector (flash_info_t * info, int sector)
|
||||
{
|
||||
ulong address;
|
||||
int page;
|
||||
int rc;
|
||||
rc= ERR_OK;
|
||||
address = cmf_backdoor_address(info->start[sector]);
|
||||
for (page=0; (page<8) && (rc==ERR_OK); page++)
|
||||
{
|
||||
*(volatile __u32*) address = 0;
|
||||
MCFCFM_CMD = MCFCFM_CMD_PGERS;
|
||||
MCFCFM_USTAT = MCFCFM_USTAT_CBEIF;
|
||||
rc = cfm_flash_readycheck(0);
|
||||
if (rc==ERR_OK)
|
||||
{
|
||||
*(volatile __u32*) address = 0;
|
||||
MCFCFM_CMD = MCFCFM_CMD_PGERSVER;
|
||||
MCFCFM_USTAT = MCFCFM_USTAT_CBEIF;
|
||||
rc = cfm_flash_readycheck(1);
|
||||
}
|
||||
address += 0x800;
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
|
||||
int cfm_flash_write_buff (flash_info_t * info, uchar * src, ulong addr, ulong cnt)
|
||||
{
|
||||
int rc;
|
||||
ulong dest, data;
|
||||
|
||||
rc = ERR_OK;
|
||||
if (addr & 3)
|
||||
{
|
||||
debug ("Byte and Word alignment not supported\n");
|
||||
rc = ERR_ALIGN;
|
||||
}
|
||||
if (cnt & 3)
|
||||
{
|
||||
debug ("Byte and Word transfer not supported\n");
|
||||
rc = ERR_ALIGN;
|
||||
}
|
||||
dest = cmf_backdoor_address(addr);
|
||||
while ((cnt>=4) && (rc == ERR_OK))
|
||||
{
|
||||
data =*((volatile u32 *) src);
|
||||
*(volatile u32*) dest = data;
|
||||
MCFCFM_CMD = MCFCFM_CMD_PGM;
|
||||
MCFCFM_USTAT = MCFCFM_USTAT_CBEIF;
|
||||
rc = cfm_flash_readycheck(0);
|
||||
if (*(volatile u32*) addr != data) rc = ERR_PROG_ERROR;
|
||||
src +=4;
|
||||
dest +=4;
|
||||
addr +=4;
|
||||
cnt -=4;
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
|
||||
#ifdef CFG_FLASH_PROTECTION
|
||||
|
||||
int cfm_flash_protect(flash_info_t * info,long sector,int prot)
|
||||
{
|
||||
int rc;
|
||||
|
||||
rc= ERR_OK;
|
||||
if (prot)
|
||||
{
|
||||
MCFCFM_PROT |= (1<<sector);
|
||||
info->protect[sector]=1;
|
||||
}
|
||||
else
|
||||
{
|
||||
MCFCFM_PROT &= ~(1<<sector);
|
||||
info->protect[sector]=0;
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
40
board/BuS/EB+MCF-EV123/cfm_flash.h
Normal file
40
board/BuS/EB+MCF-EV123/cfm_flash.h
Normal file
@@ -0,0 +1,40 @@
|
||||
/*
|
||||
* Basic Flash Driver for Freescale MCF 5282 internal FLASH
|
||||
*
|
||||
* (C) Copyright 2005 BuS Elektronik GmbH & Co.KG <esw@bus-elektonik.de>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#ifndef __CFM_FLASH_H_
|
||||
#define __CFM_FLASH_H_
|
||||
|
||||
#define FREESCALE_MANUFACT 0xFACFFACF
|
||||
#define FREESCALE_ID_MCF5281 0x5281
|
||||
#define FREESCALE_ID_MCF5282 0x5282
|
||||
|
||||
extern void cfm_flash_print_info (flash_info_t * info);
|
||||
extern int cfm_flash_erase_sector (flash_info_t * info, int sector);
|
||||
extern void cfm_flash_init (flash_info_t * info);
|
||||
extern int cfm_flash_write_buff (flash_info_t * info, uchar * src, ulong addr, ulong cnt);
|
||||
#ifdef CFG_FLASH_PROTECTION
|
||||
extern int cfm_flash_protect(flash_info_t * info,long sector,int prot);
|
||||
#endif
|
||||
|
||||
#endif
|
||||
28
board/BuS/EB+MCF-EV123/config.mk
Normal file
28
board/BuS/EB+MCF-EV123/config.mk
Normal file
@@ -0,0 +1,28 @@
|
||||
#
|
||||
# (C) Copyright 2000-2003
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
# Coldfire contribution by Bernhard Kuhn <bkuhn@metrowerks.com>
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
sinclude $(TOPDIR)/board/$(BOARDDIR)/textbase.mk
|
||||
ifndef TEXT_BASE
|
||||
TEXT_BASE = 0xFE000000
|
||||
endif
|
||||
413
board/BuS/EB+MCF-EV123/flash.c
Normal file
413
board/BuS/EB+MCF-EV123/flash.c
Normal file
@@ -0,0 +1,413 @@
|
||||
/*
|
||||
* (C) Copyright 2005
|
||||
* BuS Elektronik GmbH & Co.KG <esw@bus-elektonik.de>
|
||||
*
|
||||
* Based On
|
||||
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include "cfm_flash.h"
|
||||
|
||||
#define PHYS_FLASH_1 CFG_FLASH_BASE
|
||||
#define FLASH_BANK_SIZE 0x200000
|
||||
|
||||
flash_info_t flash_info[CFG_MAX_FLASH_BANKS];
|
||||
|
||||
void flash_print_info (flash_info_t * info)
|
||||
{
|
||||
int i;
|
||||
|
||||
switch (info->flash_id & FLASH_VENDMASK) {
|
||||
case (AMD_MANUFACT & FLASH_VENDMASK):
|
||||
printf ("AMD: ");
|
||||
switch (info->flash_id & FLASH_TYPEMASK) {
|
||||
case (AMD_ID_LV160B & FLASH_TYPEMASK):
|
||||
printf ("AM29LV160B (16Bit)\n");
|
||||
break;
|
||||
default:
|
||||
printf ("Unknown Chip Type\n");
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case FREESCALE_MANUFACT & FLASH_VENDMASK:
|
||||
cfm_flash_print_info (info);
|
||||
break;
|
||||
default:
|
||||
printf ("Unknown Vendor ");
|
||||
break;
|
||||
}
|
||||
|
||||
puts (" Size: ");
|
||||
if ((info->size >> 20) > 0)
|
||||
{
|
||||
printf ("%ld MiB",info->size >> 20);
|
||||
}
|
||||
else
|
||||
{
|
||||
printf ("%ld KiB",info->size >> 10);
|
||||
}
|
||||
printf (" in %d Sectors\n", info->sector_count);
|
||||
|
||||
printf (" Sector Start Addresses:");
|
||||
for (i = 0; i < info->sector_count; i++) {
|
||||
if ((i % 4) == 0) {
|
||||
printf ("\n ");
|
||||
}
|
||||
printf ("%02d: %08lX%s ", i,info->start[i],
|
||||
info->protect[i] ? " P" : " ");
|
||||
}
|
||||
printf ("\n\n");
|
||||
}
|
||||
|
||||
unsigned long flash_init (void)
|
||||
{
|
||||
int i, j;
|
||||
ulong size = 0;
|
||||
|
||||
for (i = 0; i < CFG_MAX_FLASH_BANKS; i++) {
|
||||
ulong flashbase = 0;
|
||||
|
||||
switch (i)
|
||||
{
|
||||
case 1:
|
||||
flash_info[i].flash_id =
|
||||
(AMD_MANUFACT & FLASH_VENDMASK) |
|
||||
(AMD_ID_LV160B & FLASH_TYPEMASK);
|
||||
flash_info[i].size = FLASH_BANK_SIZE;
|
||||
flash_info[i].sector_count = CFG_MAX_FLASH_SECT;
|
||||
memset (flash_info[i].protect, 0, CFG_MAX_FLASH_SECT);
|
||||
flashbase = PHYS_FLASH_1;
|
||||
for (j = 0; j < flash_info[i].sector_count; j++) {
|
||||
if (j == 0) {
|
||||
/* 1st is 16 KiB */
|
||||
flash_info[i].start[j] = flashbase;
|
||||
}
|
||||
if ((j >= 1) && (j <= 2)) {
|
||||
/* 2nd and 3rd are 8 KiB */
|
||||
flash_info[i].start[j] =
|
||||
flashbase + 0x4000 + 0x2000 * (j - 1);
|
||||
}
|
||||
if (j == 3) {
|
||||
/* 4th is 32 KiB */
|
||||
flash_info[i].start[j] = flashbase + 0x8000;
|
||||
}
|
||||
if ((j >= 4) && (j <= 34)) {
|
||||
/* rest is 256 KiB */
|
||||
flash_info[i].start[j] =
|
||||
flashbase + 0x10000 + 0x10000 * (j - 4);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 0:
|
||||
cfm_flash_init (&flash_info[i]);
|
||||
break;
|
||||
default:
|
||||
panic ("configured to many flash banks!\n");
|
||||
}
|
||||
|
||||
size += flash_info[i].size;
|
||||
}
|
||||
|
||||
flash_protect (FLAG_PROTECT_SET,
|
||||
CFG_FLASH_BASE,
|
||||
CFG_FLASH_BASE + 0xffff, &flash_info[0]);
|
||||
|
||||
return size;
|
||||
}
|
||||
|
||||
#define CMD_READ_ARRAY 0x00F0
|
||||
#define CMD_UNLOCK1 0x00AA
|
||||
#define CMD_UNLOCK2 0x0055
|
||||
#define CMD_ERASE_SETUP 0x0080
|
||||
#define CMD_ERASE_CONFIRM 0x0030
|
||||
#define CMD_PROGRAM 0x00A0
|
||||
#define CMD_UNLOCK_BYPASS 0x0020
|
||||
|
||||
#define MEM_FLASH_ADDR1 (*(volatile u16 *)(info->start[0] + (0x00000555<<1)))
|
||||
#define MEM_FLASH_ADDR2 (*(volatile u16 *)(info->start[0] + (0x000002AA<<1)))
|
||||
|
||||
|
||||
#define BIT_ERASE_DONE 0x0080
|
||||
#define BIT_RDY_MASK 0x0080
|
||||
#define BIT_PROGRAM_ERROR 0x0020
|
||||
#define BIT_TIMEOUT 0x80000000 /* our flag */
|
||||
|
||||
#define ERR_READY -1
|
||||
|
||||
int amd_flash_erase_sector(flash_info_t * info, int sector)
|
||||
{
|
||||
int state;
|
||||
ulong result;
|
||||
|
||||
volatile u16 *addr =
|
||||
(volatile u16 *) (info->start[sector]);
|
||||
|
||||
MEM_FLASH_ADDR1 = CMD_UNLOCK1;
|
||||
MEM_FLASH_ADDR2 = CMD_UNLOCK2;
|
||||
MEM_FLASH_ADDR1 = CMD_ERASE_SETUP;
|
||||
|
||||
MEM_FLASH_ADDR1 = CMD_UNLOCK1;
|
||||
MEM_FLASH_ADDR2 = CMD_UNLOCK2;
|
||||
*addr = CMD_ERASE_CONFIRM;
|
||||
|
||||
/* wait until flash is ready */
|
||||
state = 0;
|
||||
set_timer (0);
|
||||
|
||||
do {
|
||||
result = *addr;
|
||||
|
||||
/* check timeout */
|
||||
if (get_timer (0) > CFG_FLASH_ERASE_TOUT) {
|
||||
MEM_FLASH_ADDR1 = CMD_READ_ARRAY;
|
||||
state = ERR_TIMOUT;
|
||||
}
|
||||
|
||||
if (!state && (result & 0xFFFF) & BIT_ERASE_DONE)
|
||||
state = ERR_READY;
|
||||
}
|
||||
while (!state);
|
||||
if (state == ERR_READY)
|
||||
state = ERR_OK;
|
||||
|
||||
MEM_FLASH_ADDR1 = CMD_READ_ARRAY;
|
||||
|
||||
return state;
|
||||
}
|
||||
|
||||
int flash_erase (flash_info_t * info, int s_first, int s_last)
|
||||
{
|
||||
int iflag, cflag;
|
||||
int sector;
|
||||
int rc;
|
||||
|
||||
rc = ERR_OK;
|
||||
|
||||
if (info->flash_id == FLASH_UNKNOWN)
|
||||
{
|
||||
rc = ERR_UNKNOWN_FLASH_TYPE;
|
||||
} /* (info->flash_id == FLASH_UNKNOWN) */
|
||||
|
||||
if ((s_first < 0) || (s_first > s_last) || s_last >= info->sector_count)
|
||||
{
|
||||
rc = ERR_INVAL;
|
||||
}
|
||||
|
||||
cflag = icache_status ();
|
||||
icache_disable ();
|
||||
iflag = disable_interrupts ();
|
||||
|
||||
for (sector = s_first; (sector <= s_last) && (rc == ERR_OK); sector++) {
|
||||
|
||||
if (info->protect[sector])
|
||||
{
|
||||
putc('P'); /* protected sector will not erase */
|
||||
}
|
||||
else
|
||||
{
|
||||
/* erase on unprotected sector */
|
||||
puts("E\b");
|
||||
switch (info->flash_id & FLASH_VENDMASK)
|
||||
{
|
||||
case (AMD_MANUFACT & FLASH_VENDMASK):
|
||||
rc = amd_flash_erase_sector(info,sector);
|
||||
break;
|
||||
case (FREESCALE_MANUFACT & FLASH_VENDMASK):
|
||||
rc = cfm_flash_erase_sector(info,sector);
|
||||
break;
|
||||
default:
|
||||
return ERR_UNKNOWN_FLASH_VENDOR;
|
||||
}
|
||||
putc('.');
|
||||
}
|
||||
}
|
||||
if (rc!=ERR_OK)
|
||||
{
|
||||
printf ("\n ");
|
||||
flash_perror (rc);
|
||||
}
|
||||
else
|
||||
{
|
||||
printf (" done\n");
|
||||
}
|
||||
|
||||
udelay (10000); /* allow flash to settle - wait 10 ms */
|
||||
|
||||
if (iflag)
|
||||
enable_interrupts ();
|
||||
|
||||
if (cflag)
|
||||
icache_enable ();
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
||||
volatile static int amd_write_word (flash_info_t * info, ulong dest, u16 data)
|
||||
{
|
||||
volatile u16 *addr;
|
||||
ulong result;
|
||||
int cflag, iflag;
|
||||
int state;
|
||||
|
||||
/*
|
||||
* Check if Flash is (sufficiently) erased
|
||||
*/
|
||||
addr = (volatile u16 *) dest;
|
||||
|
||||
result = *addr;
|
||||
if ((result & data) != data)
|
||||
return ERR_NOT_ERASED;
|
||||
|
||||
/*
|
||||
* Disable interrupts which might cause a timeout
|
||||
* here. Remember that our exception vectors are
|
||||
* at address 0 in the flash, and we don't want a
|
||||
* (ticker) exception to happen while the flash
|
||||
* chip is in programming mode.
|
||||
*/
|
||||
|
||||
cflag = icache_status ();
|
||||
icache_disable ();
|
||||
iflag = disable_interrupts ();
|
||||
|
||||
MEM_FLASH_ADDR1 = CMD_UNLOCK1;
|
||||
MEM_FLASH_ADDR2 = CMD_UNLOCK2;
|
||||
MEM_FLASH_ADDR1 = CMD_PROGRAM;
|
||||
*addr = data;
|
||||
|
||||
/* arm simple, non interrupt dependent timer */
|
||||
set_timer (0);
|
||||
|
||||
/* wait until flash is ready */
|
||||
state = 0;
|
||||
do {
|
||||
result = *addr;
|
||||
|
||||
/* check timeout */
|
||||
if (get_timer (0) > CFG_FLASH_ERASE_TOUT) {
|
||||
state = ERR_TIMOUT;
|
||||
}
|
||||
if (!state && ((result & BIT_RDY_MASK) == (data & BIT_RDY_MASK)))
|
||||
state = ERR_READY;
|
||||
|
||||
} while (!state);
|
||||
|
||||
*addr = CMD_READ_ARRAY;
|
||||
|
||||
if (state == ERR_READY)
|
||||
state = ERR_OK;
|
||||
if ((*addr != data) && (state != ERR_TIMOUT))
|
||||
state = ERR_PROG_ERROR;
|
||||
|
||||
if (iflag)
|
||||
enable_interrupts ();
|
||||
|
||||
if (cflag)
|
||||
icache_enable ();
|
||||
|
||||
return state;
|
||||
}
|
||||
|
||||
int amd_flash_write_buff(flash_info_t * info, uchar * src, ulong addr, ulong cnt)
|
||||
{
|
||||
int rc;
|
||||
ulong dest;
|
||||
u16 data;
|
||||
|
||||
rc = ERR_OK;
|
||||
if (addr & 1)
|
||||
{
|
||||
debug ("Byte alignment not supported\n");
|
||||
rc = ERR_ALIGN;
|
||||
}
|
||||
if (cnt & 1)
|
||||
{
|
||||
debug ("Byte transfer not supported\n");
|
||||
rc = ERR_ALIGN;
|
||||
}
|
||||
|
||||
dest = addr;
|
||||
while ((cnt>=2) && (rc == ERR_OK))
|
||||
{
|
||||
data =*((volatile u16 *) src);
|
||||
rc=amd_write_word (info,dest,data);
|
||||
src +=2;
|
||||
dest +=2;
|
||||
cnt -=2;
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
|
||||
int write_buff (flash_info_t * info, uchar * src, ulong addr, ulong cnt)
|
||||
{
|
||||
int rc;
|
||||
|
||||
switch (info->flash_id & FLASH_VENDMASK)
|
||||
{
|
||||
case (AMD_MANUFACT & FLASH_VENDMASK):
|
||||
rc = amd_flash_write_buff(info,src,addr,cnt);
|
||||
break;
|
||||
case (FREESCALE_MANUFACT & FLASH_VENDMASK):
|
||||
rc = cfm_flash_write_buff(info,src,addr,cnt);
|
||||
break;
|
||||
default:
|
||||
rc = ERR_UNKNOWN_FLASH_VENDOR;
|
||||
}
|
||||
return rc;
|
||||
|
||||
}
|
||||
int amd_flash_protect(flash_info_t * info,long sector,int prot)
|
||||
{
|
||||
int rc;
|
||||
rc= ERR_OK;
|
||||
if (prot)
|
||||
{
|
||||
info->protect[sector]=1;
|
||||
}
|
||||
else
|
||||
{
|
||||
info->protect[sector]=0;
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
|
||||
#ifdef CFG_FLASH_PROTECTION
|
||||
|
||||
int flash_real_protect(flash_info_t * info,long sector,int prot)
|
||||
{
|
||||
int rc;
|
||||
|
||||
switch (info->flash_id & FLASH_VENDMASK)
|
||||
{
|
||||
case (AMD_MANUFACT & FLASH_VENDMASK):
|
||||
rc = amd_flash_protect(info,sector,prot);
|
||||
break;
|
||||
case (FREESCALE_MANUFACT & FLASH_VENDMASK):
|
||||
rc = cfm_flash_protect(info,sector,prot);
|
||||
break;
|
||||
default:
|
||||
rc = ERR_UNKNOWN_FLASH_VENDOR;
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
|
||||
#endif
|
||||
1
board/BuS/EB+MCF-EV123/textbase.mk
Normal file
1
board/BuS/EB+MCF-EV123/textbase.mk
Normal file
@@ -0,0 +1 @@
|
||||
TEXT_BASE = 0xFFE00000
|
||||
141
board/BuS/EB+MCF-EV123/u-boot.lds
Normal file
141
board/BuS/EB+MCF-EV123/u-boot.lds
Normal file
@@ -0,0 +1,141 @@
|
||||
/*
|
||||
* (C) Copyright 2000-2003
|
||||
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
OUTPUT_ARCH(m68k)
|
||||
SEARCH_DIR(/lib); SEARCH_DIR(/usr/lib); SEARCH_DIR(/usr/local/lib);
|
||||
/* Do we need any of these for elf?
|
||||
__DYNAMIC = 0; */
|
||||
SECTIONS
|
||||
{
|
||||
/* Read-only sections, merged into text segment: */
|
||||
. = + SIZEOF_HEADERS;
|
||||
.interp : { *(.interp) }
|
||||
.hash : { *(.hash) }
|
||||
.dynsym : { *(.dynsym) }
|
||||
.dynstr : { *(.dynstr) }
|
||||
.rel.text : { *(.rel.text) }
|
||||
.rela.text : { *(.rela.text) }
|
||||
.rel.data : { *(.rel.data) }
|
||||
.rela.data : { *(.rela.data) }
|
||||
.rel.rodata : { *(.rel.rodata) }
|
||||
.rela.rodata : { *(.rela.rodata) }
|
||||
.rel.got : { *(.rel.got) }
|
||||
.rela.got : { *(.rela.got) }
|
||||
.rel.ctors : { *(.rel.ctors) }
|
||||
.rela.ctors : { *(.rela.ctors) }
|
||||
.rel.dtors : { *(.rel.dtors) }
|
||||
.rela.dtors : { *(.rela.dtors) }
|
||||
.rel.bss : { *(.rel.bss) }
|
||||
.rela.bss : { *(.rela.bss) }
|
||||
.rel.plt : { *(.rel.plt) }
|
||||
.rela.plt : { *(.rela.plt) }
|
||||
.init : { *(.init) }
|
||||
.plt : { *(.plt) }
|
||||
.text :
|
||||
{
|
||||
/* WARNING - the following is hand-optimized to fit within */
|
||||
/* the sector layout of our flash chips! XXX FIXME XXX */
|
||||
|
||||
cpu/mcf52x2/start.o (.text)
|
||||
common/dlmalloc.o (.text)
|
||||
lib_generic/string.o (.text)
|
||||
lib_generic/vsprintf.o (.text)
|
||||
lib_generic/crc32.o (.text)
|
||||
lib_generic/zlib.o (.text)
|
||||
|
||||
/* . = env_offset; */
|
||||
common/environment.o(.text)
|
||||
|
||||
*(.text)
|
||||
*(.fixup)
|
||||
*(.got1)
|
||||
}
|
||||
_etext = .;
|
||||
PROVIDE (etext = .);
|
||||
.rodata :
|
||||
{
|
||||
*(.rodata)
|
||||
*(.rodata1)
|
||||
}
|
||||
.fini : { *(.fini) } =0
|
||||
.ctors : { *(.ctors) }
|
||||
.dtors : { *(.dtors) }
|
||||
|
||||
/* Read-write section, merged into data segment: */
|
||||
. = (. + 0x00FF) & 0xFFFFFF00;
|
||||
_erotext = .;
|
||||
PROVIDE (erotext = .);
|
||||
.reloc :
|
||||
{
|
||||
__got_start = .;
|
||||
*(.got)
|
||||
__got_end = .;
|
||||
_GOT2_TABLE_ = .;
|
||||
*(.got2)
|
||||
_FIXUP_TABLE_ = .;
|
||||
*(.fixup)
|
||||
}
|
||||
__got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >>2;
|
||||
__fixup_entries = (. - _FIXUP_TABLE_)>>2;
|
||||
|
||||
.data :
|
||||
{
|
||||
*(.data)
|
||||
*(.data1)
|
||||
*(.sdata)
|
||||
*(.sdata2)
|
||||
*(.dynamic)
|
||||
CONSTRUCTORS
|
||||
}
|
||||
_edata = .;
|
||||
PROVIDE (edata = .);
|
||||
|
||||
__u_boot_cmd_start = .;
|
||||
.u_boot_cmd : { *(.u_boot_cmd) }
|
||||
__u_boot_cmd_end = .;
|
||||
|
||||
__start___ex_table = .;
|
||||
__ex_table : { *(__ex_table) }
|
||||
__stop___ex_table = .;
|
||||
|
||||
. = ALIGN(256);
|
||||
__init_begin = .;
|
||||
.text.init : { *(.text.init) }
|
||||
.data.init : { *(.data.init) }
|
||||
. = ALIGN(256);
|
||||
__init_end = .;
|
||||
|
||||
__bss_start = .;
|
||||
.bss :
|
||||
{
|
||||
_sbss = .;
|
||||
*(.sbss) *(.scommon)
|
||||
*(.dynbss)
|
||||
*(.bss)
|
||||
*(COMMON)
|
||||
. = ALIGN(4);
|
||||
_ebss = .;
|
||||
}
|
||||
_end = . ;
|
||||
PROVIDE (end = .);
|
||||
}
|
||||
@@ -4,6 +4,9 @@
|
||||
# Copyright (C) 2000, 2001, 2002, 2003
|
||||
# The LEOX team <team@leox.org>, http://www.leox.org
|
||||
#
|
||||
# (C) Copyright 2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# LEOX.org is about the development of free hardware and software resources
|
||||
# for system on chip.
|
||||
#
|
||||
@@ -31,18 +34,22 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
|
||||
$(LIB): .depend $(OBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
/*
|
||||
* (C) Copyright 2002
|
||||
* Hyperion Entertainment, ThomasF@hyperion-entertainment.com
|
||||
* (C) Copyright 2006
|
||||
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
@@ -88,8 +89,6 @@ long initdram (int board_type)
|
||||
|
||||
void after_reloc (ulong dest_addr, gd_t *gd)
|
||||
{
|
||||
/* HJF: DECLARE_GLOBAL_DATA_PTR; */
|
||||
|
||||
board_init_r (gd, dest_addr);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2002
|
||||
# (C) Copyright 2002-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -22,8 +22,12 @@
|
||||
#
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
ifneq ($(OBJTREE),$(SRCTREE))
|
||||
$(shell mkdir -p $(obj)../menu)
|
||||
$(shell mkdir -p $(obj)../bios_emulator)
|
||||
endif
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
COBJS = $(BOARD).o articiaS.o flash.o serial.o smbus.o articiaS_pci.o \
|
||||
via686.o i8259.o ../bios_emulator/x86interface.o \
|
||||
@@ -31,26 +35,29 @@ COBJS = $(BOARD).o articiaS.o flash.o serial.o smbus.o articiaS_pci.o \
|
||||
interrupts.o ps2kbd.o video.o usb_uhci.o enet.o \
|
||||
../menu/cmd_menu.o cmd_boota.o nvram.o
|
||||
|
||||
AOBJS = board_asm_init.o memio.o
|
||||
|
||||
OBJS = $(COBJS) $(AOBJS)
|
||||
SOBJS = board_asm_init.o memio.o
|
||||
|
||||
EMUDIR = ../bios_emulator/scitech/src/x86emu/
|
||||
EMUOBJ = $(EMUDIR)decode.o $(EMUDIR)ops2.o $(EMUDIR)fpu.o $(EMUDIR)prim_ops.o \
|
||||
$(EMUDIR)ops.o $(EMUDIR)sys.o
|
||||
EMUSRC = $(EMUOBJ:.o=.c)
|
||||
EMUSRC = $(EMUOBJ:.o=.c)
|
||||
|
||||
$(LIB): .depend $(OBJS) $(EMUSRC)
|
||||
make libx86emu.a -C ../bios_emulator/scitech/src/x86emu -f makefile.uboot CROSS_COMPILE=$(CROSS_COMPILE)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
EMUOBJ := $(addprefix $(obj),$(EMUOBJ))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS) $(SOBJS) $(EMUSRC)
|
||||
make $(obj)libx86emu.a -C ../bios_emulator/scitech/src/x86emu -f makefile.uboot CROSS_COMPILE=$(CROSS_COMPILE)
|
||||
-rm $(LIB)
|
||||
$(AR) crv $@ $(OBJS) $(EMUOBJ)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS) $(EMUOBJ)
|
||||
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(AOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(AOBJS:.o=.S) $(COBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -29,6 +29,8 @@
|
||||
#include "smbus.h"
|
||||
#include "via686.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#undef DEBUG
|
||||
|
||||
struct dimm_bank {
|
||||
@@ -82,7 +84,6 @@ static inline unsigned short NSto10PS (unsigned char spd_byte)
|
||||
|
||||
long detect_sdram (uint8 * rom, int dimmNum, struct dimm_bank *banks)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
int dimm_address = (dimmNum == 0) ? SM_DIMM0_ADDR : SM_DIMM1_ADDR;
|
||||
uint32 busclock = gd->bus_clk;
|
||||
uint32 memclock = busclock;
|
||||
@@ -394,8 +395,6 @@ uint32 burst_to_len (uint32 support)
|
||||
|
||||
long articiaS_ram_init (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
register uint32 i;
|
||||
register uint32 value1;
|
||||
register uint32 value2;
|
||||
|
||||
@@ -26,6 +26,8 @@
|
||||
#include "memio.h"
|
||||
#include "articiaS.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#undef ARTICIA_PCI_DEBUG
|
||||
|
||||
#ifdef ARTICIA_PCI_DEBUG
|
||||
@@ -493,8 +495,6 @@ pci_dev_t video_dev;
|
||||
|
||||
int articiaS_init_vga (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
extern void shutdown_bios(void);
|
||||
pci_dev_t dev = ~0;
|
||||
int busnr = 0;
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
#include "../disk/part_amiga.h"
|
||||
#include <asm/cache.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#undef BOOTA_DEBUG
|
||||
|
||||
@@ -108,8 +109,6 @@ int do_boota (cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])
|
||||
|
||||
s = getenv ("autostart");
|
||||
if (s && strcmp (s, "yes") == 0) {
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
void (*boot) (bd_t *, char *, block_dev_desc_t *);
|
||||
char *args;
|
||||
|
||||
|
||||
@@ -4,6 +4,8 @@
|
||||
#include "memio.h"
|
||||
#include "articiaS.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#ifndef CFG_NS16550
|
||||
static uint32 ComPort1;
|
||||
|
||||
@@ -150,8 +152,6 @@ const NS16550_t Com1 = (NS16550_t) CFG_NS16550_COM2;
|
||||
|
||||
int serial_init (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
uint32 clock_divisor = 115200 / gd->baudrate;
|
||||
|
||||
NS16550_init (Com0, clock_divisor);
|
||||
@@ -239,8 +239,6 @@ void serial_puts (const char *string)
|
||||
|
||||
void serial_setbrg (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
uint32 clock_divisor = 115200 / gd->baudrate;
|
||||
|
||||
NS16550_init (Com0, clock_divisor);
|
||||
|
||||
@@ -28,6 +28,8 @@
|
||||
#include "via686.h"
|
||||
#include "i8259.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#undef VIA_DEBUG
|
||||
|
||||
#ifdef VIA_DEBUG
|
||||
@@ -226,33 +228,31 @@ __asm (" .globl via_calibrate_time_base \n"
|
||||
|
||||
extern unsigned long via_calibrate_time_base(void);
|
||||
|
||||
void via_calibrate_bus_freq(void)
|
||||
void via_calibrate_bus_freq (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
unsigned long tb;
|
||||
|
||||
unsigned long tb;
|
||||
/* This is 20 microseconds */
|
||||
#define CALIBRATE_TIME 28636
|
||||
|
||||
/* This is 20 microseconds */
|
||||
#define CALIBRATE_TIME 28636
|
||||
/* Enable the timer (and disable speaker) */
|
||||
unsigned char c;
|
||||
|
||||
c = in_byte (0x61);
|
||||
out_byte (0x61, ((c & ~0x02) | 0x01));
|
||||
|
||||
/* Enable the timer (and disable speaker) */
|
||||
unsigned char c;
|
||||
c = in_byte(0x61);
|
||||
out_byte(0x61, ((c & ~0x02) | 0x01));
|
||||
/* Set timer 2 to low/high writing */
|
||||
out_byte (0x43, 0xb0);
|
||||
out_byte (0x42, CALIBRATE_TIME & 0xff);
|
||||
out_byte (0x42, CALIBRATE_TIME >> 8);
|
||||
|
||||
/* Set timer 2 to low/high writing */
|
||||
out_byte(0x43, 0xb0);
|
||||
out_byte(0x42, CALIBRATE_TIME & 0xff);
|
||||
out_byte(0x42, CALIBRATE_TIME >>8);
|
||||
/* Read the time base */
|
||||
tb = via_calibrate_time_base ();
|
||||
|
||||
/* Read the time base */
|
||||
tb = via_calibrate_time_base();
|
||||
|
||||
if (tb >= 700000)
|
||||
gd->bus_clk = 133333333;
|
||||
else
|
||||
gd->bus_clk = 100000000;
|
||||
if (tb >= 700000)
|
||||
gd->bus_clk = 133333333;
|
||||
else
|
||||
gd->bus_clk = 100000000;
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -26,6 +26,8 @@
|
||||
#include "memio.h"
|
||||
#include <part.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
unsigned char *cursor_position;
|
||||
unsigned int cursor_row;
|
||||
unsigned int cursor_col;
|
||||
@@ -480,7 +482,6 @@ extern char version_string[];
|
||||
void video_banner(void)
|
||||
{
|
||||
block_dev_desc_t *ide;
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
int i;
|
||||
char *s;
|
||||
int maxdev;
|
||||
|
||||
@@ -147,14 +147,14 @@ void _EVT_pumpMessages(void)
|
||||
if (EVT.oldMove != -1) {
|
||||
EVT.evtq[EVT.oldMove].where_x = evt.where_x;/* Modify existing one */
|
||||
EVT.evtq[EVT.oldMove].where_y = evt.where_y;
|
||||
/* EVT.evtq[EVT.oldMove].relative_x += mickeyX; // TODO! */
|
||||
/* EVT.evtq[EVT.oldMove].relative_y += mickeyY; // TODO! */
|
||||
/* EVT.evtq[EVT.oldMove].relative_x += mickeyX; / / TODO! */
|
||||
/* EVT.evtq[EVT.oldMove].relative_y += mickeyY; / / TODO! */
|
||||
evt.what = 0;
|
||||
}
|
||||
else {
|
||||
EVT.oldMove = EVT.freeHead; /* Save id of this move event */
|
||||
/* evt.relative_x = mickeyX; // TODO! */
|
||||
/* evt.relative_y = mickeyY; // TODO! */
|
||||
/* evt.relative_x = mickeyX; / / TODO! */
|
||||
/* evt.relative_y = mickeyY; / / TODO! */
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@@ -45,13 +45,13 @@
|
||||
|
||||
#include "ns16550.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#ifdef CONFIG_MPSC
|
||||
|
||||
|
||||
int serial_init (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#if (defined CFG_INIT_CHAN1) || (defined CFG_INIT_CHAN2)
|
||||
int clock_divisor = 230400 / gd->baudrate;
|
||||
#endif
|
||||
@@ -88,8 +88,6 @@ int serial_tstc (void)
|
||||
|
||||
void serial_setbrg (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
galbrg_set_baudrate (CONFIG_MPSC_PORT, gd->baudrate);
|
||||
}
|
||||
|
||||
@@ -97,8 +95,6 @@ void serial_setbrg (void)
|
||||
|
||||
int serial_init (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
int clock_divisor = 230400 / gd->baudrate;
|
||||
|
||||
#ifdef CFG_INIT_CHAN1
|
||||
@@ -130,8 +126,6 @@ int serial_tstc (void)
|
||||
|
||||
void serial_setbrg (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
int clock_divisor = 230400 / gd->baudrate;
|
||||
|
||||
#ifdef CFG_INIT_CHAN1
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
#
|
||||
# (C) Copyright 2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# (C) Copyright 2001
|
||||
# Josh Huber <huber@mclx.com>, Mission Critical Linux, Inc.
|
||||
#
|
||||
@@ -22,23 +25,30 @@
|
||||
#
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
ifneq ($(OBJTREE),$(SRCTREE))
|
||||
$(shell mkdir -p $(obj)../common)
|
||||
endif
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
SOBJS = ../common/misc.o
|
||||
|
||||
OBJS = $(BOARD).o ../common/flash.o ../common/serial.o ../common/memory.o pci.o \
|
||||
COBJS = $(BOARD).o ../common/flash.o ../common/serial.o ../common/memory.o pci.o \
|
||||
mv_eth.o ../common/ns16550.o mpsc.o ../common/i2c.o \
|
||||
sdram_init.o ../common/intel_flash.o
|
||||
|
||||
$(LIB): .depend $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS) $(SOBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS) $(SOBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS)
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -42,6 +42,8 @@
|
||||
|
||||
#include "../include/memory.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
/* Define this if you wish to use the MPSC as a register based UART.
|
||||
* This will force the serial port to not use the SDMA engine at all.
|
||||
*/
|
||||
@@ -114,9 +116,7 @@ static void mpsc_debug_init (void)
|
||||
|
||||
/* Clear the CFR (CHR4) */
|
||||
/* Write random 'Z' bit (bit 29) of CHR4 to enable debug uart *UNDOCUMENTED FEATURE* */
|
||||
temp = GTREGREAD (GALMPSC_CHANNELREG_4 + (CHANNEL * GALMPSC_indent: Standard input:229: Warning:old style assignment ambiguity in "=&". Assuming "= &"
|
||||
|
||||
REG_GAP));
|
||||
temp = GTREGREAD (GALMPSC_CHANNELREG_4 + (CHANNEL * GALMPSC_REG_GAP));
|
||||
temp &= 0xffffff00;
|
||||
temp |= BIT29;
|
||||
GT_REG_WRITE (GALMPSC_CHANNELREG_4 + (CHANNEL * GALMPSC_REG_GAP),
|
||||
@@ -158,7 +158,6 @@ char mpsc_getchar_debug (void)
|
||||
* global variables [josh] */
|
||||
int mpsc_putchar_early (char ch)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
int mpsc = CHANNEL;
|
||||
int temp =
|
||||
GTREGREAD (GALMPSC_CHANNELREG_2 + (mpsc * GALMPSC_REG_GAP));
|
||||
@@ -511,7 +510,6 @@ void mpsc_init2 (void)
|
||||
|
||||
int galbrg_set_baudrate (int channel, int rate)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
int clock;
|
||||
|
||||
galbrg_disable (channel); /*ok */
|
||||
|
||||
@@ -732,6 +732,7 @@ int mv64360_eth_xmit (struct eth_device *dev, volatile void *dataPtr,
|
||||
pkt_info.cmd_sts = ETH_TX_FIRST_DESC | ETH_TX_LAST_DESC; /* DMA owned, first last */
|
||||
pkt_info.byte_cnt = dataSize;
|
||||
pkt_info.buf_ptr = (unsigned int) dataPtr;
|
||||
pkt_info.return_info = 0;
|
||||
|
||||
status = eth_port_send (ethernet_private, ETH_Q0, &pkt_info);
|
||||
if ((status == ETH_ERROR) || (status == ETH_QUEUE_FULL)) {
|
||||
|
||||
@@ -42,6 +42,8 @@
|
||||
#include "64360.h"
|
||||
#include "mv_regs.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#undef DEBUG
|
||||
#define MAP_PCI
|
||||
|
||||
@@ -246,8 +248,6 @@ static inline unsigned short NSto10PS (unsigned char spd_byte)
|
||||
/* static int check_dimm(uchar slot, AUX_MEM_DIMM_INFO *info) */
|
||||
static int check_dimm (uchar slot, AUX_MEM_DIMM_INFO * dimmInfo)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
unsigned long spd_checksum;
|
||||
|
||||
#ifdef ZUMA_NTL
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
#
|
||||
# (C) Copyright 2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# (C) Copyright 2001
|
||||
# Josh Huber <huber@mclx.com>, Mission Critical Linux, Inc.
|
||||
#
|
||||
@@ -22,23 +25,30 @@
|
||||
#
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
ifneq ($(OBJTREE),$(SRCTREE))
|
||||
$(shell mkdir -p $(obj)../common)
|
||||
endif
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
SOBJS = ../common/misc.o
|
||||
|
||||
OBJS = $(BOARD).o ../common/flash.o ../common/serial.o ../common/memory.o pci.o \
|
||||
COBJS = $(BOARD).o ../common/flash.o ../common/serial.o ../common/memory.o pci.o \
|
||||
mv_eth.o ../common/ns16550.o mpsc.o ../common/i2c.o \
|
||||
sdram_init.o ../common/intel_flash.o
|
||||
|
||||
$(LIB): .depend $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS) $(SOBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS) $(SOBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS)
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -42,6 +42,8 @@
|
||||
|
||||
#include "../include/memory.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
/* Define this if you wish to use the MPSC as a register based UART.
|
||||
* This will force the serial port to not use the SDMA engine at all.
|
||||
*/
|
||||
@@ -114,9 +116,7 @@ static void mpsc_debug_init (void)
|
||||
|
||||
/* Clear the CFR (CHR4) */
|
||||
/* Write random 'Z' bit (bit 29) of CHR4 to enable debug uart *UNDOCUMENTED FEATURE* */
|
||||
temp = GTREGREAD (GALMPSC_CHANNELREG_4 + (CHANNEL * GALMPSC_indent: Standard input:229: Warning:old style assignment ambiguity in "=&". Assuming "= &"
|
||||
|
||||
REG_GAP));
|
||||
temp = GTREGREAD (GALMPSC_CHANNELREG_4 + (CHANNEL * GALMPSC_REG_GAP));
|
||||
temp &= 0xffffff00;
|
||||
temp |= BIT29;
|
||||
GT_REG_WRITE (GALMPSC_CHANNELREG_4 + (CHANNEL * GALMPSC_REG_GAP),
|
||||
@@ -158,7 +158,6 @@ char mpsc_getchar_debug (void)
|
||||
* global variables [josh] */
|
||||
int mpsc_putchar_early (char ch)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
int mpsc = CHANNEL;
|
||||
int temp =
|
||||
GTREGREAD (GALMPSC_CHANNELREG_2 + (mpsc * GALMPSC_REG_GAP));
|
||||
@@ -511,7 +510,6 @@ void mpsc_init2 (void)
|
||||
|
||||
int galbrg_set_baudrate (int channel, int rate)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
int clock;
|
||||
|
||||
galbrg_disable (channel); /*ok */
|
||||
|
||||
@@ -731,6 +731,7 @@ int mv64460_eth_xmit (struct eth_device *dev, volatile void *dataPtr,
|
||||
pkt_info.cmd_sts = ETH_TX_FIRST_DESC | ETH_TX_LAST_DESC; /* DMA owned, first last */
|
||||
pkt_info.byte_cnt = dataSize;
|
||||
pkt_info.buf_ptr = (unsigned int) dataPtr;
|
||||
pkt_info.return_info = 0;
|
||||
|
||||
status = eth_port_send (ethernet_private, ETH_Q0, &pkt_info);
|
||||
if ((status == ETH_ERROR) || (status == ETH_QUEUE_FULL)) {
|
||||
|
||||
@@ -42,6 +42,8 @@
|
||||
#include "64460.h"
|
||||
#include "mv_regs.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#undef DEBUG
|
||||
#define MAP_PCI
|
||||
|
||||
@@ -246,8 +248,6 @@ static inline unsigned short NSto10PS (unsigned char spd_byte)
|
||||
/* static int check_dimm(uchar slot, AUX_MEM_DIMM_INFO *info) */
|
||||
static int check_dimm (uchar slot, AUX_MEM_DIMM_INFO * dimmInfo)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
unsigned long spd_checksum;
|
||||
|
||||
#ifdef ZUMA_NTL
|
||||
|
||||
@@ -91,7 +91,10 @@ extern unsigned int INTERNAL_REG_BASE_ADDR;
|
||||
#define _1G 0x40000000
|
||||
#define _2G 0x80000000
|
||||
|
||||
#ifndef BOOL_WAS_DEFINED
|
||||
#define BOOL_WAS_DEFINED
|
||||
typedef enum _bool{false,true} bool;
|
||||
#endif
|
||||
|
||||
/* Little to Big endian conversion macros */
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2000
|
||||
# (C) Copyright 2000-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,18 +23,22 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o eccx.o
|
||||
COBJS = $(BOARD).o flash.o eccx.o
|
||||
|
||||
$(LIB): .depend $(OBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2000
|
||||
# (C) Copyright 2000-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,18 +23,22 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
|
||||
$(LIB): .depend $(OBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2000-2004
|
||||
# (C) Copyright 2000-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,18 +23,22 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
|
||||
$(LIB): .depend $(OBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2000-2002
|
||||
# (C) Copyright 2000-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,18 +23,22 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
|
||||
$(LIB): .depend $(OBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2001
|
||||
# (C) Copyright 2001-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,18 +23,22 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
|
||||
$(LIB): .depend $(OBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
#
|
||||
# (C) Copyright 2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# Copyright (C) 2004 Arabella Software Ltd.
|
||||
# Yuli Barcohen <yuli@arabellasw.com>
|
||||
#
|
||||
@@ -23,12 +26,16 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS := $(BOARD).o
|
||||
COBJS := $(BOARD).o
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -38,9 +45,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CPPFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
-include .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2004 Arabella Software Ltd.
|
||||
* Copyright (C) 2004-2005 Arabella Software Ltd.
|
||||
* Yuli Barcohen <yuli@arabellasw.com>
|
||||
*
|
||||
* Support for Analogue&Micro Adder boards family.
|
||||
@@ -28,7 +28,8 @@
|
||||
#include <mpc8xx.h>
|
||||
|
||||
/*
|
||||
* SDRAM is single Samsung K4S643232F-T70 chip.
|
||||
* SDRAM is single Samsung K4S643232F-T70 chip (8MB)
|
||||
* or single Micron MT48LC4M32B2TG-7 chip (16MB).
|
||||
* Minimal CPU frequency is 40MHz.
|
||||
*/
|
||||
static uint sdram_table[] = {
|
||||
@@ -53,7 +54,7 @@ static uint sdram_table[] = {
|
||||
0xfffffc04, 0xfffffc04, 0xfffffc04, 0xfffffc04,
|
||||
|
||||
/* Refresh (offset 0x30 in UPM RAM) */
|
||||
0x1ff5fca4, 0xfffffc04, 0xfffffc04, 0xfffffc04,
|
||||
0x1ff5fc84, 0xfffffc04, 0xfffffc04, 0xfffffc04,
|
||||
0xfffffc84, 0xfffffc07, 0xfffffc04, 0xfffffc04,
|
||||
0xfffffc04, 0xfffffc04, 0xfffffc04, 0xfffffc04,
|
||||
|
||||
@@ -63,7 +64,7 @@ static uint sdram_table[] = {
|
||||
|
||||
long int initdram (int board_type)
|
||||
{
|
||||
long int msize = CFG_SDRAM_SIZE;
|
||||
long int msize;
|
||||
volatile immap_t *immap = (volatile immap_t *)CFG_IMMR;
|
||||
volatile memctl8xx_t *memctl = &immap->im_memctl;
|
||||
|
||||
@@ -72,11 +73,11 @@ long int initdram (int board_type)
|
||||
/* Configure SDRAM refresh */
|
||||
memctl->memc_mptpr = MPTPR_PTP_DIV32; /* BRGCLK/32 */
|
||||
|
||||
memctl->memc_mamr = (94 << 24) | CFG_MAMR;
|
||||
memctl->memc_mar = 0x0;
|
||||
memctl->memc_mamr = (94 << 24) | CFG_MAMR; /* No refresh */
|
||||
udelay(200);
|
||||
|
||||
/* Run precharge from location 0x15 */
|
||||
memctl->memc_mar = 0x0;
|
||||
memctl->memc_mcr = 0x80002115;
|
||||
udelay(200);
|
||||
|
||||
@@ -84,13 +85,18 @@ long int initdram (int board_type)
|
||||
memctl->memc_mcr = 0x80002830;
|
||||
udelay(200);
|
||||
|
||||
memctl->memc_mar = 0x88;
|
||||
udelay(200);
|
||||
|
||||
/* Run MRS pattern from location 0x16 */
|
||||
memctl->memc_mar = 0x88;
|
||||
memctl->memc_mcr = 0x80002116;
|
||||
udelay(200);
|
||||
|
||||
memctl->memc_mamr |= MAMR_PTAE; /* Enable refresh */
|
||||
memctl->memc_or1 = ~(CFG_SDRAM_MAX_SIZE - 1) | OR_CSNT_SAM;
|
||||
memctl->memc_br1 = CFG_SDRAM_BASE | BR_PS_32 | BR_MS_UPMA | BR_V;
|
||||
|
||||
msize = get_ram_size(CFG_SDRAM_BASE, CFG_SDRAM_MAX_SIZE);
|
||||
memctl->memc_or1 |= ~(msize - 1);
|
||||
|
||||
return msize;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
|
||||
#
|
||||
# (C) Copyright 2000
|
||||
# (C) Copyright 2000-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -24,13 +23,17 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS := adsvix.o pcmcia.o
|
||||
COBJS := adsvix.o pcmcia.o
|
||||
SOBJS := lowlevel_init.o pxavoltage.o
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS) $(SOBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS) $(SOBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -40,9 +43,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CPPFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
-include .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -30,6 +30,8 @@
|
||||
|
||||
#include <common.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
/*
|
||||
@@ -38,8 +40,6 @@
|
||||
|
||||
int board_init (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
/* memory and cpu-speed are setup before relocation */
|
||||
/* so we do _nothing_ here */
|
||||
|
||||
@@ -62,8 +62,6 @@ int board_late_init(void)
|
||||
|
||||
int dram_init (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
gd->bd->bi_dram[0].start = PHYS_SDRAM_1;
|
||||
gd->bd->bi_dram[0].size = PHYS_SDRAM_1_SIZE;
|
||||
gd->bd->bi_dram[1].start = PHYS_SDRAM_2;
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
# (C) Copyright 2003-2005
|
||||
#
|
||||
# (C) Copyright 2003-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -22,12 +23,16 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS := $(BOARD).o flash.o
|
||||
COBJS := $(BOARD).o flash.o
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -37,9 +42,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CPPFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
-include .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
190
board/altera/common/AMDLV065D.c
Normal file
190
board/altera/common/AMDLV065D.c
Normal file
@@ -0,0 +1,190 @@
|
||||
/*
|
||||
* (C) Copyright 2000-2004
|
||||
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
|
||||
#include <common.h>
|
||||
#if defined(CONFIG_NIOS)
|
||||
#include <nios.h>
|
||||
#else
|
||||
#include <asm/io.h>
|
||||
#endif
|
||||
|
||||
#define SECTSZ (64 * 1024)
|
||||
flash_info_t flash_info[CFG_MAX_FLASH_BANKS];
|
||||
|
||||
/*----------------------------------------------------------------------*/
|
||||
unsigned long flash_init (void)
|
||||
{
|
||||
int i;
|
||||
unsigned long addr;
|
||||
flash_info_t *fli = &flash_info[0];
|
||||
|
||||
fli->size = CFG_FLASH_SIZE;
|
||||
fli->sector_count = CFG_MAX_FLASH_SECT;
|
||||
fli->flash_id = FLASH_MAN_AMD + FLASH_AMDLV065D;
|
||||
|
||||
addr = CFG_FLASH_BASE;
|
||||
for (i = 0; i < fli->sector_count; ++i) {
|
||||
fli->start[i] = addr;
|
||||
addr += SECTSZ;
|
||||
fli->protect[i] = 1;
|
||||
}
|
||||
|
||||
return (CFG_FLASH_SIZE);
|
||||
}
|
||||
/*--------------------------------------------------------------------*/
|
||||
void flash_print_info (flash_info_t * info)
|
||||
{
|
||||
int i, k;
|
||||
int erased;
|
||||
unsigned long *addr;
|
||||
|
||||
printf (" Size: %ld KB in %d Sectors\n",
|
||||
info->size >> 10, info->sector_count);
|
||||
printf (" Sector Start Addresses:");
|
||||
for (i = 0; i < info->sector_count; ++i) {
|
||||
|
||||
/* Check if whole sector is erased */
|
||||
erased = 1;
|
||||
addr = (unsigned long *) info->start[i];
|
||||
for (k = 0; k < SECTSZ/sizeof(unsigned long); k++) {
|
||||
if ( readl(addr++) != (unsigned long)-1) {
|
||||
erased = 0;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* Print the info */
|
||||
if ((i % 5) == 0)
|
||||
printf ("\n ");
|
||||
printf (" %08lX%s%s",
|
||||
info->start[i],
|
||||
erased ? " E" : " ",
|
||||
info->protect[i] ? "RO " : " ");
|
||||
}
|
||||
printf ("\n");
|
||||
}
|
||||
|
||||
/*-------------------------------------------------------------------*/
|
||||
|
||||
|
||||
int flash_erase (flash_info_t * info, int s_first, int s_last)
|
||||
{
|
||||
unsigned char *addr = (unsigned char *) info->start[0];
|
||||
unsigned char *addr2;
|
||||
int prot, sect;
|
||||
ulong start;
|
||||
|
||||
/* Some sanity checking */
|
||||
if ((s_first < 0) || (s_first > s_last)) {
|
||||
printf ("- no sectors to erase\n");
|
||||
return 1;
|
||||
}
|
||||
|
||||
prot = 0;
|
||||
for (sect = s_first; sect <= s_last; ++sect) {
|
||||
if (info->protect[sect]) {
|
||||
prot++;
|
||||
}
|
||||
}
|
||||
if (prot) {
|
||||
printf ("- Warning: %d protected sectors will not be erased!\n",
|
||||
prot);
|
||||
} else {
|
||||
printf ("\n");
|
||||
}
|
||||
|
||||
/* It's ok to erase multiple sectors provided we don't delay more
|
||||
* than 50 usec between cmds ... at which point the erase time-out
|
||||
* occurs. So don't go and put printf() calls in the loop ... it
|
||||
* won't be very helpful ;-)
|
||||
*/
|
||||
for (sect = s_first; sect <= s_last; sect++) {
|
||||
if (info->protect[sect] == 0) { /* not protected */
|
||||
addr2 = (unsigned char *) info->start[sect];
|
||||
writeb (addr, 0xaa);
|
||||
writeb (addr, 0x55);
|
||||
writeb (addr, 0x80);
|
||||
writeb (addr, 0xaa);
|
||||
writeb (addr, 0x55);
|
||||
writeb (addr2, 0x30);
|
||||
/* Now just wait for 0xff & provide some user
|
||||
* feedback while we wait.
|
||||
*/
|
||||
start = get_timer (0);
|
||||
while ( readb (addr2) != 0xff) {
|
||||
udelay (1000 * 1000);
|
||||
putc ('.');
|
||||
if (get_timer (start) > CFG_FLASH_ERASE_TOUT) {
|
||||
printf ("timeout\n");
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
printf ("\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*-----------------------------------------------------------------------
|
||||
* Copy memory to flash, returns:
|
||||
* 0 - OK
|
||||
* 1 - write timeout
|
||||
* 2 - Flash not erased
|
||||
*/
|
||||
|
||||
int write_buff (flash_info_t * info, uchar * src, ulong addr, ulong cnt)
|
||||
{
|
||||
|
||||
vu_char *cmd = (vu_char *) info->start[0];
|
||||
vu_char *dst = (vu_char *) addr;
|
||||
unsigned char b;
|
||||
ulong start;
|
||||
|
||||
while (cnt) {
|
||||
/* Check for sufficient erase */
|
||||
b = *src;
|
||||
if ((readb (dst) & b) != b) {
|
||||
printf ("%02x : %02x\n", readb (dst), b);
|
||||
return (2);
|
||||
}
|
||||
|
||||
writeb (cmd, 0xaa);
|
||||
writeb (cmd, 0x55);
|
||||
writeb (cmd, 0xa0);
|
||||
writeb (dst, b);
|
||||
|
||||
/* Verify write */
|
||||
start = get_timer (0);
|
||||
while (readb (dst) != b) {
|
||||
if (get_timer (start) > CFG_FLASH_WRITE_TOUT) {
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
dst++;
|
||||
src++;
|
||||
cnt--;
|
||||
}
|
||||
|
||||
return (0);
|
||||
}
|
||||
62
board/altera/common/epled.c
Normal file
62
board/altera/common/epled.c
Normal file
@@ -0,0 +1,62 @@
|
||||
/*
|
||||
* (C) Copyright 2004, Psyent Corporation <www.psyent.com>
|
||||
* Scott McNutt <smcnutt@psyent.com>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <asm/io.h>
|
||||
#include <nios2-io.h>
|
||||
#include <status_led.h>
|
||||
|
||||
/* The LED port is configured as output only, so we
|
||||
* must track the state manually.
|
||||
*/
|
||||
static led_id_t val = 0;
|
||||
|
||||
void __led_init (led_id_t mask, int state)
|
||||
{
|
||||
nios_pio_t *pio = (nios_pio_t *)CFG_LEDPIO_ADDR;
|
||||
|
||||
if (state == STATUS_LED_ON)
|
||||
val &= ~mask;
|
||||
else
|
||||
val |= mask;
|
||||
writel (&pio->data, val);
|
||||
}
|
||||
|
||||
void __led_set (led_id_t mask, int state)
|
||||
{
|
||||
nios_pio_t *pio = (nios_pio_t *)CFG_LEDPIO_ADDR;
|
||||
|
||||
if (state == STATUS_LED_ON)
|
||||
val &= ~mask;
|
||||
else
|
||||
val |= mask;
|
||||
writel (&pio->data, val);
|
||||
}
|
||||
|
||||
void __led_toggle (led_id_t mask)
|
||||
{
|
||||
nios_pio_t *pio = (nios_pio_t *)CFG_LEDPIO_ADDR;
|
||||
|
||||
val ^= mask;
|
||||
writel (&pio->data, val);
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2001-2004
|
||||
# (C) Copyright 2001-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,14 +23,17 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
|
||||
OBJS := $(BOARD).o flash.o misc.o
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
COBJS := $(BOARD).o flash.o misc.o
|
||||
SOBJS = vectors.o
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $^
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS) $(SOBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -40,9 +43,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CPPFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
-include .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2001-2004
|
||||
# (C) Copyright 2001-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,14 +23,17 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
|
||||
OBJS := $(BOARD).o flash.o misc.o
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
COBJS := $(BOARD).o flash.o misc.o
|
||||
SOBJS = vectors.o
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $^
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS) $(SOBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -40,9 +43,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CPPFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
-include .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
55
board/altera/ep1c20/Makefile
Normal file
55
board/altera/ep1c20/Makefile
Normal file
@@ -0,0 +1,55 @@
|
||||
#
|
||||
# (C) Copyright 2001-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
ifneq ($(OBJTREE),$(SRCTREE))
|
||||
$(shell mkdir -p $(obj)../common)
|
||||
endif
|
||||
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
COMOBJS := ../common/AMDLV065D.o ../common/epled.o
|
||||
|
||||
COBJS := $(BOARD).o $(COMOBJS)
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
|
||||
distclean: clean
|
||||
rm -f $(LIB) core *.bak .depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
31
board/altera/ep1c20/config.mk
Normal file
31
board/altera/ep1c20/config.mk
Normal file
@@ -0,0 +1,31 @@
|
||||
#
|
||||
# (C) Copyright 2005, Psyent Corporation <www.psyent.com>
|
||||
# Scott McNutt <smcnutt@psyent.com>
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
TEXT_BASE = 0x01fc0000
|
||||
|
||||
PLATFORM_CPPFLAGS += -mno-hw-div -mno-hw-mul
|
||||
PLATFORM_CPPFLAGS += -I$(TOPDIR)/board/$(VENDOR)/include
|
||||
|
||||
ifeq ($(debug),1)
|
||||
PLATFORM_CPPFLAGS += -DDEBUG
|
||||
endif
|
||||
40
board/altera/ep1c20/ep1c20.c
Normal file
40
board/altera/ep1c20/ep1c20.c
Normal file
@@ -0,0 +1,40 @@
|
||||
/*
|
||||
* (C) Copyright 2005, Psyent Corporation <www.psyent.com>
|
||||
* Scott McNutt <smcnutt@psyent.com>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
|
||||
int board_early_init_f (void)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
int checkboard (void)
|
||||
{
|
||||
puts ("BOARD : Altera EP-1C20\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
long int initdram (int board_type)
|
||||
{
|
||||
return (0);
|
||||
}
|
||||
136
board/altera/ep1c20/u-boot.lds
Normal file
136
board/altera/ep1c20/u-boot.lds
Normal file
@@ -0,0 +1,136 @@
|
||||
/*
|
||||
* (C) Copyright 2004, Psyent Corporation <www.psyent.com>
|
||||
* Scott McNutt <smcnutt@psyent.com>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
|
||||
OUTPUT_FORMAT("elf32-littlenios2")
|
||||
OUTPUT_ARCH(nios2)
|
||||
ENTRY(_start)
|
||||
|
||||
SECTIONS
|
||||
{
|
||||
.text :
|
||||
{
|
||||
cpu/nios2/start.o (.text)
|
||||
*(.text)
|
||||
*(.text.*)
|
||||
*(.gnu.linkonce.t*)
|
||||
*(.rodata)
|
||||
*(.rodata.*)
|
||||
*(.gnu.linkonce.r*)
|
||||
}
|
||||
. = ALIGN (4);
|
||||
_etext = .;
|
||||
PROVIDE (etext = .);
|
||||
|
||||
/* CMD TABLE - sandwich this in between text and data so
|
||||
* the initialization code relocates the command table as
|
||||
* well -- admittedly, this is just pure laziness ;-)
|
||||
*/
|
||||
__u_boot_cmd_start = .;
|
||||
.u_boot_cmd :
|
||||
{
|
||||
*(.u_boot_cmd)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
__u_boot_cmd_end = .;
|
||||
|
||||
/* INIT DATA sections - "Small" data (see the gcc -G option)
|
||||
* is always gp-relative. Here we make all init data sections
|
||||
* adjacent to simplify the startup code -- and provide
|
||||
* the global pointer for gp-relative access.
|
||||
*/
|
||||
_data = .;
|
||||
.data :
|
||||
{
|
||||
*(.data)
|
||||
*(.data.*)
|
||||
*(.gnu.linkonce.d*)
|
||||
}
|
||||
|
||||
. = ALIGN(16);
|
||||
_gp = .; /* Global pointer addr */
|
||||
PROVIDE (gp = .);
|
||||
|
||||
.sdata :
|
||||
{
|
||||
*(.sdata)
|
||||
*(.sdata.*)
|
||||
*(.gnu.linkonce.s.*)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
|
||||
_edata = .;
|
||||
PROVIDE (edata = .);
|
||||
|
||||
/* UNINIT DATA - Small uninitialized data is first so it's
|
||||
* adjacent to sdata and can be referenced via gp. The normal
|
||||
* bss follows. We keep it adjacent to simplify init code.
|
||||
*/
|
||||
__bss_start = .;
|
||||
.sbss :
|
||||
{
|
||||
*(.sbss)
|
||||
*(.sbss.*)
|
||||
*(.gnu.linkonce.sb.*)
|
||||
*(.scommon)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
.bss :
|
||||
{
|
||||
*(.bss)
|
||||
*(.bss.*)
|
||||
*(.dynbss)
|
||||
*(COMMON)
|
||||
*(.scommon)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
_end = .;
|
||||
PROVIDE (end = .);
|
||||
|
||||
/* DEBUG -- symbol table, string table, etc. etc.
|
||||
*/
|
||||
.stab 0 : { *(.stab) }
|
||||
.stabstr 0 : { *(.stabstr) }
|
||||
.stab.excl 0 : { *(.stab.excl) }
|
||||
.stab.exclstr 0 : { *(.stab.exclstr) }
|
||||
.stab.index 0 : { *(.stab.index) }
|
||||
.stab.indexstr 0 : { *(.stab.indexstr) }
|
||||
.comment 0 : { *(.comment) }
|
||||
.debug 0 : { *(.debug) }
|
||||
.line 0 : { *(.line) }
|
||||
.debug_srcinfo 0 : { *(.debug_srcinfo) }
|
||||
.debug_sfnames 0 : { *(.debug_sfnames) }
|
||||
.debug_aranges 0 : { *(.debug_aranges) }
|
||||
.debug_pubnames 0 : { *(.debug_pubnames) }
|
||||
.debug_info 0 : { *(.debug_info) }
|
||||
.debug_abbrev 0 : { *(.debug_abbrev) }
|
||||
.debug_line 0 : { *(.debug_line) }
|
||||
.debug_frame 0 : { *(.debug_frame) }
|
||||
.debug_str 0 : { *(.debug_str) }
|
||||
.debug_loc 0 : { *(.debug_loc) }
|
||||
.debug_macinfo 0 : { *(.debug_macinfo) }
|
||||
.debug_weaknames 0 : { *(.debug_weaknames) }
|
||||
.debug_funcnames 0 : { *(.debug_funcnames) }
|
||||
.debug_typenames 0 : { *(.debug_typenames) }
|
||||
.debug_varnames 0 : { *(.debug_varnames) }
|
||||
}
|
||||
55
board/altera/ep1s10/Makefile
Normal file
55
board/altera/ep1s10/Makefile
Normal file
@@ -0,0 +1,55 @@
|
||||
#
|
||||
# (C) Copyright 2001-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
ifneq ($(OBJTREE),$(SRCTREE))
|
||||
$(shell mkdir -p $(obj)../common)
|
||||
endif
|
||||
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
COMOBJS := ../common/AMDLV065D.o ../common/epled.o
|
||||
|
||||
COBJS := $(BOARD).o $(COMOBJS)
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
|
||||
distclean: clean
|
||||
rm -f $(LIB) core *.bak .depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
31
board/altera/ep1s10/config.mk
Normal file
31
board/altera/ep1s10/config.mk
Normal file
@@ -0,0 +1,31 @@
|
||||
#
|
||||
# (C) Copyright 2005, Psyent Corporation <www.psyent.com>
|
||||
# Scott McNutt <smcnutt@psyent.com>
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
TEXT_BASE = 0x01fc0000
|
||||
|
||||
PLATFORM_CPPFLAGS += -mno-hw-div -mno-hw-mul
|
||||
PLATFORM_CPPFLAGS += -I$(TOPDIR)/board/$(VENDOR)/include
|
||||
|
||||
ifeq ($(debug),1)
|
||||
PLATFORM_CPPFLAGS += -DDEBUG
|
||||
endif
|
||||
40
board/altera/ep1s10/ep1s10.c
Normal file
40
board/altera/ep1s10/ep1s10.c
Normal file
@@ -0,0 +1,40 @@
|
||||
/*
|
||||
* (C) Copyright 2005, Psyent Corporation <www.psyent.com>
|
||||
* Scott McNutt <smcnutt@psyent.com>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
|
||||
int board_early_init_f (void)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
int checkboard (void)
|
||||
{
|
||||
puts ("BOARD : Altera EP-1S10\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
long int initdram (int board_type)
|
||||
{
|
||||
return (0);
|
||||
}
|
||||
136
board/altera/ep1s10/u-boot.lds
Normal file
136
board/altera/ep1s10/u-boot.lds
Normal file
@@ -0,0 +1,136 @@
|
||||
/*
|
||||
* (C) Copyright 2004, Psyent Corporation <www.psyent.com>
|
||||
* Scott McNutt <smcnutt@psyent.com>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
|
||||
OUTPUT_FORMAT("elf32-littlenios2")
|
||||
OUTPUT_ARCH(nios2)
|
||||
ENTRY(_start)
|
||||
|
||||
SECTIONS
|
||||
{
|
||||
.text :
|
||||
{
|
||||
cpu/nios2/start.o (.text)
|
||||
*(.text)
|
||||
*(.text.*)
|
||||
*(.gnu.linkonce.t*)
|
||||
*(.rodata)
|
||||
*(.rodata.*)
|
||||
*(.gnu.linkonce.r*)
|
||||
}
|
||||
. = ALIGN (4);
|
||||
_etext = .;
|
||||
PROVIDE (etext = .);
|
||||
|
||||
/* CMD TABLE - sandwich this in between text and data so
|
||||
* the initialization code relocates the command table as
|
||||
* well -- admittedly, this is just pure laziness ;-)
|
||||
*/
|
||||
__u_boot_cmd_start = .;
|
||||
.u_boot_cmd :
|
||||
{
|
||||
*(.u_boot_cmd)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
__u_boot_cmd_end = .;
|
||||
|
||||
/* INIT DATA sections - "Small" data (see the gcc -G option)
|
||||
* is always gp-relative. Here we make all init data sections
|
||||
* adjacent to simplify the startup code -- and provide
|
||||
* the global pointer for gp-relative access.
|
||||
*/
|
||||
_data = .;
|
||||
.data :
|
||||
{
|
||||
*(.data)
|
||||
*(.data.*)
|
||||
*(.gnu.linkonce.d*)
|
||||
}
|
||||
|
||||
. = ALIGN(16);
|
||||
_gp = .; /* Global pointer addr */
|
||||
PROVIDE (gp = .);
|
||||
|
||||
.sdata :
|
||||
{
|
||||
*(.sdata)
|
||||
*(.sdata.*)
|
||||
*(.gnu.linkonce.s.*)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
|
||||
_edata = .;
|
||||
PROVIDE (edata = .);
|
||||
|
||||
/* UNINIT DATA - Small uninitialized data is first so it's
|
||||
* adjacent to sdata and can be referenced via gp. The normal
|
||||
* bss follows. We keep it adjacent to simplify init code.
|
||||
*/
|
||||
__bss_start = .;
|
||||
.sbss :
|
||||
{
|
||||
*(.sbss)
|
||||
*(.sbss.*)
|
||||
*(.gnu.linkonce.sb.*)
|
||||
*(.scommon)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
.bss :
|
||||
{
|
||||
*(.bss)
|
||||
*(.bss.*)
|
||||
*(.dynbss)
|
||||
*(COMMON)
|
||||
*(.scommon)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
_end = .;
|
||||
PROVIDE (end = .);
|
||||
|
||||
/* DEBUG -- symbol table, string table, etc. etc.
|
||||
*/
|
||||
.stab 0 : { *(.stab) }
|
||||
.stabstr 0 : { *(.stabstr) }
|
||||
.stab.excl 0 : { *(.stab.excl) }
|
||||
.stab.exclstr 0 : { *(.stab.exclstr) }
|
||||
.stab.index 0 : { *(.stab.index) }
|
||||
.stab.indexstr 0 : { *(.stab.indexstr) }
|
||||
.comment 0 : { *(.comment) }
|
||||
.debug 0 : { *(.debug) }
|
||||
.line 0 : { *(.line) }
|
||||
.debug_srcinfo 0 : { *(.debug_srcinfo) }
|
||||
.debug_sfnames 0 : { *(.debug_sfnames) }
|
||||
.debug_aranges 0 : { *(.debug_aranges) }
|
||||
.debug_pubnames 0 : { *(.debug_pubnames) }
|
||||
.debug_info 0 : { *(.debug_info) }
|
||||
.debug_abbrev 0 : { *(.debug_abbrev) }
|
||||
.debug_line 0 : { *(.debug_line) }
|
||||
.debug_frame 0 : { *(.debug_frame) }
|
||||
.debug_str 0 : { *(.debug_str) }
|
||||
.debug_loc 0 : { *(.debug_loc) }
|
||||
.debug_macinfo 0 : { *(.debug_macinfo) }
|
||||
.debug_weaknames 0 : { *(.debug_weaknames) }
|
||||
.debug_funcnames 0 : { *(.debug_funcnames) }
|
||||
.debug_typenames 0 : { *(.debug_typenames) }
|
||||
.debug_varnames 0 : { *(.debug_varnames) }
|
||||
}
|
||||
55
board/altera/ep1s40/Makefile
Normal file
55
board/altera/ep1s40/Makefile
Normal file
@@ -0,0 +1,55 @@
|
||||
#
|
||||
# (C) Copyright 2001-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
ifneq ($(OBJTREE),$(SRCTREE))
|
||||
$(shell mkdir -p $(obj)../common)
|
||||
endif
|
||||
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
COMOBJS := ../common/AMDLV065D.o ../common/epled.o
|
||||
|
||||
COBJS := $(BOARD).o $(COMOBJS)
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
|
||||
distclean: clean
|
||||
rm -f $(LIB) core *.bak .depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
31
board/altera/ep1s40/config.mk
Normal file
31
board/altera/ep1s40/config.mk
Normal file
@@ -0,0 +1,31 @@
|
||||
#
|
||||
# (C) Copyright 2005, Psyent Corporation <www.psyent.com>
|
||||
# Scott McNutt <smcnutt@psyent.com>
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
TEXT_BASE = 0x01fc0000
|
||||
|
||||
PLATFORM_CPPFLAGS += -mno-hw-div -mno-hw-mul
|
||||
PLATFORM_CPPFLAGS += -I$(TOPDIR)/board/$(VENDOR)/include
|
||||
|
||||
ifeq ($(debug),1)
|
||||
PLATFORM_CPPFLAGS += -DDEBUG
|
||||
endif
|
||||
35
board/altera/ep1s40/ep1s40.c
Normal file
35
board/altera/ep1s40/ep1s40.c
Normal file
@@ -0,0 +1,35 @@
|
||||
/*
|
||||
* (C) Copyright 2005, Psyent Corporation <www.psyent.com>
|
||||
* Scott McNutt <smcnutt@psyent.com>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
|
||||
int checkboard (void)
|
||||
{
|
||||
puts ("BOARD : Altera EP-1S40\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
long int initdram (int board_type)
|
||||
{
|
||||
return (0);
|
||||
}
|
||||
136
board/altera/ep1s40/u-boot.lds
Normal file
136
board/altera/ep1s40/u-boot.lds
Normal file
@@ -0,0 +1,136 @@
|
||||
/*
|
||||
* (C) Copyright 2004, Psyent Corporation <www.psyent.com>
|
||||
* Scott McNutt <smcnutt@psyent.com>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
|
||||
OUTPUT_FORMAT("elf32-littlenios2")
|
||||
OUTPUT_ARCH(nios2)
|
||||
ENTRY(_start)
|
||||
|
||||
SECTIONS
|
||||
{
|
||||
.text :
|
||||
{
|
||||
cpu/nios2/start.o (.text)
|
||||
*(.text)
|
||||
*(.text.*)
|
||||
*(.gnu.linkonce.t*)
|
||||
*(.rodata)
|
||||
*(.rodata.*)
|
||||
*(.gnu.linkonce.r*)
|
||||
}
|
||||
. = ALIGN (4);
|
||||
_etext = .;
|
||||
PROVIDE (etext = .);
|
||||
|
||||
/* CMD TABLE - sandwich this in between text and data so
|
||||
* the initialization code relocates the command table as
|
||||
* well -- admittedly, this is just pure laziness ;-)
|
||||
*/
|
||||
__u_boot_cmd_start = .;
|
||||
.u_boot_cmd :
|
||||
{
|
||||
*(.u_boot_cmd)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
__u_boot_cmd_end = .;
|
||||
|
||||
/* INIT DATA sections - "Small" data (see the gcc -G option)
|
||||
* is always gp-relative. Here we make all init data sections
|
||||
* adjacent to simplify the startup code -- and provide
|
||||
* the global pointer for gp-relative access.
|
||||
*/
|
||||
_data = .;
|
||||
.data :
|
||||
{
|
||||
*(.data)
|
||||
*(.data.*)
|
||||
*(.gnu.linkonce.d*)
|
||||
}
|
||||
|
||||
. = ALIGN(16);
|
||||
_gp = .; /* Global pointer addr */
|
||||
PROVIDE (gp = .);
|
||||
|
||||
.sdata :
|
||||
{
|
||||
*(.sdata)
|
||||
*(.sdata.*)
|
||||
*(.gnu.linkonce.s.*)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
|
||||
_edata = .;
|
||||
PROVIDE (edata = .);
|
||||
|
||||
/* UNINIT DATA - Small uninitialized data is first so it's
|
||||
* adjacent to sdata and can be referenced via gp. The normal
|
||||
* bss follows. We keep it adjacent to simplify init code.
|
||||
*/
|
||||
__bss_start = .;
|
||||
.sbss :
|
||||
{
|
||||
*(.sbss)
|
||||
*(.sbss.*)
|
||||
*(.gnu.linkonce.sb.*)
|
||||
*(.scommon)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
.bss :
|
||||
{
|
||||
*(.bss)
|
||||
*(.bss.*)
|
||||
*(.dynbss)
|
||||
*(COMMON)
|
||||
*(.scommon)
|
||||
}
|
||||
. = ALIGN(4);
|
||||
_end = .;
|
||||
PROVIDE (end = .);
|
||||
|
||||
/* DEBUG -- symbol table, string table, etc. etc.
|
||||
*/
|
||||
.stab 0 : { *(.stab) }
|
||||
.stabstr 0 : { *(.stabstr) }
|
||||
.stab.excl 0 : { *(.stab.excl) }
|
||||
.stab.exclstr 0 : { *(.stab.exclstr) }
|
||||
.stab.index 0 : { *(.stab.index) }
|
||||
.stab.indexstr 0 : { *(.stab.indexstr) }
|
||||
.comment 0 : { *(.comment) }
|
||||
.debug 0 : { *(.debug) }
|
||||
.line 0 : { *(.line) }
|
||||
.debug_srcinfo 0 : { *(.debug_srcinfo) }
|
||||
.debug_sfnames 0 : { *(.debug_sfnames) }
|
||||
.debug_aranges 0 : { *(.debug_aranges) }
|
||||
.debug_pubnames 0 : { *(.debug_pubnames) }
|
||||
.debug_info 0 : { *(.debug_info) }
|
||||
.debug_abbrev 0 : { *(.debug_abbrev) }
|
||||
.debug_line 0 : { *(.debug_line) }
|
||||
.debug_frame 0 : { *(.debug_frame) }
|
||||
.debug_str 0 : { *(.debug_str) }
|
||||
.debug_loc 0 : { *(.debug_loc) }
|
||||
.debug_macinfo 0 : { *(.debug_macinfo) }
|
||||
.debug_weaknames 0 : { *(.debug_weaknames) }
|
||||
.debug_funcnames 0 : { *(.debug_funcnames) }
|
||||
.debug_typenames 0 : { *(.debug_typenames) }
|
||||
.debug_varnames 0 : { *(.debug_varnames) }
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2002
|
||||
# (C) Copyright 2002-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,14 +23,17 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o
|
||||
OBJS += flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
SOBJS = init.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -40,9 +43,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -277,7 +277,7 @@ int board_early_init_f(void)
|
||||
}
|
||||
|
||||
#if (CONFIG_COMMANDS & CFG_CMD_NAND)
|
||||
#include <linux/mtd/nand.h>
|
||||
#include <linux/mtd/nand_legacy.h>
|
||||
extern struct nand_chip nand_dev_desc[CFG_MAX_NAND_DEVICE];
|
||||
|
||||
/*----------------------------------------------------------------------------+
|
||||
@@ -435,7 +435,7 @@ long int initdram (int board_type)
|
||||
*/
|
||||
init_spd_array();
|
||||
|
||||
dram_size = spd_sdram (0);
|
||||
dram_size = spd_sdram();
|
||||
|
||||
return dram_size;
|
||||
}
|
||||
|
||||
@@ -283,10 +283,8 @@
|
||||
/*----------------------------------------------------------------------------+
|
||||
| PPC440EP GPIOs addresses.
|
||||
+----------------------------------------------------------------------------*/
|
||||
#define GPIO0_BASE 0xEF600B00
|
||||
#define GPIO0_REAL 0xEF600B00
|
||||
|
||||
#define GPIO1_BASE 0xEF600C00
|
||||
#define GPIO1_REAL 0xEF600C00
|
||||
|
||||
/* Offsets */
|
||||
@@ -331,17 +329,6 @@
|
||||
#define GPIO_IS3(x) (x+GPIOx_IS3L) /* GPIO Input register3 High or Low */
|
||||
|
||||
|
||||
/*----------------------------------------------------------------------------+
|
||||
| Declare Configuration values
|
||||
+----------------------------------------------------------------------------*/
|
||||
typedef enum gpio_select { GPIO_SEL, GPIO_ALT1, GPIO_ALT2, GPIO_ALT3 } gpio_select_t;
|
||||
typedef enum gpio_driver { GPIO_DIS, GPIO_IN, GPIO_OUT, GPIO_BI } gpio_driver_t;
|
||||
|
||||
typedef struct { unsigned long add; /* gpio core base address */
|
||||
gpio_driver_t in_out; /* Driver Setting */
|
||||
gpio_select_t alt_nb; /* Selected Alternate */
|
||||
} gpio_param_s;
|
||||
|
||||
/*----------------------------------------------------------------------------+
|
||||
| XX XX
|
||||
|
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2002
|
||||
# (C) Copyright 2002-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -21,7 +21,7 @@
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
TEXT_BASE = 0xFFF80000
|
||||
TEXT_BASE = 0xFFFA0000
|
||||
|
||||
PLATFORM_CPPFLAGS += -DCONFIG_440=1
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2000
|
||||
# (C) Copyright 2000-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,12 +23,16 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -38,9 +42,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
#include <ppc4xx.h>
|
||||
#include <asm/processor.h>
|
||||
|
||||
flash_info_t flash_info[CFG_MAX_FLASH_BANKS]; /* info for FLASH chips */
|
||||
flash_info_t flash_info[CFG_MAX_FLASH_BANKS]; /* info for FLASH chips */
|
||||
|
||||
/*-----------------------------------------------------------------------
|
||||
* Functions
|
||||
@@ -76,6 +76,9 @@ void flash_print_info(flash_info_t * info)
|
||||
case FLASH_MAN_SST:
|
||||
printf("SST ");
|
||||
break;
|
||||
case FLASH_MAN_MX:
|
||||
printf ("MACRONIX ");
|
||||
break;
|
||||
default:
|
||||
printf("Unknown Vendor ");
|
||||
break;
|
||||
@@ -124,6 +127,9 @@ void flash_print_info(flash_info_t * info)
|
||||
case FLASH_STMW320DT:
|
||||
printf ("M29W320DT (32 M, top sector)\n");
|
||||
break;
|
||||
case FLASH_MXLV320T:
|
||||
printf ("MXLV320T (32 Mbit, top sector)\n");
|
||||
break;
|
||||
default:
|
||||
printf("Unknown Chip Type\n");
|
||||
break;
|
||||
@@ -217,75 +223,75 @@ static ulong flash_get_size(vu_long * addr, flash_info_t * info)
|
||||
return (0); /* no or unknown flash */
|
||||
}
|
||||
|
||||
value = addr2[1]; /* device ID */
|
||||
value = addr2[1]; /* device ID */
|
||||
DEBUGF("\nFLASH DEVICEID: %x\n", value);
|
||||
|
||||
switch (value) {
|
||||
case (CFG_FLASH_WORD_SIZE) AMD_ID_LV040B:
|
||||
info->flash_id += FLASH_AM040;
|
||||
info->sector_count = 8;
|
||||
info->size = 0x0080000; /* => 512 ko */
|
||||
info->size = 0x0080000; /* => 512 KiB */
|
||||
break;
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE) AMD_ID_F040B:
|
||||
info->flash_id += FLASH_AM040;
|
||||
info->sector_count = 8;
|
||||
info->size = 0x0080000; /* => 512 ko */
|
||||
info->size = 0x0080000; /* => 512 KiB */
|
||||
break;
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE) STM_ID_M29W040B:
|
||||
info->flash_id += FLASH_AM040;
|
||||
info->sector_count = 8;
|
||||
info->size = 0x0080000; /* => 512 ko */
|
||||
info->size = 0x0080000; /* => 512 KiB */
|
||||
break;
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE) AMD_ID_F016D:
|
||||
info->flash_id += FLASH_AMD016;
|
||||
info->sector_count = 32;
|
||||
info->size = 0x00200000;
|
||||
break; /* => 2 MB */
|
||||
info->size = 0x00200000; /* => 2 MiB */
|
||||
break;
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE) AMD_ID_LV033C:
|
||||
info->flash_id += FLASH_AMDLV033C;
|
||||
info->sector_count = 64;
|
||||
info->size = 0x00400000;
|
||||
break; /* => 4 MB */
|
||||
info->size = 0x00400000; /* => 4 MiB */
|
||||
break;
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE) AMD_ID_LV400T:
|
||||
info->flash_id += FLASH_AM400T;
|
||||
info->sector_count = 11;
|
||||
info->size = 0x00080000;
|
||||
break; /* => 0.5 MB */
|
||||
info->size = 0x00080000; /* => 512 KiB */
|
||||
break;
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE) AMD_ID_LV400B:
|
||||
info->flash_id += FLASH_AM400B;
|
||||
info->sector_count = 11;
|
||||
info->size = 0x00080000;
|
||||
break; /* => 0.5 MB */
|
||||
info->size = 0x00080000; /* => 512 KiB */
|
||||
break;
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE) AMD_ID_LV800T:
|
||||
info->flash_id += FLASH_AM800T;
|
||||
info->sector_count = 19;
|
||||
info->size = 0x00100000;
|
||||
break; /* => 1 MB */
|
||||
info->size = 0x00100000; /* => 1 MiB */
|
||||
break;
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE) AMD_ID_LV800B:
|
||||
info->flash_id += FLASH_AM800B;
|
||||
info->sector_count = 19;
|
||||
info->size = 0x00100000;
|
||||
break; /* => 1 MB */
|
||||
info->size = 0x00100000; /* => 1 MiB */
|
||||
break;
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE) AMD_ID_LV160T:
|
||||
info->flash_id += FLASH_AM160T;
|
||||
info->sector_count = 35;
|
||||
info->size = 0x00200000;
|
||||
break; /* => 2 MB */
|
||||
info->size = 0x00200000; /* => 2 MiB */
|
||||
break;
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE) AMD_ID_LV160B:
|
||||
info->flash_id += FLASH_AM160B;
|
||||
info->sector_count = 35;
|
||||
info->size = 0x00200000;
|
||||
break; /* => 2 MB */
|
||||
info->size = 0x00200000; /* => 2 MiB */
|
||||
break;
|
||||
|
||||
default:
|
||||
info->flash_id = FLASH_UNKNOWN;
|
||||
@@ -300,7 +306,7 @@ static ulong flash_get_size(vu_long * addr, flash_info_t * info)
|
||||
info->start[i] = base + (i * 0x00010000);
|
||||
} else {
|
||||
if (info->flash_id & FLASH_BTYPE) {
|
||||
/* set sector offsets for bottom boot block type */
|
||||
/* set sector offsets for bottom boot block type */
|
||||
info->start[0] = base + 0x00000000;
|
||||
info->start[1] = base + 0x00004000;
|
||||
info->start[2] = base + 0x00006000;
|
||||
@@ -310,7 +316,7 @@ static ulong flash_get_size(vu_long * addr, flash_info_t * info)
|
||||
base + (i * 0x00010000) - 0x00030000;
|
||||
}
|
||||
} else {
|
||||
/* set sector offsets for top boot block type */
|
||||
/* set sector offsets for top boot block type */
|
||||
i = info->sector_count - 1;
|
||||
info->start[i--] = base + info->size - 0x00004000;
|
||||
info->start[i--] = base + info->size - 0x00006000;
|
||||
@@ -375,6 +381,7 @@ int flash_erase(flash_info_t * info, int s_first, int s_last)
|
||||
{
|
||||
if (((info->flash_id & FLASH_TYPEMASK) == FLASH_AM320B) ||
|
||||
((info->flash_id & FLASH_TYPEMASK) == FLASH_AM320T) ||
|
||||
((info->flash_id & FLASH_TYPEMASK) == FLASH_MXLV320T) ||
|
||||
((info->flash_id & FLASH_TYPEMASK) == FLASH_STMW320DT)) {
|
||||
return flash_erase_2(info, s_first, s_last);
|
||||
} else {
|
||||
@@ -555,6 +562,7 @@ static int write_word(flash_info_t * info, ulong dest, ulong data)
|
||||
{
|
||||
if (((info->flash_id & FLASH_TYPEMASK) == FLASH_AM320B) ||
|
||||
((info->flash_id & FLASH_TYPEMASK) == FLASH_AM320T) ||
|
||||
((info->flash_id & FLASH_TYPEMASK) == FLASH_MXLV320T) ||
|
||||
((info->flash_id & FLASH_TYPEMASK) == FLASH_STMW320DT)) {
|
||||
return write_word_2(info, dest, data);
|
||||
} else {
|
||||
@@ -648,6 +656,9 @@ static ulong flash_get_size_2(vu_long * addr, flash_info_t * info)
|
||||
case (CFG_FLASH_WORD_SIZE) STM_MANUFACT:
|
||||
info->flash_id = FLASH_MAN_STM;
|
||||
break;
|
||||
case (CFG_FLASH_WORD_SIZE) MX_MANUFACT:
|
||||
info->flash_id = FLASH_MAN_MX;
|
||||
break;
|
||||
default:
|
||||
info->flash_id = FLASH_UNKNOWN;
|
||||
info->sector_count = 0;
|
||||
@@ -655,7 +666,7 @@ static ulong flash_get_size_2(vu_long * addr, flash_info_t * info)
|
||||
return (0); /* no or unknown flash */
|
||||
}
|
||||
|
||||
value = addr2[1]; /* device ID */
|
||||
value = addr2[1]; /* device ID */
|
||||
|
||||
DEBUGF("\nFLASH DEVICEID: %x\n", value);
|
||||
|
||||
@@ -664,17 +675,23 @@ static ulong flash_get_size_2(vu_long * addr, flash_info_t * info)
|
||||
case (CFG_FLASH_WORD_SIZE)AMD_ID_LV320T:
|
||||
info->flash_id += FLASH_AM320T;
|
||||
info->sector_count = 71;
|
||||
info->size = 0x00400000; break; /* => 4 MB */
|
||||
info->size = 0x00400000; break; /* => 4 MiB */
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE)AMD_ID_LV320B:
|
||||
info->flash_id += FLASH_AM320B;
|
||||
info->sector_count = 71;
|
||||
info->size = 0x00400000; break; /* => 4 MB */
|
||||
info->size = 0x00400000; break; /* => 4 MiB */
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE)STM_ID_29W320DT:
|
||||
info->flash_id += FLASH_STMW320DT;
|
||||
info->sector_count = 67;
|
||||
info->size = 0x00400000; break; /* => 4 MB */
|
||||
info->size = 0x00400000; break; /* => 4 MiB */
|
||||
|
||||
case (CFG_FLASH_WORD_SIZE)MX_ID_LV320T:
|
||||
info->flash_id += FLASH_MXLV320T;
|
||||
info->sector_count = 71;
|
||||
info->size = 0x00400000;
|
||||
break; /* => 4 MB */
|
||||
|
||||
default:
|
||||
info->flash_id = FLASH_UNKNOWN;
|
||||
@@ -711,9 +728,22 @@ static ulong flash_get_size_2(vu_long * addr, flash_info_t * info)
|
||||
--i;
|
||||
info->start[i] = base;
|
||||
}
|
||||
} else if ((info->flash_id & FLASH_TYPEMASK) == FLASH_MXLV320T) {
|
||||
i = info->sector_count - 1;
|
||||
info->start[i--] = base + info->size - 0x00002000;
|
||||
info->start[i--] = base + info->size - 0x00004000;
|
||||
info->start[i--] = base + info->size - 0x00006000;
|
||||
info->start[i--] = base + info->size - 0x00008000;
|
||||
info->start[i--] = base + info->size - 0x0000a000;
|
||||
info->start[i--] = base + info->size - 0x0000c000;
|
||||
info->start[i--] = base + info->size - 0x0000e000;
|
||||
info->start[i--] = base + info->size - 0x00010000;
|
||||
|
||||
for (; i >= 0; i--)
|
||||
info->start[i] = base + i * 0x00010000;
|
||||
} else {
|
||||
if (info->flash_id & FLASH_BTYPE) {
|
||||
/* set sector offsets for bottom boot block type */
|
||||
/* set sector offsets for bottom boot block type */
|
||||
info->start[0] = base + 0x00000000;
|
||||
info->start[1] = base + 0x00004000;
|
||||
info->start[2] = base + 0x00006000;
|
||||
@@ -723,7 +753,7 @@ static ulong flash_get_size_2(vu_long * addr, flash_info_t * info)
|
||||
base + (i * 0x00010000) - 0x00030000;
|
||||
}
|
||||
} else {
|
||||
/* set sector offsets for top boot block type */
|
||||
/* set sector offsets for top boot block type */
|
||||
i = info->sector_count - 1;
|
||||
info->start[i--] = base + info->size - 0x00004000;
|
||||
info->start[i--] = base + info->size - 0x00006000;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2002
|
||||
# (C) Copyright 2002-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,13 +23,17 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
SOBJS = init.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -39,9 +43,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -28,6 +28,8 @@
|
||||
#define FLASH_ONBD_N 2 /* 00000010 */
|
||||
#define FLASH_SRAM_SEL 1 /* 00000001 */
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
long int fixed_sdram(void);
|
||||
|
||||
int board_early_init_f(void)
|
||||
@@ -107,7 +109,7 @@ long int initdram(int board_type)
|
||||
long dram_size = 0;
|
||||
|
||||
#if defined(CONFIG_SPD_EEPROM)
|
||||
dram_size = spd_sdram(0);
|
||||
dram_size = spd_sdram();
|
||||
#else
|
||||
dram_size = fixed_sdram();
|
||||
#endif
|
||||
@@ -235,8 +237,6 @@ int pci_pre_init(struct pci_controller *hose)
|
||||
#if defined(CONFIG_PCI) && defined(CFG_PCI_TARGET_INIT)
|
||||
void pci_target_init(struct pci_controller *hose)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
/*--------------------------------------------------------------------------+
|
||||
* Disable everything
|
||||
*--------------------------------------------------------------------------*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2002
|
||||
# (C) Copyright 2002-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,14 +23,17 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o
|
||||
OBJS += flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
SOBJS = init.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -40,9 +43,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
#include <spd_sdram.h>
|
||||
#include "epld.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
extern flash_info_t flash_info[CFG_MAX_FLASH_BANKS]; /* info for FLASH chips */
|
||||
|
||||
@@ -291,8 +292,6 @@ int pci_pre_init( struct pci_controller *hose )
|
||||
#if defined(CONFIG_PCI) && defined(CFG_PCI_TARGET_INIT)
|
||||
void pci_target_init(struct pci_controller *hose)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
/*--------------------------------------------------------------------------+
|
||||
* Disable everything
|
||||
*--------------------------------------------------------------------------*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2002
|
||||
# (C) Copyright 2002-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,13 +23,17 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
SOBJS = init.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -39,9 +43,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -1,30 +1,31 @@
|
||||
/*
|
||||
* Copyright (C) 2002 Scott McNutt <smcnutt@artesyncp.com>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
* Copyright (C) 2002 Scott McNutt <smcnutt@artesyncp.com>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <ppc_asm.tmpl>
|
||||
#include <config.h>
|
||||
|
||||
/* General */
|
||||
#define TLB_VALID 0x00000200
|
||||
#define _256M 0x10000000
|
||||
|
||||
/* Supported page sizes */
|
||||
|
||||
@@ -32,10 +33,11 @@
|
||||
#define SZ_4K 0x00000010
|
||||
#define SZ_16K 0x00000020
|
||||
#define SZ_64K 0x00000030
|
||||
#define SZ_256K 0x00000040
|
||||
#define SZ_256K 0x00000040
|
||||
#define SZ_1M 0x00000050
|
||||
#define SZ_8M 0x00000060
|
||||
#define SZ_16M 0x00000070
|
||||
#define SZ_256M 0x00000090
|
||||
#define SZ_256M 0x00000090
|
||||
|
||||
/* Storage attributes */
|
||||
#define SA_W 0x00000800 /* Write-through */
|
||||
@@ -54,7 +56,7 @@
|
||||
#define EPN(e) ((e) & 0xfffffc00)
|
||||
#define TLB0(epn,sz) ( (EPN((epn)) | (sz) | TLB_VALID ) )
|
||||
#define TLB1(rpn,erpn) ( ((rpn)&0xfffffc00) | (erpn) )
|
||||
#define TLB2(a) ( (a)&0x00000fbf )
|
||||
#define TLB2(a) ( (a)&0x00000fbf )
|
||||
|
||||
#define tlbtab_start\
|
||||
mflr r1 ;\
|
||||
@@ -86,12 +88,14 @@
|
||||
|
||||
tlbtab:
|
||||
tlbtab_start
|
||||
tlbentry( 0xf0000000, SZ_256M, 0xf0000000, 1, AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
tlbentry( CFG_PERIPHERAL_BASE, SZ_256M, 0x40000000, 1, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry( 0xf0000000, SZ_256M, 0xf0000000, 1, AC_R|AC_W|AC_X|SA_G|SA_I )
|
||||
tlbentry( CFG_PERIPHERAL_BASE, SZ_256M, 0x40000000, 1, AC_R|AC_W|SA_G|SA_I )
|
||||
tlbentry( CFG_ISRAM_BASE, SZ_4K, 0x80000000, 0, AC_R|AC_W|AC_X )
|
||||
tlbentry( CFG_ISRAM_BASE + 0x1000, SZ_4K, 0x80001000, 0, AC_R|AC_W|AC_X )
|
||||
tlbentry( CFG_SDRAM_BASE, SZ_256M, 0x00000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I )
|
||||
tlbentry( CFG_SDRAM_BASE+0x10000000, SZ_256M, 0x00000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I )
|
||||
tlbentry( CFG_SDRAM_BASE + 0x10000000, SZ_256M, 0x10000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I )
|
||||
tlbentry( CFG_SDRAM_BASE + 0x20000000, SZ_256M, 0x20000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I )
|
||||
tlbentry( CFG_SDRAM_BASE + 0x30000000, SZ_256M, 0x30000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I )
|
||||
tlbentry( CFG_PCI_BASE, SZ_256M, 0x00000000, 2, AC_R|AC_W|SA_G|SA_I )
|
||||
tlbentry( CFG_PCI_MEMBASE, SZ_256M, 0x00000000, 3, AC_R|AC_W|SA_G|SA_I )
|
||||
tlbtab_end
|
||||
|
||||
@@ -30,6 +30,8 @@
|
||||
#include <spd_sdram.h>
|
||||
#include <ppc4xx_enet.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#define BOOT_SMALL_FLASH 32 /* 00100000 */
|
||||
#define FLASH_ONBD_N 2 /* 00000010 */
|
||||
#define FLASH_SRAM_SEL 1 /* 00000001 */
|
||||
@@ -204,7 +206,7 @@ long int initdram (int board_type)
|
||||
long dram_size = 0;
|
||||
|
||||
#if defined(CONFIG_SPD_EEPROM)
|
||||
dram_size = spd_sdram (0);
|
||||
dram_size = spd_sdram ();
|
||||
#else
|
||||
dram_size = fixed_sdram ();
|
||||
#endif
|
||||
@@ -334,8 +336,6 @@ int pci_pre_init(struct pci_controller * hose )
|
||||
#if defined(CONFIG_PCI) && defined(CFG_PCI_TARGET_INIT)
|
||||
void pci_target_init(struct pci_controller * hose )
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
/*--------------------------------------------------------------------------+
|
||||
* Disable everything
|
||||
*--------------------------------------------------------------------------*/
|
||||
|
||||
52
board/amcc/sequoia/Makefile
Normal file
52
board/amcc/sequoia/Makefile
Normal file
@@ -0,0 +1,52 @@
|
||||
#
|
||||
# (C) Copyright 2002-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
include $(TOPDIR)/include/config.mk
|
||||
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
COBJS = $(BOARD).o sdram.o
|
||||
SOBJS = init.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
|
||||
distclean: clean
|
||||
rm -f $(LIB) core *.bak .depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
41
board/amcc/sequoia/config.mk
Normal file
41
board/amcc/sequoia/config.mk
Normal file
@@ -0,0 +1,41 @@
|
||||
#
|
||||
# (C) Copyright 2002
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
#
|
||||
# AMCC 440EPx Reference Platform (Sequoia) board
|
||||
#
|
||||
|
||||
sinclude $(TOPDIR)/board/$(BOARDDIR)/config.tmp
|
||||
|
||||
ifndef TEXT_BASE
|
||||
TEXT_BASE = 0xFFFA0000
|
||||
endif
|
||||
|
||||
PLATFORM_CPPFLAGS += -DCONFIG_440=1
|
||||
|
||||
ifeq ($(debug),1)
|
||||
PLATFORM_CPPFLAGS += -DDEBUG
|
||||
endif
|
||||
|
||||
ifeq ($(dbcr),1)
|
||||
PLATFORM_CPPFLAGS += -DCFG_INIT_DBCR=0x8cff0000
|
||||
endif
|
||||
157
board/amcc/sequoia/init.S
Normal file
157
board/amcc/sequoia/init.S
Normal file
@@ -0,0 +1,157 @@
|
||||
/*
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <ppc_asm.tmpl>
|
||||
#include <config.h>
|
||||
|
||||
/* General */
|
||||
#define TLB_VALID 0x00000200
|
||||
#define _256M 0x10000000
|
||||
|
||||
/* Supported page sizes */
|
||||
|
||||
#define SZ_1K 0x00000000
|
||||
#define SZ_4K 0x00000010
|
||||
#define SZ_16K 0x00000020
|
||||
#define SZ_64K 0x00000030
|
||||
#define SZ_256K 0x00000040
|
||||
#define SZ_1M 0x00000050
|
||||
#define SZ_8M 0x00000060
|
||||
#define SZ_16M 0x00000070
|
||||
#define SZ_256M 0x00000090
|
||||
|
||||
/* Storage attributes */
|
||||
#define SA_W 0x00000800 /* Write-through */
|
||||
#define SA_I 0x00000400 /* Caching inhibited */
|
||||
#define SA_M 0x00000200 /* Memory coherence */
|
||||
#define SA_G 0x00000100 /* Guarded */
|
||||
#define SA_E 0x00000080 /* Endian */
|
||||
|
||||
/* Access control */
|
||||
#define AC_X 0x00000024 /* Execute */
|
||||
#define AC_W 0x00000012 /* Write */
|
||||
#define AC_R 0x00000009 /* Read */
|
||||
|
||||
/* Some handy macros */
|
||||
|
||||
#define EPN(e) ((e) & 0xfffffc00)
|
||||
#define TLB0(epn,sz) ( (EPN((epn)) | (sz) | TLB_VALID ) )
|
||||
#define TLB1(rpn,erpn) ( ((rpn)&0xfffffc00) | (erpn) )
|
||||
#define TLB2(a) ( (a)&0x00000fbf )
|
||||
|
||||
#define tlbtab_start\
|
||||
mflr r1 ;\
|
||||
bl 0f ;
|
||||
|
||||
#define tlbtab_end\
|
||||
.long 0, 0, 0 ; \
|
||||
0: mflr r0 ; \
|
||||
mtlr r1 ; \
|
||||
blr ;
|
||||
|
||||
#define tlbentry(epn,sz,rpn,erpn,attr)\
|
||||
.long TLB0(epn,sz),TLB1(rpn,erpn),TLB2(attr)
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
* TLB TABLE
|
||||
*
|
||||
* This table is used by the cpu boot code to setup the initial tlb
|
||||
* entries. Rather than make broad assumptions in the cpu source tree,
|
||||
* this table lets each board set things up however they like.
|
||||
*
|
||||
* Pointer to the table is returned in r1
|
||||
*
|
||||
*************************************************************************/
|
||||
.section .bootpg,"ax"
|
||||
.globl tlbtab
|
||||
|
||||
tlbtab:
|
||||
tlbtab_start
|
||||
|
||||
/*
|
||||
* BOOT_CS (FLASH) must be first. Before relocation SA_I can be off to use the
|
||||
* speed up boot process. It is patched after relocation to enable SA_I
|
||||
*/
|
||||
#ifndef CONFIG_NAND_SPL
|
||||
tlbentry( CFG_BOOT_BASE_ADDR, SZ_256M, CFG_BOOT_BASE_ADDR, 1, AC_R|AC_W|AC_X|SA_G )
|
||||
#else
|
||||
tlbentry( CFG_NAND_BOOT_SPL_SRC, SZ_4K, CFG_NAND_BOOT_SPL_SRC, 1, AC_R|AC_W|AC_X|SA_G )
|
||||
#endif
|
||||
|
||||
/* TLB-entry for DDR SDRAM (Up to 2GB) */
|
||||
tlbentry( CFG_SDRAM_BASE, SZ_256M, CFG_SDRAM_BASE, 0, AC_R|AC_W|AC_X|SA_G|SA_I )
|
||||
|
||||
#ifdef CFG_INIT_RAM_DCACHE
|
||||
/* TLB-entry for init-ram in dcache (SA_I must be turned off!) */
|
||||
tlbentry( CFG_INIT_RAM_ADDR, SZ_64K, CFG_INIT_RAM_ADDR, 0, AC_R|AC_W|AC_X|SA_G )
|
||||
#endif
|
||||
|
||||
/* TLB-entry for PCI Memory */
|
||||
tlbentry( CFG_PCI_MEMBASE, SZ_256M, CFG_PCI_MEMBASE, 1, AC_R|AC_W|SA_G|SA_I )
|
||||
tlbentry( CFG_PCI_MEMBASE1, SZ_256M, CFG_PCI_MEMBASE1, 1, AC_R|AC_W|SA_G|SA_I )
|
||||
tlbentry( CFG_PCI_MEMBASE2, SZ_256M, CFG_PCI_MEMBASE2, 1, AC_R|AC_W|SA_G|SA_I )
|
||||
tlbentry( CFG_PCI_MEMBASE3, SZ_256M, CFG_PCI_MEMBASE3, 1, AC_R|AC_W|SA_G|SA_I )
|
||||
|
||||
/* TLB-entry for EBC */
|
||||
tlbentry( CFG_BCSR_BASE, SZ_1K, CFG_BCSR_BASE, 1, AC_R|AC_W|AC_X|SA_G|SA_I )
|
||||
|
||||
/* TLB-entry for NAND */
|
||||
tlbentry( CFG_NAND_ADDR, SZ_1K, CFG_NAND_ADDR, 1, AC_R|AC_W|AC_X|SA_G|SA_I )
|
||||
|
||||
/* TLB-entry for Internal Registers & OCM */
|
||||
tlbentry( 0xe0000000, SZ_16M, 0xe0000000, 0, AC_R|AC_W|AC_X|SA_I )
|
||||
|
||||
/*TLB-entry PCI registers*/
|
||||
tlbentry( 0xEEC00000, SZ_1K, 0xEEC00000, 1, AC_R|AC_W|AC_X|SA_G|SA_I )
|
||||
|
||||
/* TLB-entry for peripherals */
|
||||
tlbentry( 0xEF000000, SZ_16M, 0xEF000000, 1, AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
|
||||
tlbtab_end
|
||||
|
||||
#if defined(CONFIG_NAND_U_BOOT) && !defined(CONFIG_NAND_SPL)
|
||||
/*
|
||||
* For NAND booting the first TLB has to be reconfigured to full size
|
||||
* and with caching disabled after running from RAM!
|
||||
*/
|
||||
#define TLB00 TLB0(CFG_BOOT_BASE_ADDR, SZ_256M)
|
||||
#define TLB01 TLB1(CFG_BOOT_BASE_ADDR, 1)
|
||||
#define TLB02 TLB2(AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
|
||||
.globl reconfig_tlb0
|
||||
reconfig_tlb0:
|
||||
sync
|
||||
isync
|
||||
addi r4,r0,0x0000 /* TLB entry #0 */
|
||||
lis r5,TLB00@h
|
||||
ori r5,r5,TLB00@l
|
||||
tlbwe r5,r4,0x0000 /* Save it out */
|
||||
lis r5,TLB01@h
|
||||
ori r5,r5,TLB01@l
|
||||
tlbwe r5,r4,0x0001 /* Save it out */
|
||||
lis r5,TLB02@h
|
||||
ori r5,r5,TLB02@l
|
||||
tlbwe r5,r4,0x0002 /* Save it out */
|
||||
sync
|
||||
isync
|
||||
blr
|
||||
#endif
|
||||
77
board/amcc/sequoia/sdram.c
Normal file
77
board/amcc/sequoia/sdram.c
Normal file
@@ -0,0 +1,77 @@
|
||||
/*
|
||||
* (C) Copyright 2006
|
||||
* Stefan Roese, DENX Software Engineering, sr@denx.de.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <asm/processor.h>
|
||||
#include <ppc440.h>
|
||||
|
||||
/*************************************************************************
|
||||
*
|
||||
* initdram -- 440EPx's DDR controller is a DENALI Core
|
||||
*
|
||||
************************************************************************/
|
||||
long int initdram (int board_type)
|
||||
{
|
||||
#if !defined(CONFIG_NAND_U_BOOT) || defined(CONFIG_NAND_SPL)
|
||||
volatile ulong val;
|
||||
|
||||
mtsdram(DDR0_02, 0x00000000);
|
||||
|
||||
mtsdram(DDR0_00, 0x0000190A);
|
||||
mtsdram(DDR0_01, 0x01000000);
|
||||
mtsdram(DDR0_03, 0x02030602);
|
||||
mtsdram(DDR0_04, 0x13030300);
|
||||
mtsdram(DDR0_05, 0x0202050E);
|
||||
mtsdram(DDR0_06, 0x0104C823);
|
||||
mtsdram(DDR0_07, 0x000D0100);
|
||||
mtsdram(DDR0_08, 0x02360001);
|
||||
mtsdram(DDR0_09, 0x00011D5F);
|
||||
mtsdram(DDR0_10, 0x00000300);
|
||||
mtsdram(DDR0_11, 0x0027C800);
|
||||
mtsdram(DDR0_12, 0x00000003);
|
||||
mtsdram(DDR0_14, 0x00000000);
|
||||
mtsdram(DDR0_17, 0x19000000);
|
||||
mtsdram(DDR0_18, 0x19191919);
|
||||
mtsdram(DDR0_19, 0x19191919);
|
||||
mtsdram(DDR0_20, 0x0B0B0B0B);
|
||||
mtsdram(DDR0_21, 0x0B0B0B0B);
|
||||
mtsdram(DDR0_22, 0x00267F0B);
|
||||
mtsdram(DDR0_23, 0x00000000);
|
||||
mtsdram(DDR0_24, 0x01010002);
|
||||
mtsdram(DDR0_26, 0x5B260181);
|
||||
mtsdram(DDR0_27, 0x0000682B);
|
||||
mtsdram(DDR0_28, 0x00000000);
|
||||
mtsdram(DDR0_31, 0x00000000);
|
||||
mtsdram(DDR0_42, 0x01000006);
|
||||
mtsdram(DDR0_43, 0x050A0200);
|
||||
mtsdram(DDR0_44, 0x00000005);
|
||||
mtsdram(DDR0_02, 0x00000001);
|
||||
|
||||
/*
|
||||
* Wait for DCC master delay line to finish calibration
|
||||
*/
|
||||
mfsdram(DDR0_17, val);
|
||||
while (((val >> 8) & 0x000007f) == 0) {
|
||||
mfsdram(DDR0_17, val);
|
||||
}
|
||||
#endif /* #ifndef CONFIG_NAND_U_BOOT */
|
||||
|
||||
return (CFG_MBYTES_SDRAM << 20);
|
||||
}
|
||||
560
board/amcc/sequoia/sequoia.c
Normal file
560
board/amcc/sequoia/sequoia.c
Normal file
@@ -0,0 +1,560 @@
|
||||
/*
|
||||
* (C) Copyright 2006
|
||||
* Stefan Roese, DENX Software Engineering, sr@denx.de.
|
||||
*
|
||||
* (C) Copyright 2006
|
||||
* Jacqueline Pira-Ferriol, AMCC/IBM, jpira-ferriol@fr.ibm.com
|
||||
* Alain Saurel, AMCC/IBM, alain.saurel@fr.ibm.com
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <asm/processor.h>
|
||||
#include <ppc440.h>
|
||||
#include "sequoia.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
extern flash_info_t flash_info[CFG_MAX_FLASH_BANKS]; /* info for FLASH chips */
|
||||
|
||||
int board_early_init_f(void)
|
||||
{
|
||||
unsigned long sdr0_cust0;
|
||||
unsigned long sdr0_pfc1, sdr0_pfc2;
|
||||
register uint reg;
|
||||
|
||||
mtdcr(ebccfga, xbcfg);
|
||||
mtdcr(ebccfgd, 0xb8400000);
|
||||
|
||||
/*--------------------------------------------------------------------
|
||||
* Setup the GPIO pins
|
||||
*-------------------------------------------------------------------*/
|
||||
/* test-only: take GPIO init from pcs440ep ???? in config file */
|
||||
out32(GPIO0_OR, 0x00000000);
|
||||
out32(GPIO0_TCR, 0x0000000f);
|
||||
out32(GPIO0_OSRL, 0x50015400);
|
||||
out32(GPIO0_OSRH, 0x550050aa);
|
||||
out32(GPIO0_TSRL, 0x50015400);
|
||||
out32(GPIO0_TSRH, 0x55005000);
|
||||
out32(GPIO0_ISR1L, 0x50000000);
|
||||
out32(GPIO0_ISR1H, 0x00000000);
|
||||
out32(GPIO0_ISR2L, 0x00000000);
|
||||
out32(GPIO0_ISR2H, 0x00000100);
|
||||
out32(GPIO0_ISR3L, 0x00000000);
|
||||
out32(GPIO0_ISR3H, 0x00000000);
|
||||
|
||||
out32(GPIO1_OR, 0x00000000);
|
||||
out32(GPIO1_TCR, 0xc2000000);
|
||||
out32(GPIO1_OSRL, 0x5c280000);
|
||||
out32(GPIO1_OSRH, 0x00000000);
|
||||
out32(GPIO1_TSRL, 0x0c000000);
|
||||
out32(GPIO1_TSRH, 0x00000000);
|
||||
out32(GPIO1_ISR1L, 0x00005550);
|
||||
out32(GPIO1_ISR1H, 0x00000000);
|
||||
out32(GPIO1_ISR2L, 0x00050000);
|
||||
out32(GPIO1_ISR2H, 0x00000000);
|
||||
out32(GPIO1_ISR3L, 0x01400000);
|
||||
out32(GPIO1_ISR3H, 0x00000000);
|
||||
|
||||
/*--------------------------------------------------------------------
|
||||
* Setup the interrupt controller polarities, triggers, etc.
|
||||
*-------------------------------------------------------------------*/
|
||||
mtdcr(uic0sr, 0xffffffff); /* clear all */
|
||||
mtdcr(uic0er, 0x00000000); /* disable all */
|
||||
mtdcr(uic0cr, 0x00000005); /* ATI & UIC1 crit are critical */
|
||||
mtdcr(uic0pr, 0xfffff7ff); /* per ref-board manual */
|
||||
mtdcr(uic0tr, 0x00000000); /* per ref-board manual */
|
||||
mtdcr(uic0vr, 0x00000000); /* int31 highest, base=0x000 */
|
||||
mtdcr(uic0sr, 0xffffffff); /* clear all */
|
||||
|
||||
mtdcr(uic1sr, 0xffffffff); /* clear all */
|
||||
mtdcr(uic1er, 0x00000000); /* disable all */
|
||||
mtdcr(uic1cr, 0x00000000); /* all non-critical */
|
||||
mtdcr(uic1pr, 0xffffffff); /* per ref-board manual */
|
||||
mtdcr(uic1tr, 0x00000000); /* per ref-board manual */
|
||||
mtdcr(uic1vr, 0x00000000); /* int31 highest, base=0x000 */
|
||||
mtdcr(uic1sr, 0xffffffff); /* clear all */
|
||||
|
||||
mtdcr(uic2sr, 0xffffffff); /* clear all */
|
||||
mtdcr(uic2er, 0x00000000); /* disable all */
|
||||
mtdcr(uic2cr, 0x00000000); /* all non-critical */
|
||||
mtdcr(uic2pr, 0xffffffff); /* per ref-board manual */
|
||||
mtdcr(uic2tr, 0x00000000); /* per ref-board manual */
|
||||
mtdcr(uic2vr, 0x00000000); /* int31 highest, base=0x000 */
|
||||
mtdcr(uic2sr, 0xffffffff); /* clear all */
|
||||
|
||||
/* 50MHz tmrclk */
|
||||
*(unsigned char *)(CFG_BCSR_BASE | 0x04) = 0x00;
|
||||
|
||||
/* clear write protects */
|
||||
*(unsigned char *)(CFG_BCSR_BASE | 0x07) = 0x00;
|
||||
|
||||
/* enable Ethernet */
|
||||
*(unsigned char *)(CFG_BCSR_BASE | 0x08) = 0x00;
|
||||
|
||||
/* enable USB device */
|
||||
*(unsigned char *)(CFG_BCSR_BASE | 0x09) = 0x20;
|
||||
|
||||
/* select Ethernet pins */
|
||||
mfsdr(SDR0_PFC1, sdr0_pfc1);
|
||||
sdr0_pfc1 = (sdr0_pfc1 & ~SDR0_PFC1_SELECT_MASK) | SDR0_PFC1_SELECT_CONFIG_4;
|
||||
mfsdr(SDR0_PFC2, sdr0_pfc2);
|
||||
sdr0_pfc2 = (sdr0_pfc2 & ~SDR0_PFC2_SELECT_MASK) | SDR0_PFC2_SELECT_CONFIG_4;
|
||||
mtsdr(SDR0_PFC2, sdr0_pfc2);
|
||||
mtsdr(SDR0_PFC1, sdr0_pfc1);
|
||||
|
||||
/* PCI arbiter enabled */
|
||||
mfsdr(sdr_pci0, reg);
|
||||
mtsdr(sdr_pci0, 0x80000000 | reg);
|
||||
|
||||
/* setup NAND FLASH */
|
||||
mfsdr(SDR0_CUST0, sdr0_cust0);
|
||||
sdr0_cust0 = SDR0_CUST0_MUX_NDFC_SEL |
|
||||
SDR0_CUST0_NDFC_ENABLE |
|
||||
SDR0_CUST0_NDFC_BW_8_BIT |
|
||||
SDR0_CUST0_NDFC_ARE_MASK |
|
||||
(0x80000000 >> (28 + CFG_NAND_CS));
|
||||
mtsdr(SDR0_CUST0, sdr0_cust0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*---------------------------------------------------------------------------+
|
||||
| misc_init_r.
|
||||
+---------------------------------------------------------------------------*/
|
||||
int misc_init_r(void)
|
||||
{
|
||||
uint pbcr;
|
||||
int size_val = 0;
|
||||
#ifdef CONFIG_440EPX
|
||||
unsigned long usb2d0cr = 0;
|
||||
unsigned long usb2phy0cr, usb2h0cr = 0;
|
||||
unsigned long sdr0_pfc1;
|
||||
char *act = getenv("usbact");
|
||||
#endif
|
||||
|
||||
/*
|
||||
* FLASH stuff...
|
||||
*/
|
||||
|
||||
/* Re-do sizing to get full correct info */
|
||||
#if defined(CONFIG_NAND_U_BOOT) || defined(CONFIG_NAND_SPL)
|
||||
mtdcr(ebccfga, pb3cr);
|
||||
#else
|
||||
mtdcr(ebccfga, pb0cr);
|
||||
#endif
|
||||
pbcr = mfdcr(ebccfgd);
|
||||
switch (gd->bd->bi_flashsize) {
|
||||
case 1 << 20:
|
||||
size_val = 0;
|
||||
break;
|
||||
case 2 << 20:
|
||||
size_val = 1;
|
||||
break;
|
||||
case 4 << 20:
|
||||
size_val = 2;
|
||||
break;
|
||||
case 8 << 20:
|
||||
size_val = 3;
|
||||
break;
|
||||
case 16 << 20:
|
||||
size_val = 4;
|
||||
break;
|
||||
case 32 << 20:
|
||||
size_val = 5;
|
||||
break;
|
||||
case 64 << 20:
|
||||
size_val = 6;
|
||||
break;
|
||||
case 128 << 20:
|
||||
size_val = 7;
|
||||
break;
|
||||
}
|
||||
pbcr = (pbcr & 0x0001ffff) | gd->bd->bi_flashstart | (size_val << 17);
|
||||
#if defined(CONFIG_NAND_U_BOOT) || defined(CONFIG_NAND_SPL)
|
||||
mtdcr(ebccfga, pb3cr);
|
||||
#else
|
||||
mtdcr(ebccfga, pb0cr);
|
||||
#endif
|
||||
mtdcr(ebccfgd, pbcr);
|
||||
|
||||
/* adjust flash start and offset */
|
||||
gd->bd->bi_flashstart = 0 - gd->bd->bi_flashsize;
|
||||
gd->bd->bi_flashoffset = 0;
|
||||
|
||||
#ifdef CFG_ENV_IS_IN_FLASH
|
||||
/* Monitor protection ON by default */
|
||||
(void)flash_protect(FLAG_PROTECT_SET,
|
||||
-CFG_MONITOR_LEN,
|
||||
0xffffffff,
|
||||
&flash_info[0]);
|
||||
|
||||
/* Env protection ON by default */
|
||||
(void)flash_protect(FLAG_PROTECT_SET,
|
||||
CFG_ENV_ADDR_REDUND,
|
||||
CFG_ENV_ADDR_REDUND + 2*CFG_ENV_SECT_SIZE - 1,
|
||||
&flash_info[0]);
|
||||
#endif
|
||||
|
||||
/*
|
||||
* USB suff...
|
||||
*/
|
||||
#ifdef CONFIG_440EPX
|
||||
if (act == NULL || strcmp(act, "hostdev") == 0) {
|
||||
/* SDR Setting */
|
||||
mfsdr(SDR0_PFC1, sdr0_pfc1);
|
||||
mfsdr(SDR0_USB0, usb2d0cr);
|
||||
mfsdr(SDR0_USB2PHY0CR, usb2phy0cr);
|
||||
mfsdr(SDR0_USB2H0CR, usb2h0cr);
|
||||
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_XOCLK_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_XOCLK_EXTERNAL; /*0*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_WDINT_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_WDINT_16BIT_30MHZ; /*1*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_DVBUS_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_DVBUS_PURDIS; /*0*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_DWNSTR_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_DWNSTR_HOST; /*1*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_UTMICN_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_UTMICN_HOST; /*1*/
|
||||
|
||||
/* An 8-bit/60MHz interface is the only possible alternative
|
||||
when connecting the Device to the PHY */
|
||||
usb2h0cr = usb2h0cr &~SDR0_USB2H0CR_WDINT_MASK;
|
||||
usb2h0cr = usb2h0cr | SDR0_USB2H0CR_WDINT_16BIT_30MHZ; /*1*/
|
||||
|
||||
/* To enable the USB 2.0 Device function through the UTMI interface */
|
||||
usb2d0cr = usb2d0cr &~SDR0_USB2D0CR_USB2DEV_EBC_SEL_MASK;
|
||||
usb2d0cr = usb2d0cr | SDR0_USB2D0CR_USB2DEV_SELECTION; /*1*/
|
||||
|
||||
sdr0_pfc1 = sdr0_pfc1 &~SDR0_PFC1_UES_MASK;
|
||||
sdr0_pfc1 = sdr0_pfc1 | SDR0_PFC1_UES_USB2D_SEL; /*0*/
|
||||
|
||||
mtsdr(SDR0_PFC1, sdr0_pfc1);
|
||||
mtsdr(SDR0_USB0, usb2d0cr);
|
||||
mtsdr(SDR0_USB2PHY0CR, usb2phy0cr);
|
||||
mtsdr(SDR0_USB2H0CR, usb2h0cr);
|
||||
|
||||
/*clear resets*/
|
||||
udelay (1000);
|
||||
mtsdr(SDR0_SRST1, 0x00000000);
|
||||
udelay (1000);
|
||||
mtsdr(SDR0_SRST0, 0x00000000);
|
||||
|
||||
printf("USB: Host(int phy) Device(ext phy)\n");
|
||||
|
||||
} else if (strcmp(act, "dev") == 0) {
|
||||
/*-------------------PATCH-------------------------------*/
|
||||
mfsdr(SDR0_USB2PHY0CR, usb2phy0cr);
|
||||
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_XOCLK_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_XOCLK_EXTERNAL; /*0*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_DVBUS_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_DVBUS_PURDIS; /*0*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_DWNSTR_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_DWNSTR_HOST; /*1*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_UTMICN_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_UTMICN_HOST; /*1*/
|
||||
mtsdr(SDR0_USB2PHY0CR, usb2phy0cr);
|
||||
|
||||
udelay (1000);
|
||||
mtsdr(SDR0_SRST1, 0x672c6000);
|
||||
|
||||
udelay (1000);
|
||||
mtsdr(SDR0_SRST0, 0x00000080);
|
||||
|
||||
udelay (1000);
|
||||
mtsdr(SDR0_SRST1, 0x60206000);
|
||||
|
||||
*(unsigned int *)(0xe0000350) = 0x00000001;
|
||||
|
||||
udelay (1000);
|
||||
mtsdr(SDR0_SRST1, 0x60306000);
|
||||
/*-------------------PATCH-------------------------------*/
|
||||
|
||||
/* SDR Setting */
|
||||
mfsdr(SDR0_USB2PHY0CR, usb2phy0cr);
|
||||
mfsdr(SDR0_USB2H0CR, usb2h0cr);
|
||||
mfsdr(SDR0_USB0, usb2d0cr);
|
||||
mfsdr(SDR0_PFC1, sdr0_pfc1);
|
||||
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_XOCLK_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_XOCLK_EXTERNAL; /*0*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_WDINT_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_WDINT_8BIT_60MHZ; /*0*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_DVBUS_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_DVBUS_PUREN; /*1*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_DWNSTR_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_DWNSTR_DEV; /*0*/
|
||||
usb2phy0cr = usb2phy0cr &~SDR0_USB2PHY0CR_UTMICN_MASK;
|
||||
usb2phy0cr = usb2phy0cr | SDR0_USB2PHY0CR_UTMICN_DEV; /*0*/
|
||||
|
||||
usb2h0cr = usb2h0cr &~SDR0_USB2H0CR_WDINT_MASK;
|
||||
usb2h0cr = usb2h0cr | SDR0_USB2H0CR_WDINT_8BIT_60MHZ; /*0*/
|
||||
|
||||
usb2d0cr = usb2d0cr &~SDR0_USB2D0CR_USB2DEV_EBC_SEL_MASK;
|
||||
usb2d0cr = usb2d0cr | SDR0_USB2D0CR_EBC_SELECTION; /*0*/
|
||||
|
||||
sdr0_pfc1 = sdr0_pfc1 &~SDR0_PFC1_UES_MASK;
|
||||
sdr0_pfc1 = sdr0_pfc1 | SDR0_PFC1_UES_EBCHR_SEL; /*1*/
|
||||
|
||||
mtsdr(SDR0_USB2H0CR, usb2h0cr);
|
||||
mtsdr(SDR0_USB2PHY0CR, usb2phy0cr);
|
||||
mtsdr(SDR0_USB0, usb2d0cr);
|
||||
mtsdr(SDR0_PFC1, sdr0_pfc1);
|
||||
|
||||
/*clear resets*/
|
||||
udelay (1000);
|
||||
mtsdr(SDR0_SRST1, 0x00000000);
|
||||
udelay (1000);
|
||||
mtsdr(SDR0_SRST0, 0x00000000);
|
||||
|
||||
printf("USB: Device(int phy)\n");
|
||||
}
|
||||
#endif /* CONFIG_440EPX */
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int checkboard(void)
|
||||
{
|
||||
char *s = getenv("serial#");
|
||||
|
||||
#ifdef CONFIG_440EPX
|
||||
printf("Board: Sequoia - AMCC PPC440EPx Evaluation Board");
|
||||
#else
|
||||
printf("Board: Rainier - AMCC PPC440GRx Evaluation Board");
|
||||
#endif
|
||||
if (s != NULL) {
|
||||
puts(", serial# ");
|
||||
puts(s);
|
||||
}
|
||||
putc('\n');
|
||||
|
||||
return (0);
|
||||
}
|
||||
|
||||
#if defined(CFG_DRAM_TEST)
|
||||
int testdram(void)
|
||||
{
|
||||
unsigned long *mem = (unsigned long *)0;
|
||||
const unsigned long kend = (1024 / sizeof(unsigned long));
|
||||
unsigned long k, n;
|
||||
|
||||
mtmsr(0);
|
||||
|
||||
for (k = 0; k < CFG_MBYTES_SDRAM;
|
||||
++k, mem += (1024 / sizeof(unsigned long))) {
|
||||
if ((k & 1023) == 0) {
|
||||
printf("%3d MB\r", k / 1024);
|
||||
}
|
||||
|
||||
memset(mem, 0xaaaaaaaa, 1024);
|
||||
for (n = 0; n < kend; ++n) {
|
||||
if (mem[n] != 0xaaaaaaaa) {
|
||||
printf("SDRAM test fails at: %08x\n",
|
||||
(uint) & mem[n]);
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
memset(mem, 0x55555555, 1024);
|
||||
for (n = 0; n < kend; ++n) {
|
||||
if (mem[n] != 0x55555555) {
|
||||
printf("SDRAM test fails at: %08x\n",
|
||||
(uint) & mem[n]);
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
printf("SDRAM test passes\n");
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
/*************************************************************************
|
||||
* pci_pre_init
|
||||
*
|
||||
* This routine is called just prior to registering the hose and gives
|
||||
* the board the opportunity to check things. Returning a value of zero
|
||||
* indicates that things are bad & PCI initialization should be aborted.
|
||||
*
|
||||
* Different boards may wish to customize the pci controller structure
|
||||
* (add regions, override default access routines, etc) or perform
|
||||
* certain pre-initialization actions.
|
||||
*
|
||||
************************************************************************/
|
||||
#if defined(CONFIG_PCI) && defined(CFG_PCI_PRE_INIT)
|
||||
int pci_pre_init(struct pci_controller *hose)
|
||||
{
|
||||
unsigned long addr;
|
||||
#if 0
|
||||
/*--------------------------------------------------------------------------+
|
||||
* Cactus is always configured as the host & requires the
|
||||
* PCI arbiter to be enabled ???
|
||||
*--------------------------------------------------------------------------*/
|
||||
unsigned long strap;
|
||||
mfsdr(sdr_sdstp1, strap);
|
||||
if ((strap & SDR0_SDSTP1_PAE_MASK) == 0) {
|
||||
printf("PCI: SDR0_STRP1[PAE] not set.\n");
|
||||
printf("PCI: Configuration aborted.\n");
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
/*-------------------------------------------------------------------------+
|
||||
| Set priority for all PLB3 devices to 0.
|
||||
| Set PLB3 arbiter to fair mode.
|
||||
+-------------------------------------------------------------------------*/
|
||||
mfsdr(sdr_amp1, addr);
|
||||
mtsdr(sdr_amp1, (addr & 0x000000FF) | 0x0000FF00);
|
||||
addr = mfdcr(plb3_acr);
|
||||
mtdcr(plb3_acr, addr | 0x80000000);
|
||||
|
||||
/*-------------------------------------------------------------------------+
|
||||
| Set priority for all PLB4 devices to 0.
|
||||
+-------------------------------------------------------------------------*/
|
||||
mfsdr(sdr_amp0, addr);
|
||||
mtsdr(sdr_amp0, (addr & 0x000000FF) | 0x0000FF00);
|
||||
addr = mfdcr(plb4_acr) | 0xa0000000; /* Was 0x8---- */
|
||||
mtdcr(plb4_acr, addr);
|
||||
|
||||
/*-------------------------------------------------------------------------+
|
||||
| Set Nebula PLB4 arbiter to fair mode.
|
||||
+-------------------------------------------------------------------------*/
|
||||
/* Segment0 */
|
||||
addr = (mfdcr(plb0_acr) & ~plb0_acr_ppm_mask) | plb0_acr_ppm_fair;
|
||||
addr = (addr & ~plb0_acr_hbu_mask) | plb0_acr_hbu_enabled;
|
||||
addr = (addr & ~plb0_acr_rdp_mask) | plb0_acr_rdp_4deep;
|
||||
addr = (addr & ~plb0_acr_wrp_mask) | plb0_acr_wrp_2deep;
|
||||
mtdcr(plb0_acr, addr);
|
||||
|
||||
/* Segment1 */
|
||||
addr = (mfdcr(plb1_acr) & ~plb1_acr_ppm_mask) | plb1_acr_ppm_fair;
|
||||
addr = (addr & ~plb1_acr_hbu_mask) | plb1_acr_hbu_enabled;
|
||||
addr = (addr & ~plb1_acr_rdp_mask) | plb1_acr_rdp_4deep;
|
||||
addr = (addr & ~plb1_acr_wrp_mask) | plb1_acr_wrp_2deep;
|
||||
mtdcr(plb1_acr, addr);
|
||||
|
||||
return 1;
|
||||
}
|
||||
#endif /* defined(CONFIG_PCI) && defined(CFG_PCI_PRE_INIT) */
|
||||
|
||||
/*************************************************************************
|
||||
* pci_target_init
|
||||
*
|
||||
* The bootstrap configuration provides default settings for the pci
|
||||
* inbound map (PIM). But the bootstrap config choices are limited and
|
||||
* may not be sufficient for a given board.
|
||||
*
|
||||
************************************************************************/
|
||||
#if defined(CONFIG_PCI) && defined(CFG_PCI_TARGET_INIT)
|
||||
void pci_target_init(struct pci_controller *hose)
|
||||
{
|
||||
/*--------------------------------------------------------------------------+
|
||||
* Set up Direct MMIO registers
|
||||
*--------------------------------------------------------------------------*/
|
||||
/*--------------------------------------------------------------------------+
|
||||
| PowerPC440EPX PCI Master configuration.
|
||||
| Map one 1Gig range of PLB/processor addresses to PCI memory space.
|
||||
| PLB address 0xA0000000-0xDFFFFFFF ==> PCI address 0xA0000000-0xDFFFFFFF
|
||||
| Use byte reversed out routines to handle endianess.
|
||||
| Make this region non-prefetchable.
|
||||
+--------------------------------------------------------------------------*/
|
||||
out32r(PCIX0_PMM0MA, 0x00000000); /* PMM0 Mask/Attribute - disabled b4 setting */
|
||||
out32r(PCIX0_PMM0LA, CFG_PCI_MEMBASE); /* PMM0 Local Address */
|
||||
out32r(PCIX0_PMM0PCILA, CFG_PCI_MEMBASE); /* PMM0 PCI Low Address */
|
||||
out32r(PCIX0_PMM0PCIHA, 0x00000000); /* PMM0 PCI High Address */
|
||||
out32r(PCIX0_PMM0MA, 0xE0000001); /* 512M + No prefetching, and enable region */
|
||||
|
||||
out32r(PCIX0_PMM1MA, 0x00000000); /* PMM0 Mask/Attribute - disabled b4 setting */
|
||||
out32r(PCIX0_PMM1LA, CFG_PCI_MEMBASE2); /* PMM0 Local Address */
|
||||
out32r(PCIX0_PMM1PCILA, CFG_PCI_MEMBASE2); /* PMM0 PCI Low Address */
|
||||
out32r(PCIX0_PMM1PCIHA, 0x00000000); /* PMM0 PCI High Address */
|
||||
out32r(PCIX0_PMM1MA, 0xE0000001); /* 512M + No prefetching, and enable region */
|
||||
|
||||
out32r(PCIX0_PTM1MS, 0x00000001); /* Memory Size/Attribute */
|
||||
out32r(PCIX0_PTM1LA, 0); /* Local Addr. Reg */
|
||||
out32r(PCIX0_PTM2MS, 0); /* Memory Size/Attribute */
|
||||
out32r(PCIX0_PTM2LA, 0); /* Local Addr. Reg */
|
||||
|
||||
/*--------------------------------------------------------------------------+
|
||||
* Set up Configuration registers
|
||||
*--------------------------------------------------------------------------*/
|
||||
|
||||
/* Program the board's subsystem id/vendor id */
|
||||
pci_write_config_word(0, PCI_SUBSYSTEM_VENDOR_ID,
|
||||
CFG_PCI_SUBSYS_VENDORID);
|
||||
pci_write_config_word(0, PCI_SUBSYSTEM_ID, CFG_PCI_SUBSYS_ID);
|
||||
|
||||
/* Configure command register as bus master */
|
||||
pci_write_config_word(0, PCI_COMMAND, PCI_COMMAND_MASTER);
|
||||
|
||||
/* 240nS PCI clock */
|
||||
pci_write_config_word(0, PCI_LATENCY_TIMER, 1);
|
||||
|
||||
/* No error reporting */
|
||||
pci_write_config_word(0, PCI_ERREN, 0);
|
||||
|
||||
pci_write_config_dword(0, PCI_BRDGOPT2, 0x00000101);
|
||||
|
||||
}
|
||||
#endif /* defined(CONFIG_PCI) && defined(CFG_PCI_TARGET_INIT) */
|
||||
|
||||
/*************************************************************************
|
||||
* pci_master_init
|
||||
*
|
||||
************************************************************************/
|
||||
#if defined(CONFIG_PCI) && defined(CFG_PCI_MASTER_INIT)
|
||||
void pci_master_init(struct pci_controller *hose)
|
||||
{
|
||||
unsigned short temp_short;
|
||||
|
||||
/*--------------------------------------------------------------------------+
|
||||
| Write the PowerPC440 EP PCI Configuration regs.
|
||||
| Enable PowerPC440 EP to be a master on the PCI bus (PMM).
|
||||
| Enable PowerPC440 EP to act as a PCI memory target (PTM).
|
||||
+--------------------------------------------------------------------------*/
|
||||
pci_read_config_word(0, PCI_COMMAND, &temp_short);
|
||||
pci_write_config_word(0, PCI_COMMAND,
|
||||
temp_short | PCI_COMMAND_MASTER |
|
||||
PCI_COMMAND_MEMORY);
|
||||
}
|
||||
#endif /* defined(CONFIG_PCI) && defined(CFG_PCI_MASTER_INIT) */
|
||||
|
||||
/*************************************************************************
|
||||
* is_pci_host
|
||||
*
|
||||
* This routine is called to determine if a pci scan should be
|
||||
* performed. With various hardware environments (especially cPCI and
|
||||
* PPMC) it's insufficient to depend on the state of the arbiter enable
|
||||
* bit in the strap register, or generic host/adapter assumptions.
|
||||
*
|
||||
* Rather than hard-code a bad assumption in the general 440 code, the
|
||||
* 440 pci code requires the board to decide at runtime.
|
||||
*
|
||||
* Return 0 for adapter mode, non-zero for host (monarch) mode.
|
||||
*
|
||||
*
|
||||
************************************************************************/
|
||||
#if defined(CONFIG_PCI)
|
||||
int is_pci_host(struct pci_controller *hose)
|
||||
{
|
||||
/* Cactus is always configured as host. */
|
||||
return (1);
|
||||
}
|
||||
#endif /* defined(CONFIG_PCI) */
|
||||
67
board/amcc/sequoia/sequoia.h
Normal file
67
board/amcc/sequoia/sequoia.h
Normal file
@@ -0,0 +1,67 @@
|
||||
/*
|
||||
* (C) Copyright 2006
|
||||
* Stefan Roese, DENX Software Engineering, sr@denx.de.
|
||||
*
|
||||
* (C) Copyright 2006
|
||||
* Jacqueline Pira-Ferriol, AMCC/IBM, jpira-ferriol@fr.ibm.com
|
||||
* Alain Saurel, AMCC/IBM, alain.saurel@fr.ibm.com
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
|
||||
/*----------------------------------------------------------------------------+
|
||||
| EBC Configuration Register - EBC0_CFG
|
||||
+----------------------------------------------------------------------------*/
|
||||
/* External Bus Three-State Control */
|
||||
#define EBC0_CFG_EBTC_DRIVEN 0x80000000
|
||||
/* Device-Paced Time-out Disable */
|
||||
#define EBC0_CFG_PTD_ENABLED 0x00000000
|
||||
/* Ready Timeout Count */
|
||||
#define EBC0_CFG_RTC_MASK 0x38000000
|
||||
#define EBC0_CFG_RTC_16PERCLK 0x00000000
|
||||
#define EBC0_CFG_RTC_32PERCLK 0x08000000
|
||||
#define EBC0_CFG_RTC_64PERCLK 0x10000000
|
||||
#define EBC0_CFG_RTC_128PERCLK 0x18000000
|
||||
#define EBC0_CFG_RTC_256PERCLK 0x20000000
|
||||
#define EBC0_CFG_RTC_512PERCLK 0x28000000
|
||||
#define EBC0_CFG_RTC_1024PERCLK 0x30000000
|
||||
#define EBC0_CFG_RTC_2048PERCLK 0x38000000
|
||||
/* External Master Priority Low */
|
||||
#define EBC0_CFG_EMPL_LOW 0x00000000
|
||||
#define EBC0_CFG_EMPL_MEDIUM_LOW 0x02000000
|
||||
#define EBC0_CFG_EMPL_MEDIUM_HIGH 0x04000000
|
||||
#define EBC0_CFG_EMPL_HIGH 0x06000000
|
||||
/* External Master Priority High */
|
||||
#define EBC0_CFG_EMPH_LOW 0x00000000
|
||||
#define EBC0_CFG_EMPH_MEDIUM_LOW 0x00800000
|
||||
#define EBC0_CFG_EMPH_MEDIUM_HIGH 0x01000000
|
||||
#define EBC0_CFG_EMPH_HIGH 0x01800000
|
||||
/* Chip Select Three-State Control */
|
||||
#define EBC0_CFG_CSTC_DRIVEN 0x00400000
|
||||
/* Burst Prefetch */
|
||||
#define EBC0_CFG_BPF_ONEDW 0x00000000
|
||||
#define EBC0_CFG_BPF_TWODW 0x00100000
|
||||
#define EBC0_CFG_BPF_FOURDW 0x00200000
|
||||
/* External Master Size */
|
||||
#define EBC0_CFG_EMS_8BIT 0x00000000
|
||||
/* Power Management Enable */
|
||||
#define EBC0_CFG_PME_DISABLED 0x00000000
|
||||
#define EBC0_CFG_PME_ENABLED 0x00020000
|
||||
/* Power Management Timer */
|
||||
#define EBC0_CFG_PMT_ENCODE(n) ((((unsigned long)(n))&0x1F)<<12)
|
||||
|
||||
#define SDR0_USB0 0x0320 /* USB Control Register */
|
||||
137
board/amcc/sequoia/u-boot-nand.lds
Normal file
137
board/amcc/sequoia/u-boot-nand.lds
Normal file
@@ -0,0 +1,137 @@
|
||||
/*
|
||||
* (C) Copyright 2006
|
||||
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
OUTPUT_ARCH(powerpc)
|
||||
SEARCH_DIR(/lib); SEARCH_DIR(/usr/lib); SEARCH_DIR(/usr/local/lib); SEARCH_DIR(/usr/local/powerpc-any-elf/lib);
|
||||
SECTIONS
|
||||
{
|
||||
/* Read-only sections, merged into text segment: */
|
||||
. = + SIZEOF_HEADERS;
|
||||
.interp : { *(.interp) }
|
||||
.hash : { *(.hash) }
|
||||
.dynsym : { *(.dynsym) }
|
||||
.dynstr : { *(.dynstr) }
|
||||
.rel.text : { *(.rel.text) }
|
||||
.rela.text : { *(.rela.text) }
|
||||
.rel.data : { *(.rel.data) }
|
||||
.rela.data : { *(.rela.data) }
|
||||
.rel.rodata : { *(.rel.rodata) }
|
||||
.rela.rodata : { *(.rela.rodata) }
|
||||
.rel.got : { *(.rel.got) }
|
||||
.rela.got : { *(.rela.got) }
|
||||
.rel.ctors : { *(.rel.ctors) }
|
||||
.rela.ctors : { *(.rela.ctors) }
|
||||
.rel.dtors : { *(.rel.dtors) }
|
||||
.rela.dtors : { *(.rela.dtors) }
|
||||
.rel.bss : { *(.rel.bss) }
|
||||
.rela.bss : { *(.rela.bss) }
|
||||
.rel.plt : { *(.rel.plt) }
|
||||
.rela.plt : { *(.rela.plt) }
|
||||
.init : { *(.init) }
|
||||
.plt : { *(.plt) }
|
||||
.text :
|
||||
{
|
||||
/* WARNING - the following is hand-optimized to fit within */
|
||||
/* the sector layout of our flash chips! XXX FIXME XXX */
|
||||
|
||||
cpu/ppc4xx/start.o (.text)
|
||||
|
||||
/* Align to next NAND block */
|
||||
. = ALIGN(0x4000);
|
||||
common/environment.o (.ppcenv)
|
||||
/* Keep some space here for redundant env and potential bad env blocks */
|
||||
. = ALIGN(0x10000);
|
||||
|
||||
*(.text)
|
||||
*(.fixup)
|
||||
*(.got1)
|
||||
}
|
||||
_etext = .;
|
||||
PROVIDE (etext = .);
|
||||
.rodata :
|
||||
{
|
||||
*(.rodata)
|
||||
*(.rodata1)
|
||||
*(.rodata.str1.4)
|
||||
}
|
||||
.fini : { *(.fini) } =0
|
||||
.ctors : { *(.ctors) }
|
||||
.dtors : { *(.dtors) }
|
||||
|
||||
/* Read-write section, merged into data segment: */
|
||||
. = (. + 0x00FF) & 0xFFFFFF00;
|
||||
_erotext = .;
|
||||
PROVIDE (erotext = .);
|
||||
.reloc :
|
||||
{
|
||||
*(.got)
|
||||
_GOT2_TABLE_ = .;
|
||||
*(.got2)
|
||||
_FIXUP_TABLE_ = .;
|
||||
*(.fixup)
|
||||
}
|
||||
__got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >>2;
|
||||
__fixup_entries = (. - _FIXUP_TABLE_)>>2;
|
||||
|
||||
.data :
|
||||
{
|
||||
*(.data)
|
||||
*(.data1)
|
||||
*(.sdata)
|
||||
*(.sdata2)
|
||||
*(.dynamic)
|
||||
CONSTRUCTORS
|
||||
}
|
||||
_edata = .;
|
||||
PROVIDE (edata = .);
|
||||
|
||||
. = .;
|
||||
__u_boot_cmd_start = .;
|
||||
.u_boot_cmd : { *(.u_boot_cmd) }
|
||||
__u_boot_cmd_end = .;
|
||||
|
||||
|
||||
. = .;
|
||||
__start___ex_table = .;
|
||||
__ex_table : { *(__ex_table) }
|
||||
__stop___ex_table = .;
|
||||
|
||||
. = ALIGN(256);
|
||||
__init_begin = .;
|
||||
.text.init : { *(.text.init) }
|
||||
.data.init : { *(.data.init) }
|
||||
. = ALIGN(256);
|
||||
__init_end = .;
|
||||
|
||||
__bss_start = .;
|
||||
.bss :
|
||||
{
|
||||
*(.sbss) *(.scommon)
|
||||
*(.dynbss)
|
||||
*(.bss)
|
||||
*(COMMON)
|
||||
}
|
||||
|
||||
_end = . ;
|
||||
PROVIDE (end = .);
|
||||
}
|
||||
145
board/amcc/sequoia/u-boot.lds
Normal file
145
board/amcc/sequoia/u-boot.lds
Normal file
@@ -0,0 +1,145 @@
|
||||
/*
|
||||
* (C) Copyright 2002
|
||||
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
OUTPUT_ARCH(powerpc)
|
||||
SEARCH_DIR(/lib); SEARCH_DIR(/usr/lib); SEARCH_DIR(/usr/local/lib); SEARCH_DIR(/usr/local/powerpc-any-elf/lib);
|
||||
/* Do we need any of these for elf?
|
||||
__DYNAMIC = 0; */
|
||||
SECTIONS
|
||||
{
|
||||
.resetvec 0xFFFFFFFC :
|
||||
{
|
||||
*(.resetvec)
|
||||
} = 0xffff
|
||||
|
||||
.bootpg 0xFFFFF000 :
|
||||
{
|
||||
cpu/ppc4xx/start.o (.bootpg)
|
||||
} = 0xffff
|
||||
|
||||
/* Read-only sections, merged into text segment: */
|
||||
. = + SIZEOF_HEADERS;
|
||||
.interp : { *(.interp) }
|
||||
.hash : { *(.hash) }
|
||||
.dynsym : { *(.dynsym) }
|
||||
.dynstr : { *(.dynstr) }
|
||||
.rel.text : { *(.rel.text) }
|
||||
.rela.text : { *(.rela.text) }
|
||||
.rel.data : { *(.rel.data) }
|
||||
.rela.data : { *(.rela.data) }
|
||||
.rel.rodata : { *(.rel.rodata) }
|
||||
.rela.rodata : { *(.rela.rodata) }
|
||||
.rel.got : { *(.rel.got) }
|
||||
.rela.got : { *(.rela.got) }
|
||||
.rel.ctors : { *(.rel.ctors) }
|
||||
.rela.ctors : { *(.rela.ctors) }
|
||||
.rel.dtors : { *(.rel.dtors) }
|
||||
.rela.dtors : { *(.rela.dtors) }
|
||||
.rel.bss : { *(.rel.bss) }
|
||||
.rela.bss : { *(.rela.bss) }
|
||||
.rel.plt : { *(.rel.plt) }
|
||||
.rela.plt : { *(.rela.plt) }
|
||||
.init : { *(.init) }
|
||||
.plt : { *(.plt) }
|
||||
.text :
|
||||
{
|
||||
/* WARNING - the following is hand-optimized to fit within */
|
||||
/* the sector layout of our flash chips! XXX FIXME XXX */
|
||||
|
||||
cpu/ppc4xx/start.o (.text)
|
||||
|
||||
*(.text)
|
||||
*(.fixup)
|
||||
*(.got1)
|
||||
}
|
||||
_etext = .;
|
||||
PROVIDE (etext = .);
|
||||
.rodata :
|
||||
{
|
||||
*(.rodata)
|
||||
*(.rodata1)
|
||||
*(.rodata.str1.4)
|
||||
}
|
||||
.fini : { *(.fini) } =0
|
||||
.ctors : { *(.ctors) }
|
||||
.dtors : { *(.dtors) }
|
||||
|
||||
/* Read-write section, merged into data segment: */
|
||||
. = (. + 0x00FF) & 0xFFFFFF00;
|
||||
_erotext = .;
|
||||
PROVIDE (erotext = .);
|
||||
.reloc :
|
||||
{
|
||||
*(.got)
|
||||
_GOT2_TABLE_ = .;
|
||||
*(.got2)
|
||||
_FIXUP_TABLE_ = .;
|
||||
*(.fixup)
|
||||
}
|
||||
__got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >>2;
|
||||
__fixup_entries = (. - _FIXUP_TABLE_)>>2;
|
||||
|
||||
.data :
|
||||
{
|
||||
*(.data)
|
||||
*(.data1)
|
||||
*(.sdata)
|
||||
*(.sdata2)
|
||||
*(.dynamic)
|
||||
CONSTRUCTORS
|
||||
}
|
||||
_edata = .;
|
||||
PROVIDE (edata = .);
|
||||
|
||||
. = .;
|
||||
__u_boot_cmd_start = .;
|
||||
.u_boot_cmd : { *(.u_boot_cmd) }
|
||||
__u_boot_cmd_end = .;
|
||||
|
||||
|
||||
. = .;
|
||||
__start___ex_table = .;
|
||||
__ex_table : { *(__ex_table) }
|
||||
__stop___ex_table = .;
|
||||
|
||||
. = ALIGN(256);
|
||||
__init_begin = .;
|
||||
.text.init : { *(.text.init) }
|
||||
.data.init : { *(.data.init) }
|
||||
. = ALIGN(256);
|
||||
__init_end = .;
|
||||
|
||||
__bss_start = .;
|
||||
.bss :
|
||||
{
|
||||
*(.sbss) *(.scommon)
|
||||
*(.dynbss)
|
||||
*(.bss)
|
||||
*(COMMON)
|
||||
}
|
||||
|
||||
ppcenv_assert = ASSERT(. < 0xFFFF8000, ".bss section too big, overlaps .ppcenv section. Please update your confguration: CFG_MONITOR_BASE, CFG_MONITOR_LEN and TEXT_BASE may need to be modified.");
|
||||
|
||||
_end = . ;
|
||||
PROVIDE (end = .);
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2000
|
||||
# (C) Copyright 2000-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,12 +23,16 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o flash.o
|
||||
COBJS = $(BOARD).o flash.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -38,9 +42,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -99,7 +99,7 @@ void sdram_init(void)
|
||||
*/
|
||||
long int initdram(int board_type)
|
||||
{
|
||||
return spd_sdram(0);
|
||||
return spd_sdram();
|
||||
}
|
||||
|
||||
int testdram(void)
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2002
|
||||
# (C) Copyright 2002-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,13 +23,17 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o
|
||||
COBJS = $(BOARD).o
|
||||
SOBJS = init.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -39,9 +43,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -24,6 +24,8 @@
|
||||
#include <asm/processor.h>
|
||||
#include <spd_sdram.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
extern flash_info_t flash_info[CFG_MAX_FLASH_BANKS]; /* info for FLASH chips */
|
||||
|
||||
int board_early_init_f(void)
|
||||
@@ -77,8 +79,8 @@ int board_early_init_f(void)
|
||||
out32(GPIO1_ISR2L, in32(GPIO1_ISR2L) | 0x00010000);
|
||||
|
||||
/* external interrupts IRQ0...3 */
|
||||
out32(GPIO1_TCR, in32(GPIO1_TCR) & ~0x0f000000);
|
||||
out32(GPIO1_TSRL, in32(GPIO1_TSRL) & ~0x00005500);
|
||||
out32(GPIO1_TCR, in32(GPIO1_TCR) & ~0x00f00000);
|
||||
out32(GPIO1_TSRL, in32(GPIO1_TSRL) & ~0x0000ff00);
|
||||
out32(GPIO1_ISR1L, in32(GPIO1_ISR1L) | 0x00005500);
|
||||
|
||||
#if 0 /* test-only */
|
||||
@@ -136,7 +138,6 @@ int board_early_init_f(void)
|
||||
|
||||
int misc_init_r (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
uint pbcr;
|
||||
int size_val = 0;
|
||||
|
||||
@@ -312,13 +313,13 @@ void sdram_init(void)
|
||||
mtsdram(mem_tr0, 0x410a4012); /* ?? */
|
||||
mtsdram(mem_rtr, 0x04080000); /* ?? */
|
||||
mtsdram(mem_cfg1, 0x00000000); /* Self-refresh exit, disable PM */
|
||||
mtsdram(mem_cfg0, 0x34000000); /* Disable EEC */
|
||||
mtsdram(mem_cfg0, 0x30000000); /* Disable EEC */
|
||||
udelay(400); /* Delay 200 usecs (min) */
|
||||
|
||||
/*--------------------------------------------------------------------
|
||||
* Enable the controller, then wait for DCEN to complete
|
||||
*------------------------------------------------------------------*/
|
||||
mtsdram(mem_cfg0, 0x84000000); /* Enable */
|
||||
mtsdram(mem_cfg0, 0x80000000); /* Enable */
|
||||
|
||||
for (;;) {
|
||||
mfsdram(mem_mcsts, reg);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# (C) Copyright 2002
|
||||
# (C) Copyright 2002-2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
@@ -23,13 +23,17 @@
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = lib$(BOARD).a
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
OBJS = $(BOARD).o
|
||||
COBJS = $(BOARD).o
|
||||
SOBJS = init.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(OBJS) $(SOBJS)
|
||||
$(AR) crv $@ $(OBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
@@ -39,9 +43,9 @@ distclean: clean
|
||||
|
||||
#########################################################################
|
||||
|
||||
.depend: Makefile $(SOBJS:.o=.S) $(OBJS:.o=.c)
|
||||
$(CC) -M $(CFLAGS) $(SOBJS:.o=.S) $(OBJS:.o=.c) > $@
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude .depend
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
|
||||
@@ -24,6 +24,8 @@
|
||||
#include <asm/processor.h>
|
||||
#include <spd_sdram.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
extern flash_info_t flash_info[CFG_MAX_FLASH_BANKS]; /* info for FLASH chips */
|
||||
|
||||
int board_early_init_f(void)
|
||||
@@ -77,8 +79,8 @@ int board_early_init_f(void)
|
||||
out32(GPIO1_ISR2L, in32(GPIO1_ISR2L) | 0x00010000);
|
||||
|
||||
/* external interrupts IRQ0...3 */
|
||||
out32(GPIO1_TCR, in32(GPIO1_TCR) & ~0x0f000000);
|
||||
out32(GPIO1_TSRL, in32(GPIO1_TSRL) & ~0x00005500);
|
||||
out32(GPIO1_TCR, in32(GPIO1_TCR) & ~0x00f00000);
|
||||
out32(GPIO1_TSRL, in32(GPIO1_TSRL) & ~0x0000ff00);
|
||||
out32(GPIO1_ISR1L, in32(GPIO1_ISR1L) | 0x00005500);
|
||||
|
||||
/*setup USB 2.0 */
|
||||
@@ -132,7 +134,6 @@ int board_early_init_f(void)
|
||||
|
||||
int misc_init_r (void)
|
||||
{
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
uint pbcr;
|
||||
int size_val = 0;
|
||||
|
||||
@@ -308,13 +309,13 @@ void sdram_init(void)
|
||||
mtsdram(mem_tr0, 0x410a4012); /* ?? */
|
||||
mtsdram(mem_rtr, 0x04080000); /* ?? */
|
||||
mtsdram(mem_cfg1, 0x00000000); /* Self-refresh exit, disable PM */
|
||||
mtsdram(mem_cfg0, 0x34000000); /* Disable EEC */
|
||||
mtsdram(mem_cfg0, 0x30000000); /* Disable EEC */
|
||||
udelay(400); /* Delay 200 usecs (min) */
|
||||
|
||||
/*--------------------------------------------------------------------
|
||||
* Enable the controller, then wait for DCEN to complete
|
||||
*------------------------------------------------------------------*/
|
||||
mtsdram(mem_cfg0, 0x84000000); /* Enable */
|
||||
mtsdram(mem_cfg0, 0x80000000); /* Enable */
|
||||
|
||||
for (;;) {
|
||||
mfsdram(mem_mcsts, reg);
|
||||
|
||||
51
board/amcc/yucca/Makefile
Normal file
51
board/amcc/yucca/Makefile
Normal file
@@ -0,0 +1,51 @@
|
||||
#
|
||||
# (C) Copyright 2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
include $(TOPDIR)/config.mk
|
||||
|
||||
LIB = $(obj)lib$(BOARD).a
|
||||
|
||||
COBJS = $(BOARD).o flash.o cmd_yucca.o
|
||||
SOBJS = init.o
|
||||
|
||||
SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
|
||||
OBJS := $(addprefix $(obj),$(COBJS))
|
||||
SOBJS := $(addprefix $(obj),$(SOBJS))
|
||||
|
||||
$(LIB): $(obj).depend $(OBJS) $(SOBJS)
|
||||
$(AR) $(ARFLAGS) $@ $(OBJS)
|
||||
|
||||
clean:
|
||||
rm -f $(SOBJS) $(OBJS)
|
||||
|
||||
distclean: clean
|
||||
rm -f $(LIB) core *.bak .depend *~
|
||||
|
||||
#########################################################################
|
||||
|
||||
# defines $(obj).depend target
|
||||
include $(SRCTREE)/rules.mk
|
||||
|
||||
sinclude $(obj).depend
|
||||
|
||||
#########################################################################
|
||||
288
board/amcc/yucca/cmd_yucca.c
Normal file
288
board/amcc/yucca/cmd_yucca.c
Normal file
@@ -0,0 +1,288 @@
|
||||
/*
|
||||
* (C) Copyright 2001
|
||||
* Denis Peter, MPL AG Switzerland, d.peter@mpl.ch
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*
|
||||
* hacked for evb440spe
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <command.h>
|
||||
#include "yucca.h"
|
||||
#include <i2c.h>
|
||||
#include <asm/byteorder.h>
|
||||
|
||||
extern void print_evb440spe_info(void);
|
||||
static int setBootStrapClock(cmd_tbl_t *cmdtp, int incrflag,
|
||||
int flag, int argc, char *argv[]);
|
||||
|
||||
extern int cmd_get_data_size(char* arg, int default_size);
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
int do_evb440spe(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
|
||||
{
|
||||
return setBootStrapClock (cmdtp, 1, flag, argc, argv);
|
||||
}
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* Modify memory.
|
||||
*
|
||||
* Syntax:
|
||||
* evb440spe wrclk prom0,prom1
|
||||
*/
|
||||
static int setBootStrapClock(cmd_tbl_t *cmdtp, int incrflag, int flag,
|
||||
int argc, char *argv[])
|
||||
{
|
||||
uchar chip;
|
||||
ulong data;
|
||||
int nbytes;
|
||||
extern char console_buffer[];
|
||||
|
||||
char sysClock[4];
|
||||
char cpuClock[4];
|
||||
char plbClock[4];
|
||||
char pcixClock[4];
|
||||
|
||||
if (argc < 3) {
|
||||
printf ("Usage:\n%s\n", cmdtp->usage);
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (strcmp(argv[2], "prom0") == 0)
|
||||
chip = IIC0_BOOTPROM_ADDR;
|
||||
else
|
||||
chip = IIC0_ALT_BOOTPROM_ADDR;
|
||||
|
||||
do {
|
||||
printf("enter sys clock frequency 33 or 66 Mhz or quit to abort\n");
|
||||
nbytes = readline (" ? ");
|
||||
|
||||
if (strcmp(console_buffer, "quit") == 0)
|
||||
return 0;
|
||||
|
||||
if ((strcmp(console_buffer, "33") != 0) &
|
||||
(strcmp(console_buffer, "66") != 0))
|
||||
nbytes=0;
|
||||
|
||||
strcpy(sysClock, console_buffer);
|
||||
|
||||
} while (nbytes == 0);
|
||||
|
||||
do {
|
||||
if (strcmp(sysClock, "66") == 0) {
|
||||
printf("enter cpu clock frequency 400, 533 Mhz or quit to abort\n");
|
||||
} else {
|
||||
#ifdef CONFIG_STRESS
|
||||
printf("enter cpu clock frequency 400, 500, 533, 667 Mhz or quit to abort\n");
|
||||
#else
|
||||
printf("enter cpu clock frequency 400, 500, 533 Mhz or quit to abort\n");
|
||||
#endif
|
||||
}
|
||||
nbytes = readline (" ? ");
|
||||
|
||||
if (strcmp(console_buffer, "quit") == 0)
|
||||
return 0;
|
||||
|
||||
if (strcmp(sysClock, "66") == 0) {
|
||||
if ((strcmp(console_buffer, "400") != 0) &
|
||||
(strcmp(console_buffer, "533") != 0)
|
||||
#ifdef CONFIG_STRESS
|
||||
& (strcmp(console_buffer, "667") != 0)
|
||||
#endif
|
||||
) {
|
||||
nbytes = 0;
|
||||
}
|
||||
} else {
|
||||
if ((strcmp(console_buffer, "400") != 0) &
|
||||
(strcmp(console_buffer, "500") != 0) &
|
||||
(strcmp(console_buffer, "533") != 0)
|
||||
#ifdef CONFIG_STRESS
|
||||
& (strcmp(console_buffer, "667") != 0)
|
||||
#endif
|
||||
) {
|
||||
nbytes = 0;
|
||||
}
|
||||
}
|
||||
|
||||
strcpy(cpuClock, console_buffer);
|
||||
|
||||
} while (nbytes == 0);
|
||||
|
||||
if (strcmp(cpuClock, "500") == 0){
|
||||
strcpy(plbClock, "166");
|
||||
} else if (strcmp(cpuClock, "533") == 0){
|
||||
strcpy(plbClock, "133");
|
||||
} else {
|
||||
do {
|
||||
if (strcmp(cpuClock, "400") == 0)
|
||||
printf("enter plb clock frequency 100, 133 Mhz or quit to abort\n");
|
||||
|
||||
#ifdef CONFIG_STRESS
|
||||
if (strcmp(cpuClock, "667") == 0)
|
||||
printf("enter plb clock frequency 133, 166 Mhz or quit to abort\n");
|
||||
|
||||
#endif
|
||||
nbytes = readline (" ? ");
|
||||
|
||||
if (strcmp(console_buffer, "quit") == 0)
|
||||
return 0;
|
||||
|
||||
if (strcmp(cpuClock, "400") == 0) {
|
||||
if ((strcmp(console_buffer, "100") != 0) &
|
||||
(strcmp(console_buffer, "133") != 0))
|
||||
nbytes = 0;
|
||||
}
|
||||
#ifdef CONFIG_STRESS
|
||||
if (strcmp(cpuClock, "667") == 0) {
|
||||
if ((strcmp(console_buffer, "133") != 0) &
|
||||
(strcmp(console_buffer, "166") != 0))
|
||||
nbytes = 0;
|
||||
}
|
||||
#endif
|
||||
strcpy(plbClock, console_buffer);
|
||||
|
||||
} while (nbytes == 0);
|
||||
}
|
||||
|
||||
do {
|
||||
printf("enter Pci-X clock frequency 33, 66, 100 or 133 Mhz or quit to abort\n");
|
||||
nbytes = readline (" ? ");
|
||||
|
||||
if (strcmp(console_buffer, "quit") == 0)
|
||||
return 0;
|
||||
|
||||
if ((strcmp(console_buffer, "33") != 0) &
|
||||
(strcmp(console_buffer, "66") != 0) &
|
||||
(strcmp(console_buffer, "100") != 0) &
|
||||
(strcmp(console_buffer, "133") != 0)) {
|
||||
nbytes = 0;
|
||||
}
|
||||
strcpy(pcixClock, console_buffer);
|
||||
|
||||
} while (nbytes == 0);
|
||||
|
||||
printf("\nsys clk = %sMhz\n", sysClock);
|
||||
printf("cpu clk = %sMhz\n", cpuClock);
|
||||
printf("plb clk = %sMhz\n", plbClock);
|
||||
printf("Pci-X clk = %sMhz\n", pcixClock);
|
||||
|
||||
do {
|
||||
printf("\npress [y] to write I2C bootstrap \n");
|
||||
printf("or [n] to abort. \n");
|
||||
printf("Don't forget to set board switches \n");
|
||||
printf("according to your choice before re-starting \n");
|
||||
printf("(refer to 440spe_uboot_kit_um_1_01.pdf) \n");
|
||||
|
||||
nbytes = readline (" ? ");
|
||||
if (strcmp(console_buffer, "n") == 0)
|
||||
return 0;
|
||||
|
||||
} while (nbytes == 0);
|
||||
|
||||
if (strcmp(sysClock, "33") == 0) {
|
||||
if ((strcmp(cpuClock, "400") == 0) &
|
||||
(strcmp(plbClock, "100") == 0))
|
||||
data = 0x8678c206;
|
||||
|
||||
if ((strcmp(cpuClock, "400") == 0) &
|
||||
(strcmp(plbClock, "133") == 0))
|
||||
data = 0x8678c2c6;
|
||||
|
||||
if ((strcmp(cpuClock, "500") == 0))
|
||||
data = 0x8778f2c6;
|
||||
|
||||
if ((strcmp(cpuClock, "533") == 0))
|
||||
data = 0x87790252;
|
||||
|
||||
#ifdef CONFIG_STRESS
|
||||
if ((strcmp(cpuClock, "667") == 0) &
|
||||
(strcmp(plbClock, "133") == 0))
|
||||
data = 0x87794256;
|
||||
|
||||
if ((strcmp(cpuClock, "667") == 0) &
|
||||
(strcmp(plbClock, "166") == 0))
|
||||
data = 0x87794206;
|
||||
|
||||
#endif
|
||||
}
|
||||
if (strcmp(sysClock, "66") == 0) {
|
||||
if ((strcmp(cpuClock, "400") == 0) &
|
||||
(strcmp(plbClock, "100") == 0))
|
||||
data = 0x84706206;
|
||||
|
||||
if ((strcmp(cpuClock, "400") == 0) &
|
||||
(strcmp(plbClock, "133") == 0))
|
||||
data = 0x847062c6;
|
||||
|
||||
if ((strcmp(cpuClock, "533") == 0))
|
||||
data = 0x85708206;
|
||||
|
||||
#ifdef CONFIG_STRESS
|
||||
if ((strcmp(cpuClock, "667") == 0) &
|
||||
(strcmp(plbClock, "133") == 0))
|
||||
data = 0x8570a256;
|
||||
|
||||
if ((strcmp(cpuClock, "667") == 0) &
|
||||
(strcmp(plbClock, "166") == 0))
|
||||
data = 0x8570a206;
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifdef DEBUG
|
||||
printf(" pin strap0 to write in i2c = %x\n", data);
|
||||
#endif /* DEBUG */
|
||||
|
||||
if (i2c_write(chip, 0, 1, (uchar *)&data, 4) != 0)
|
||||
printf("Error writing strap0 in %s\n", argv[2]);
|
||||
|
||||
if (strcmp(pcixClock, "33") == 0)
|
||||
data = 0x00000701;
|
||||
|
||||
if (strcmp(pcixClock, "66") == 0)
|
||||
data = 0x00000601;
|
||||
|
||||
if (strcmp(pcixClock, "100") == 0)
|
||||
data = 0x00000501;
|
||||
|
||||
if (strcmp(pcixClock, "133") == 0)
|
||||
data = 0x00000401;
|
||||
|
||||
if (strcmp(plbClock, "166") == 0)
|
||||
data = data | 0x05950000;
|
||||
else
|
||||
data = data | 0x05A50000;
|
||||
|
||||
#ifdef DEBUG
|
||||
printf(" pin strap1 to write in i2c = %x\n", data);
|
||||
#endif /* DEBUG */
|
||||
|
||||
udelay(1000);
|
||||
if (i2c_write(chip, 4, 1, (uchar *)&data, 4) != 0)
|
||||
printf("Error writing strap1 in %s\n", argv[2]);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
U_BOOT_CMD(
|
||||
evb440spe, 3, 1, do_evb440spe,
|
||||
"evb440spe - program the serial device strap\n",
|
||||
"wrclk [prom0|prom1] - program the serial device strap\n"
|
||||
);
|
||||
42
board/amcc/yucca/config.mk
Normal file
42
board/amcc/yucca/config.mk
Normal file
@@ -0,0 +1,42 @@
|
||||
#
|
||||
# (C) Copyright 2006
|
||||
# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
#
|
||||
# See file CREDITS for list of people who contributed to this
|
||||
# project.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation; either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
# MA 02111-1307 USA
|
||||
#
|
||||
|
||||
#
|
||||
# AMCC 440SPe Reference Platform (yucca) board
|
||||
#
|
||||
|
||||
ifeq ($(ramsym),1)
|
||||
TEXT_BASE = 0x07FD0000
|
||||
else
|
||||
TEXT_BASE = 0xfffb0000
|
||||
endif
|
||||
|
||||
PLATFORM_CPPFLAGS += -DCONFIG_440=1
|
||||
|
||||
ifeq ($(debug),1)
|
||||
PLATFORM_CPPFLAGS += -DDEBUG
|
||||
endif
|
||||
|
||||
ifeq ($(dbcr),1)
|
||||
PLATFORM_CPPFLAGS += -DCFG_INIT_DBCR=0x8cff0000
|
||||
endif
|
||||
1054
board/amcc/yucca/flash.c
Normal file
1054
board/amcc/yucca/flash.c
Normal file
File diff suppressed because it is too large
Load Diff
152
board/amcc/yucca/init.S
Normal file
152
board/amcc/yucca/init.S
Normal file
@@ -0,0 +1,152 @@
|
||||
/*
|
||||
* Copyright (C) 2002 Scott McNutt <smcnutt@artesyncp.com>
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
/* port to AMCC 440SPE evaluatioon board - SG April 12,2005 */
|
||||
|
||||
#include <ppc_asm.tmpl>
|
||||
#include <config.h>
|
||||
|
||||
/* General */
|
||||
#define TLB_VALID 0x00000200
|
||||
|
||||
/* Supported page sizes */
|
||||
|
||||
#define SZ_1K 0x00000000
|
||||
#define SZ_4K 0x00000010
|
||||
#define SZ_16K 0x00000020
|
||||
#define SZ_64K 0x00000030
|
||||
#define SZ_256K 0x00000040
|
||||
#define SZ_1M 0x00000050
|
||||
#define SZ_16M 0x00000070
|
||||
#define SZ_256M 0x00000090
|
||||
|
||||
/* Storage attributes */
|
||||
#define SA_W 0x00000800 /* Write-through */
|
||||
#define SA_I 0x00000400 /* Caching inhibited */
|
||||
#define SA_M 0x00000200 /* Memory coherence */
|
||||
#define SA_G 0x00000100 /* Guarded */
|
||||
#define SA_E 0x00000080 /* Endian */
|
||||
|
||||
/* Access control */
|
||||
#define AC_X 0x00000024 /* Execute */
|
||||
#define AC_W 0x00000012 /* Write */
|
||||
#define AC_R 0x00000009 /* Read */
|
||||
|
||||
/* Some handy macros */
|
||||
|
||||
#define EPN(e) ((e) & 0xfffffc00)
|
||||
#define TLB0(epn,sz) ((EPN((epn)) | (sz) | TLB_VALID ))
|
||||
#define TLB1(rpn,erpn) (((rpn) & 0xfffffc00) | (erpn))
|
||||
#define TLB2(a) ((a) & 0x00000fbf)
|
||||
|
||||
#define tlbtab_start\
|
||||
mflr r1 ;\
|
||||
bl 0f ;
|
||||
|
||||
#define tlbtab_end\
|
||||
.long 0, 0, 0 ;\
|
||||
0: mflr r0 ;\
|
||||
mtlr r1 ;\
|
||||
blr ;
|
||||
|
||||
#define tlbentry(epn,sz,rpn,erpn,attr)\
|
||||
.long TLB0(epn,sz),TLB1(rpn,erpn),TLB2(attr)
|
||||
|
||||
/**************************************************************************
|
||||
* TLB TABLE
|
||||
*
|
||||
* This table is used by the cpu boot code to setup the initial tlb
|
||||
* entries. Rather than make broad assumptions in the cpu source tree,
|
||||
* this table lets each board set things up however they like.
|
||||
*
|
||||
* Pointer to the table is returned in r1
|
||||
*
|
||||
*************************************************************************/
|
||||
|
||||
.section .bootpg,"ax"
|
||||
|
||||
/**************************************************************************
|
||||
* TLB table for revA
|
||||
*************************************************************************/
|
||||
.globl tlbtabA
|
||||
tlbtabA:
|
||||
tlbtab_start
|
||||
tlbentry(0xfff00000, SZ_16M, 0xfff00000, 4, AC_R|AC_W|AC_X|SA_G)
|
||||
|
||||
tlbentry(CFG_SDRAM_BASE, SZ_256M, 0x00000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
tlbentry(CFG_SDRAM_BASE + 0x10000000, SZ_256M, 0x10000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
tlbentry(CFG_SDRAM_BASE + 0x20000000, SZ_256M, 0x20000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
tlbentry(CFG_SDRAM_BASE + 0x30000000, SZ_256M, 0x30000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
|
||||
tlbentry(CFG_ISRAM_BASE, SZ_256K, 0x00000000, 4, AC_R|AC_W|AC_X|SA_I)
|
||||
tlbentry(CFG_FPGA_BASE, SZ_1K, 0xE2000000, 4,AC_R|AC_W|SA_I)
|
||||
|
||||
tlbentry(CFG_OPER_FLASH, SZ_16M, 0xE7000000, 4,AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
tlbentry(CFG_PERIPHERAL_BASE, SZ_4K, 0xF0000000, 4, AC_R|AC_W|SA_G|SA_I)
|
||||
|
||||
tlbentry(CFG_PCI_BASE, SZ_256M, 0x00000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCI_MEMBASE, SZ_256M, 0x10000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE_MEMBASE, SZ_256M, 0xB0000000, 0xD, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE_BASE, SZ_16K, 0x20000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
|
||||
tlbentry(CFG_PCIE0_CFGBASE, SZ_1K, 0x40000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE1_CFGBASE, SZ_1K, 0x80000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE2_CFGBASE, SZ_1K, 0xC0000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE0_XCFGBASE, SZ_1K, 0x50000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE1_XCFGBASE, SZ_1K, 0x90000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE2_XCFGBASE, SZ_1K, 0xD0000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbtab_end
|
||||
|
||||
/**************************************************************************
|
||||
* TLB table for revB
|
||||
*
|
||||
* Notice: revB of the 440SPe chip is very strict about PLB real addresses
|
||||
* and ranges to be mapped for config space: it seems to only work with
|
||||
* d_nnnn_nnnn range (hangs the core upon config transaction attempts when
|
||||
* set otherwise) while revA uses c_nnnn_nnnn.
|
||||
*************************************************************************/
|
||||
.globl tlbtabB
|
||||
tlbtabB:
|
||||
tlbtab_start
|
||||
tlbentry(0xfff00000, SZ_16M, 0xfff00000, 4, AC_R|AC_W|AC_X|SA_G)
|
||||
|
||||
tlbentry(CFG_SDRAM_BASE, SZ_256M, 0x00000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
tlbentry(CFG_SDRAM_BASE + 0x10000000, SZ_256M, 0x10000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
tlbentry(CFG_SDRAM_BASE + 0x20000000, SZ_256M, 0x20000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
tlbentry(CFG_SDRAM_BASE + 0x30000000, SZ_256M, 0x30000000, 0, AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
|
||||
tlbentry(CFG_ISRAM_BASE, SZ_256K, 0x00000000, 4, AC_R|AC_W|AC_X|SA_I)
|
||||
tlbentry(CFG_FPGA_BASE, SZ_1K, 0xE2000000, 4,AC_R|AC_W|SA_I)
|
||||
|
||||
tlbentry(CFG_OPER_FLASH, SZ_16M, 0xE7000000, 4,AC_R|AC_W|AC_X|SA_G|SA_I)
|
||||
tlbentry(CFG_PERIPHERAL_BASE, SZ_4K, 0xF0000000, 4, AC_R|AC_W|SA_G|SA_I)
|
||||
|
||||
tlbentry(CFG_PCI_BASE, SZ_256M, 0x00000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCI_MEMBASE, SZ_256M, 0x10000000, 0xC, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE_MEMBASE, SZ_256M, 0xB0000000, 0xD, AC_R|AC_W|SA_G|SA_I)
|
||||
|
||||
tlbentry(CFG_PCIE0_CFGBASE, SZ_1K, 0x00100000, 0xD, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE1_CFGBASE, SZ_1K, 0x20100000, 0xD, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE2_CFGBASE, SZ_1K, 0x40100000, 0xD, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE0_XCFGBASE, SZ_1K, 0x10000000, 0xD, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE1_XCFGBASE, SZ_1K, 0x30000000, 0xD, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbentry(CFG_PCIE2_XCFGBASE, SZ_1K, 0x50000000, 0xD, AC_R|AC_W|SA_G|SA_I)
|
||||
tlbtab_end
|
||||
157
board/amcc/yucca/u-boot.lds
Normal file
157
board/amcc/yucca/u-boot.lds
Normal file
@@ -0,0 +1,157 @@
|
||||
/*
|
||||
* (C) Copyright 2004
|
||||
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
OUTPUT_ARCH(powerpc)
|
||||
SEARCH_DIR(/lib); SEARCH_DIR(/usr/lib); SEARCH_DIR(/usr/local/lib); SEARCH_DIR(/usr/local/powerpc-any-elf/lib);
|
||||
/* Do we need any of these for elf?
|
||||
__DYNAMIC = 0; */
|
||||
SECTIONS
|
||||
{
|
||||
.resetvec 0xFFFFFFFC :
|
||||
{
|
||||
*(.resetvec)
|
||||
} = 0xffff
|
||||
|
||||
.bootpg 0xFFFFF000 :
|
||||
{
|
||||
cpu/ppc4xx/start.o (.bootpg)
|
||||
} = 0xffff
|
||||
|
||||
/* Read-only sections, merged into text segment: */
|
||||
. = + SIZEOF_HEADERS;
|
||||
.interp : { *(.interp) }
|
||||
.hash : { *(.hash) }
|
||||
.dynsym : { *(.dynsym) }
|
||||
.dynstr : { *(.dynstr) }
|
||||
.rel.text : { *(.rel.text) }
|
||||
.rela.text : { *(.rela.text) }
|
||||
.rel.data : { *(.rel.data) }
|
||||
.rela.data : { *(.rela.data) }
|
||||
.rel.rodata : { *(.rel.rodata) }
|
||||
.rela.rodata : { *(.rela.rodata) }
|
||||
.rel.got : { *(.rel.got) }
|
||||
.rela.got : { *(.rela.got) }
|
||||
.rel.ctors : { *(.rel.ctors) }
|
||||
.rela.ctors : { *(.rela.ctors) }
|
||||
.rel.dtors : { *(.rel.dtors) }
|
||||
.rela.dtors : { *(.rela.dtors) }
|
||||
.rel.bss : { *(.rel.bss) }
|
||||
.rela.bss : { *(.rela.bss) }
|
||||
.rel.plt : { *(.rel.plt) }
|
||||
.rela.plt : { *(.rela.plt) }
|
||||
.init : { *(.init) }
|
||||
.plt : { *(.plt) }
|
||||
.text :
|
||||
{
|
||||
/* WARNING - the following is hand-optimized to fit within */
|
||||
/* the sector layout of our flash chips! XXX FIXME XXX */
|
||||
|
||||
cpu/ppc4xx/start.o (.text)
|
||||
board/amcc/yucca/init.o (.text)
|
||||
cpu/ppc4xx/kgdb.o (.text)
|
||||
cpu/ppc4xx/traps.o (.text)
|
||||
cpu/ppc4xx/interrupts.o (.text)
|
||||
cpu/ppc4xx/serial.o (.text)
|
||||
cpu/ppc4xx/cpu_init.o (.text)
|
||||
cpu/ppc4xx/speed.o (.text)
|
||||
common/dlmalloc.o (.text)
|
||||
lib_generic/crc32.o (.text)
|
||||
lib_ppc/extable.o (.text)
|
||||
lib_generic/zlib.o (.text)
|
||||
|
||||
/* . = env_offset;*/
|
||||
/* common/environment.o(.text)*/
|
||||
|
||||
*(.text)
|
||||
*(.fixup)
|
||||
*(.got1)
|
||||
}
|
||||
_etext = .;
|
||||
PROVIDE (etext = .);
|
||||
.rodata :
|
||||
{
|
||||
*(.rodata)
|
||||
*(.rodata1)
|
||||
*(.rodata.str1.4)
|
||||
*(.eh_frame)
|
||||
}
|
||||
.fini : { *(.fini) } =0
|
||||
.ctors : { *(.ctors) }
|
||||
.dtors : { *(.dtors) }
|
||||
|
||||
/* Read-write section, merged into data segment: */
|
||||
. = (. + 0x00FF) & 0xFFFFFF00;
|
||||
_erotext = .;
|
||||
PROVIDE (erotext = .);
|
||||
.reloc :
|
||||
{
|
||||
*(.got)
|
||||
_GOT2_TABLE_ = .;
|
||||
*(.got2)
|
||||
_FIXUP_TABLE_ = .;
|
||||
*(.fixup)
|
||||
}
|
||||
__got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >>2;
|
||||
__fixup_entries = (. - _FIXUP_TABLE_)>>2;
|
||||
|
||||
.data :
|
||||
{
|
||||
*(.data)
|
||||
*(.data1)
|
||||
*(.sdata)
|
||||
*(.sdata2)
|
||||
*(.dynamic)
|
||||
CONSTRUCTORS
|
||||
}
|
||||
_edata = .;
|
||||
PROVIDE (edata = .);
|
||||
|
||||
. = .;
|
||||
__u_boot_cmd_start = .;
|
||||
.u_boot_cmd : { *(.u_boot_cmd) }
|
||||
__u_boot_cmd_end = .;
|
||||
|
||||
|
||||
. = .;
|
||||
__start___ex_table = .;
|
||||
__ex_table : { *(__ex_table) }
|
||||
__stop___ex_table = .;
|
||||
|
||||
. = ALIGN(256);
|
||||
__init_begin = .;
|
||||
.text.init : { *(.text.init) }
|
||||
.data.init : { *(.data.init) }
|
||||
. = ALIGN(256);
|
||||
__init_end = .;
|
||||
|
||||
__bss_start = .;
|
||||
.bss :
|
||||
{
|
||||
*(.sbss) *(.scommon)
|
||||
*(.dynbss)
|
||||
*(.bss)
|
||||
*(COMMON)
|
||||
}
|
||||
_end = . ;
|
||||
PROVIDE (end = .);
|
||||
}
|
||||
146
board/amcc/yucca/u-boot.lds.debug
Normal file
146
board/amcc/yucca/u-boot.lds.debug
Normal file
@@ -0,0 +1,146 @@
|
||||
/*
|
||||
* (C) Copyright 2002-2004
|
||||
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
OUTPUT_ARCH(powerpc)
|
||||
SEARCH_DIR(/lib); SEARCH_DIR(/usr/lib); SEARCH_DIR(/usr/local/lib); SEARCH_DIR(/usr/local/powerpc-any-elf/lib);
|
||||
/* Do we need any of these for elf?
|
||||
__DYNAMIC = 0; */
|
||||
SECTIONS
|
||||
{
|
||||
/* Read-only sections, merged into text segment: */
|
||||
. = + SIZEOF_HEADERS;
|
||||
.interp : { *(.interp) }
|
||||
.hash : { *(.hash) }
|
||||
.dynsym : { *(.dynsym) }
|
||||
.dynstr : { *(.dynstr) }
|
||||
.rel.text : { *(.rel.text) }
|
||||
.rela.text : { *(.rela.text) }
|
||||
.rel.data : { *(.rel.data) }
|
||||
.rela.data : { *(.rela.data) }
|
||||
.rel.rodata : { *(.rel.rodata) }
|
||||
.rela.rodata : { *(.rela.rodata) }
|
||||
.rel.got : { *(.rel.got) }
|
||||
.rela.got : { *(.rela.got) }
|
||||
.rel.ctors : { *(.rel.ctors) }
|
||||
.rela.ctors : { *(.rela.ctors) }
|
||||
.rel.dtors : { *(.rel.dtors) }
|
||||
.rela.dtors : { *(.rela.dtors) }
|
||||
.rel.bss : { *(.rel.bss) }
|
||||
.rela.bss : { *(.rela.bss) }
|
||||
.rel.plt : { *(.rel.plt) }
|
||||
.rela.plt : { *(.rela.plt) }
|
||||
.init : { *(.init) }
|
||||
.plt : { *(.plt) }
|
||||
.text :
|
||||
{
|
||||
/* WARNING - the following is hand-optimized to fit within */
|
||||
/* the sector layout of our flash chips! XXX FIXME XXX */
|
||||
|
||||
cpu/ppc4xx/start.o (.text)
|
||||
board/amcc/yucca/init.o (.text)
|
||||
cpu/ppc4xx/kgdb.o (.text)
|
||||
cpu/ppc4xx/traps.o (.text)
|
||||
cpu/ppc4xx/interrupts.o (.text)
|
||||
cpu/ppc4xx/serial.o (.text)
|
||||
cpu/ppc4xx/cpu_init.o (.text)
|
||||
cpu/ppc4xx/speed.o (.text)
|
||||
common/dlmalloc.o (.text)
|
||||
lib_generic/crc32.o (.text)
|
||||
lib_ppc/extable.o (.text)
|
||||
lib_generic/zlib.o (.text)
|
||||
|
||||
/* common/environment.o(.text) */
|
||||
|
||||
*(.text)
|
||||
*(.fixup)
|
||||
*(.got1)
|
||||
}
|
||||
_etext = .;
|
||||
PROVIDE (etext = .);
|
||||
.rodata :
|
||||
{
|
||||
*(.rodata)
|
||||
*(.rodata1)
|
||||
*(.rodata.str1.4)
|
||||
*(.eh_frame)
|
||||
}
|
||||
.fini : { *(.fini) } =0
|
||||
.ctors : { *(.ctors) }
|
||||
.dtors : { *(.dtors) }
|
||||
|
||||
/* Read-write section, merged into data segment: */
|
||||
. = (. + 0x0FFF) & 0xFFFFF000;
|
||||
_erotext = .;
|
||||
PROVIDE (erotext = .);
|
||||
.reloc :
|
||||
{
|
||||
*(.got)
|
||||
_GOT2_TABLE_ = .;
|
||||
*(.got2)
|
||||
_FIXUP_TABLE_ = .;
|
||||
*(.fixup)
|
||||
}
|
||||
__got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >>2;
|
||||
__fixup_entries = (. - _FIXUP_TABLE_)>>2;
|
||||
|
||||
.data :
|
||||
{
|
||||
*(.data)
|
||||
*(.data1)
|
||||
*(.sdata)
|
||||
*(.sdata2)
|
||||
*(.dynamic)
|
||||
CONSTRUCTORS
|
||||
}
|
||||
_edata = .;
|
||||
PROVIDE (edata = .);
|
||||
|
||||
. = .;
|
||||
__u_boot_cmd_start = .;
|
||||
.u_boot_cmd : { *(.u_boot_cmd) }
|
||||
__u_boot_cmd_end = .;
|
||||
|
||||
|
||||
. = .;
|
||||
__start___ex_table = .;
|
||||
__ex_table : { *(__ex_table) }
|
||||
__stop___ex_table = .;
|
||||
|
||||
. = ALIGN(256);
|
||||
__init_begin = .;
|
||||
.text.init : { *(.text.init) }
|
||||
.data.init : { *(.data.init) }
|
||||
. = ALIGN(256);
|
||||
__init_end = .;
|
||||
|
||||
__bss_start = .;
|
||||
.bss :
|
||||
{
|
||||
*(.sbss) *(.scommon)
|
||||
*(.dynbss)
|
||||
*(.bss)
|
||||
*(COMMON)
|
||||
}
|
||||
_end = . ;
|
||||
PROVIDE (end = .);
|
||||
}
|
||||
1308
board/amcc/yucca/yucca.c
Normal file
1308
board/amcc/yucca/yucca.c
Normal file
File diff suppressed because it is too large
Load Diff
366
board/amcc/yucca/yucca.h
Normal file
366
board/amcc/yucca/yucca.h
Normal file
@@ -0,0 +1,366 @@
|
||||
/*
|
||||
* (C) Copyright 2006
|
||||
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
||||
*
|
||||
* See file CREDITS for list of people who contributed to this
|
||||
* project.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
||||
* MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#ifndef __YUCCA_H_
|
||||
#define __YUCCA_H_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*----------------------------------------------------------------------------+
|
||||
| Defines
|
||||
+----------------------------------------------------------------------------*/
|
||||
|
||||
#define TMR_FREQ_EXT 25000000
|
||||
#define BOARD_UART_CLOCK 11059200
|
||||
|
||||
#define BOARD_OPTION_SELECTED 1
|
||||
#define BOARD_OPTION_NOT_SELECTED 0
|
||||
|
||||
#define ENGINEERING_CLOCK_CHECKING "clk_chk"
|
||||
#define ENGINEERING_EXTERNAL_CLOCK "ext_clk"
|
||||
|
||||
#define ENGINEERING_CLOCK_CHECKING_DATA 1
|
||||
#define ENGINEERING_EXTERNAL_CLOCK_DATA 2
|
||||
|
||||
/* ethernet definition */
|
||||
#define MAX_ENETMODE_PARM 3
|
||||
#define ENETMODE_NEG 0
|
||||
#define ENETMODE_SPEED 1
|
||||
#define ENETMODE_DUPLEX 2
|
||||
|
||||
#define ENETMODE_AUTONEG 0
|
||||
#define ENETMODE_NO_AUTONEG 1
|
||||
#define ENETMODE_10 2
|
||||
#define ENETMODE_100 3
|
||||
#define ENETMODE_1000 4
|
||||
#define ENETMODE_HALF 5
|
||||
#define ENETMODE_FULL 6
|
||||
|
||||
#define NUM_TLB_ENTRIES 64
|
||||
|
||||
/* MICRON SPD JEDEC ID Code (first byte) - SPD data byte [64] */
|
||||
#define MICRON_SPD_JEDEC_ID 0x2c
|
||||
|
||||
/*----------------------------------------------------------------------------+
|
||||
| TLB specific defines.
|
||||
+----------------------------------------------------------------------------*/
|
||||
#define TLB_256MB_ALIGN_MASK 0xF0000000
|
||||
#define TLB_16MB_ALIGN_MASK 0xFF000000
|
||||
#define TLB_1MB_ALIGN_MASK 0xFFF00000
|
||||
#define TLB_256KB_ALIGN_MASK 0xFFFC0000
|
||||
#define TLB_64KB_ALIGN_MASK 0xFFFF0000
|
||||
#define TLB_16KB_ALIGN_MASK 0xFFFFC000
|
||||
#define TLB_4KB_ALIGN_MASK 0xFFFFF000
|
||||
#define TLB_1KB_ALIGN_MASK 0xFFFFFC00
|
||||
#define TLB_256MB_SIZE 0x10000000
|
||||
#define TLB_16MB_SIZE 0x01000000
|
||||
#define TLB_1MB_SIZE 0x00100000
|
||||
#define TLB_256KB_SIZE 0x00040000
|
||||
#define TLB_64KB_SIZE 0x00010000
|
||||
#define TLB_16KB_SIZE 0x00004000
|
||||
#define TLB_4KB_SIZE 0x00001000
|
||||
#define TLB_1KB_SIZE 0x00000400
|
||||
|
||||
#define TLB_WORD0_EPN_MASK 0xFFFFFC00
|
||||
#define TLB_WORD0_EPN_ENCODE(n) (((unsigned long)(n))&0xFFFFFC00)
|
||||
#define TLB_WORD0_EPN_DECODE(n) (((unsigned long)(n))&0xFFFFFC00)
|
||||
#define TLB_WORD0_V_MASK 0x00000200
|
||||
#define TLB_WORD0_V_ENABLE 0x00000200
|
||||
#define TLB_WORD0_V_DISABLE 0x00000000
|
||||
#define TLB_WORD0_TS_MASK 0x00000100
|
||||
#define TLB_WORD0_TS_1 0x00000100
|
||||
#define TLB_WORD0_TS_0 0x00000000
|
||||
#define TLB_WORD0_SIZE_MASK 0x000000F0
|
||||
#define TLB_WORD0_SIZE_1KB 0x00000000
|
||||
#define TLB_WORD0_SIZE_4KB 0x00000010
|
||||
#define TLB_WORD0_SIZE_16KB 0x00000020
|
||||
#define TLB_WORD0_SIZE_64KB 0x00000030
|
||||
#define TLB_WORD0_SIZE_256KB 0x00000040
|
||||
#define TLB_WORD0_SIZE_1MB 0x00000050
|
||||
#define TLB_WORD0_SIZE_16MB 0x00000070
|
||||
#define TLB_WORD0_SIZE_256MB 0x00000090
|
||||
#define TLB_WORD0_TPAR_MASK 0x0000000F
|
||||
#define TLB_WORD0_TPAR_ENCODE(n) ((((unsigned long)(n))&0x0F)<<0)
|
||||
#define TLB_WORD0_TPAR_DECODE(n) ((((unsigned long)(n))>>0)&0x0F)
|
||||
|
||||
#define TLB_WORD1_RPN_MASK 0xFFFFFC00
|
||||
#define TLB_WORD1_RPN_ENCODE(n) (((unsigned long)(n))&0xFFFFFC00)
|
||||
#define TLB_WORD1_RPN_DECODE(n) (((unsigned long)(n))&0xFFFFFC00)
|
||||
#define TLB_WORD1_PAR1_MASK 0x00000300
|
||||
#define TLB_WORD1_PAR1_ENCODE(n) ((((unsigned long)(n))&0x03)<<8)
|
||||
#define TLB_WORD1_PAR1_DECODE(n) ((((unsigned long)(n))>>8)&0x03)
|
||||
#define TLB_WORD1_PAR1_0 0x00000000
|
||||
#define TLB_WORD1_PAR1_1 0x00000100
|
||||
#define TLB_WORD1_PAR1_2 0x00000200
|
||||
#define TLB_WORD1_PAR1_3 0x00000300
|
||||
#define TLB_WORD1_ERPN_MASK 0x0000000F
|
||||
#define TLB_WORD1_ERPN_ENCODE(n) ((((unsigned long)(n))&0x0F)<<0)
|
||||
#define TLB_WORD1_ERPN_DECODE(n) ((((unsigned long)(n))>>0)&0x0F)
|
||||
|
||||
#define TLB_WORD2_PAR2_MASK 0xC0000000
|
||||
#define TLB_WORD2_PAR2_ENCODE(n) ((((unsigned long)(n))&0x03)<<30)
|
||||
#define TLB_WORD2_PAR2_DECODE(n) ((((unsigned long)(n))>>30)&0x03)
|
||||
#define TLB_WORD2_PAR2_0 0x00000000
|
||||
#define TLB_WORD2_PAR2_1 0x40000000
|
||||
#define TLB_WORD2_PAR2_2 0x80000000
|
||||
#define TLB_WORD2_PAR2_3 0xC0000000
|
||||
#define TLB_WORD2_U0_MASK 0x00008000
|
||||
#define TLB_WORD2_U0_ENABLE 0x00008000
|
||||
#define TLB_WORD2_U0_DISABLE 0x00000000
|
||||
#define TLB_WORD2_U1_MASK 0x00004000
|
||||
#define TLB_WORD2_U1_ENABLE 0x00004000
|
||||
#define TLB_WORD2_U1_DISABLE 0x00000000
|
||||
#define TLB_WORD2_U2_MASK 0x00002000
|
||||
#define TLB_WORD2_U2_ENABLE 0x00002000
|
||||
#define TLB_WORD2_U2_DISABLE 0x00000000
|
||||
#define TLB_WORD2_U3_MASK 0x00001000
|
||||
#define TLB_WORD2_U3_ENABLE 0x00001000
|
||||
#define TLB_WORD2_U3_DISABLE 0x00000000
|
||||
#define TLB_WORD2_W_MASK 0x00000800
|
||||
#define TLB_WORD2_W_ENABLE 0x00000800
|
||||
#define TLB_WORD2_W_DISABLE 0x00000000
|
||||
#define TLB_WORD2_I_MASK 0x00000400
|
||||
#define TLB_WORD2_I_ENABLE 0x00000400
|
||||
#define TLB_WORD2_I_DISABLE 0x00000000
|
||||
#define TLB_WORD2_M_MASK 0x00000200
|
||||
#define TLB_WORD2_M_ENABLE 0x00000200
|
||||
#define TLB_WORD2_M_DISABLE 0x00000000
|
||||
#define TLB_WORD2_G_MASK 0x00000100
|
||||
#define TLB_WORD2_G_ENABLE 0x00000100
|
||||
#define TLB_WORD2_G_DISABLE 0x00000000
|
||||
#define TLB_WORD2_E_MASK 0x00000080
|
||||
#define TLB_WORD2_E_ENABLE 0x00000080
|
||||
#define TLB_WORD2_E_DISABLE 0x00000000
|
||||
#define TLB_WORD2_UX_MASK 0x00000020
|
||||
#define TLB_WORD2_UX_ENABLE 0x00000020
|
||||
#define TLB_WORD2_UX_DISABLE 0x00000000
|
||||
#define TLB_WORD2_UW_MASK 0x00000010
|
||||
#define TLB_WORD2_UW_ENABLE 0x00000010
|
||||
#define TLB_WORD2_UW_DISABLE 0x00000000
|
||||
#define TLB_WORD2_UR_MASK 0x00000008
|
||||
#define TLB_WORD2_UR_ENABLE 0x00000008
|
||||
#define TLB_WORD2_UR_DISABLE 0x00000000
|
||||
#define TLB_WORD2_SX_MASK 0x00000004
|
||||
#define TLB_WORD2_SX_ENABLE 0x00000004
|
||||
#define TLB_WORD2_SX_DISABLE 0x00000000
|
||||
#define TLB_WORD2_SW_MASK 0x00000002
|
||||
#define TLB_WORD2_SW_ENABLE 0x00000002
|
||||
#define TLB_WORD2_SW_DISABLE 0x00000000
|
||||
#define TLB_WORD2_SR_MASK 0x00000001
|
||||
#define TLB_WORD2_SR_ENABLE 0x00000001
|
||||
#define TLB_WORD2_SR_DISABLE 0x00000000
|
||||
|
||||
/*----------------------------------------------------------------------------+
|
||||
| Board specific defines.
|
||||
+----------------------------------------------------------------------------*/
|
||||
#define NONCACHE_MEMORY_SIZE (64*1024)
|
||||
#define NONCACHE_AREA0_ENDOFFSET (64*1024)
|
||||
#define NONCACHE_AREA1_ENDOFFSET (32*1024)
|
||||
|
||||
#define FLASH_SECTORSIZE 0x00010000
|
||||
|
||||
/* SDRAM MICRON */
|
||||
#define SDRAM_MICRON 0x2C
|
||||
|
||||
#define SDRAM_TRUE 1
|
||||
#define SDRAM_FALSE 0
|
||||
#define SDRAM_DDR1 1
|
||||
#define SDRAM_DDR2 2
|
||||
#define SDRAM_NONE 0
|
||||
#define MAXDIMMS 2 /* Changes le 12/01/05 pour 1.6 */
|
||||
#define MAXRANKS 4 /* Changes le 12/01/05 pour 1.6 */
|
||||
#define MAXBANKSPERDIMM 2
|
||||
#define MAXRANKSPERDIMM 2
|
||||
#define MAXBXCF 4 /* Changes le 12/01/05 pour 1.6 */
|
||||
#define MAXSDRAMMEMORY 0xFFFFFFFF /* 4GB */
|
||||
#define ERROR_STR_LENGTH 256
|
||||
#define MAX_SPD_BYTES 256 /* Max number of bytes on the DIMM's SPD EEPROM */
|
||||
|
||||
/*----------------------------------------------------------------------------+
|
||||
| SDR Configuration registers
|
||||
+----------------------------------------------------------------------------*/
|
||||
/* Serial Device Strap Reg 0 */
|
||||
#define sdr_pstrp0 0x0040
|
||||
|
||||
#define SDR0_SDSTP1_EBC_ROM_BS_MASK 0x00000080 /* EBC Boot bus width Mask */
|
||||
#define SDR0_SDSTP1_EBC_ROM_BS_16BIT 0x00000080 /* EBC 16 Bits */
|
||||
#define SDR0_SDSTP1_EBC_ROM_BS_8BIT 0x00000000 /* EBC 8 Bits */
|
||||
|
||||
#define SDR0_SDSTP1_BOOT_SEL_MASK 0x00080000 /* Boot device Selection Mask */
|
||||
#define SDR0_SDSTP1_BOOT_SEL_EBC 0x00000000 /* EBC */
|
||||
#define SDR0_SDSTP1_BOOT_SEL_PCI 0x00080000 /* PCI */
|
||||
|
||||
#define SDR0_SDSTP1_EBC_SIZE_MASK 0x00000060 /* Boot rom size Mask */
|
||||
#define SDR0_SDSTP1_BOOT_SIZE_16MB 0x00000060 /* 16 MB */
|
||||
#define SDR0_SDSTP1_BOOT_SIZE_8MB 0x00000040 /* 8 MB */
|
||||
#define SDR0_SDSTP1_BOOT_SIZE_4MB 0x00000020 /* 4 MB */
|
||||
#define SDR0_SDSTP1_BOOT_SIZE_2MB 0x00000000 /* 2 MB */
|
||||
|
||||
/* Serial Device Enabled - Addr = 0xA8 */
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_IIC_A8_EN SDR0_PSTRP0_BOOTSTRAP_SETTINGS5
|
||||
/* Serial Device Enabled - Addr = 0xA4 */
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_IIC_A4_EN SDR0_PSTRP0_BOOTSTRAP_SETTINGS7
|
||||
|
||||
/* Pin Straps Reg */
|
||||
#define SDR0_PSTRP0 0x0040
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_MASK 0xE0000000 /* Strap Bits */
|
||||
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_SETTINGS0 0x00000000 /* Default strap settings 0 */
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_SETTINGS1 0x20000000 /* Default strap settings 1 */
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_SETTINGS2 0x40000000 /* Default strap settings 2 */
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_SETTINGS3 0x60000000 /* Default strap settings 3 */
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_SETTINGS4 0x80000000 /* Default strap settings 4 */
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_SETTINGS5 0xA0000000 /* Default strap settings 5 */
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_SETTINGS6 0xC0000000 /* Default strap settings 6 */
|
||||
#define SDR0_PSTRP0_BOOTSTRAP_SETTINGS7 0xE0000000 /* Default strap settings 7 */
|
||||
|
||||
/* fpgareg - defines are in include/config/YUCCA.h */
|
||||
|
||||
#define SDR0_CUST0_ENET3_MASK 0x00000080
|
||||
#define SDR0_CUST0_ENET3_COPPER 0x00000000
|
||||
#define SDR0_CUST0_ENET3_FIBER 0x00000080
|
||||
#define SDR0_CUST0_RGMII3_MASK 0x00000070
|
||||
#define SDR0_CUST0_RGMII3_ENCODE(n) ((((unsigned long)(n))&0x7)<<4)
|
||||
#define SDR0_CUST0_RGMII3_DECODE(n) ((((unsigned long)(n))>>4)&0x07)
|
||||
#define SDR0_CUST0_RGMII3_DISAB 0x00000000
|
||||
#define SDR0_CUST0_RGMII3_RTBI 0x00000040
|
||||
#define SDR0_CUST0_RGMII3_RGMII 0x00000050
|
||||
#define SDR0_CUST0_RGMII3_TBI 0x00000060
|
||||
#define SDR0_CUST0_RGMII3_GMII 0x00000070
|
||||
#define SDR0_CUST0_ENET2_MASK 0x00000008
|
||||
#define SDR0_CUST0_ENET2_COPPER 0x00000000
|
||||
#define SDR0_CUST0_ENET2_FIBER 0x00000008
|
||||
#define SDR0_CUST0_RGMII2_MASK 0x00000007
|
||||
#define SDR0_CUST0_RGMII2_ENCODE(n) ((((unsigned long)(n))&0x7)<<0)
|
||||
#define SDR0_CUST0_RGMII2_DECODE(n) ((((unsigned long)(n))>>0)&0x07)
|
||||
#define SDR0_CUST0_RGMII2_DISAB 0x00000000
|
||||
#define SDR0_CUST0_RGMII2_RTBI 0x00000004
|
||||
#define SDR0_CUST0_RGMII2_RGMII 0x00000005
|
||||
#define SDR0_CUST0_RGMII2_TBI 0x00000006
|
||||
#define SDR0_CUST0_RGMII2_GMII 0x00000007
|
||||
|
||||
#define ONE_MILLION 1000000
|
||||
#define ONE_BILLION 1000000000
|
||||
|
||||
/*----------------------------------------------------------------------------+
|
||||
| X
|
||||
| XX
|
||||
| XX XXX XXXXX XX XXX XXXXX
|
||||
| XX XX X XXX XX XX
|
||||
| XX XX XXXXXX XX XX
|
||||
| XX XX X XX XX XX XX
|
||||
| XXX XX XXXXX X XXXX XXX
|
||||
+----------------------------------------------------------------------------*/
|
||||
/*----------------------------------------------------------------------------+
|
||||
| Declare Configuration values
|
||||
+----------------------------------------------------------------------------*/
|
||||
|
||||
typedef enum config_selection {
|
||||
CONFIG_NOT_SELECTED,
|
||||
CONFIG_SELECTED
|
||||
} config_selection_t;
|
||||
|
||||
typedef enum config_list {
|
||||
UART2_IN_SERVICE_MODE,
|
||||
CPU_TRACE_MODE,
|
||||
UART1_CTS_RTS,
|
||||
CONFIG_NB
|
||||
} config_list_t;
|
||||
|
||||
#define MAX_CONFIG_SELECT_NB 3
|
||||
|
||||
#define BOARD_INFO_UART2_IN_SERVICE_MODE 1
|
||||
#define BOARD_INFO_CPU_TRACE_MODE 2
|
||||
#define BOARD_INFO_UART1_CTS_RTS_MODE 4
|
||||
|
||||
void force_bup_config_selection(config_selection_t *confgi_select_P);
|
||||
void update_config_selection_table(config_selection_t *config_select_P);
|
||||
void display_config_selection(config_selection_t *config_select_P);
|
||||
|
||||
/*----------------------------------------------------------------------------+
|
||||
| XX
|
||||
|
|
||||
| XXXX XX XXX XXX XXXX
|
||||
| XX XX XX XX XX XX
|
||||
| XX XXX XX XX XX XX XX
|
||||
| XX XX XXXXX XX XX XX
|
||||
| XXXX XX XXXX XXXX
|
||||
| XXXX
|
||||
|
|
||||
|
|
||||
|
|
||||
| +------------------------------------------------------------------+
|
||||
| | GPIO/Secondary func | Primary Function | I/O | Alternate1 | I/O |
|
||||
| +----------------------+------------------+-----+------------+-----+
|
||||
| | | | | | |
|
||||
| | GPIO0_0 | PCIX0REQ2_N | I/O | TRCCLK | |
|
||||
| | GPIO0_1 | PCIX0REQ3_N | I/O | TRCBS0 | |
|
||||
| | GPIO0_2 | PCIX0GNT2_N | I/O | TRCBS1 | |
|
||||
| | GPIO0_3 | PCIX0GNT3_N | I/O | TRCBS2 | |
|
||||
| | GPIO0_4 | PCIX1REQ2_N | I/O | TRCES0 | |
|
||||
| | GPIO0_5 | PCIX1REQ3_N | I/O | TRCES1 | |
|
||||
| | GPIO0_6 | PCIX1GNT2_N | I/O | TRCES2 | NA |
|
||||
| | GPIO0_7 | PCIX1GNT3_N | I/O | TRCES3 | NA |
|
||||
| | GPIO0_8 | PERREADY | I | TRCES4 | NA |
|
||||
| | GPIO0_9 | PERCS1_N | O | TRCTS0 | NA |
|
||||
| | GPIO0_10 | PERCS2_N | O | TRCTS1 | NA |
|
||||
| | GPIO0_11 | IRQ0 | I | TRCTS2 | NA |
|
||||
| | GPIO0_12 | IRQ1 | I | TRCTS3 | NA |
|
||||
| | GPIO0_13 | IRQ2 | I | TRCTS4 | NA |
|
||||
| | GPIO0_14 | IRQ3 | I | TRCTS5 | NA |
|
||||
| | GPIO0_15 | IRQ4 | I | TRCTS6 | NA |
|
||||
| | GPIO0_16 | IRQ5 | I | UART2RX | I |
|
||||
| | GPIO0_17 | PERBE0_N | O | UART2TX | O |
|
||||
| | GPIO0_18 | PCI0GNT0_N | I/O | NA | NA |
|
||||
| | GPIO0_19 | PCI0GNT1_N | I/O | NA | NA |
|
||||
| | GPIO0_20 | PCI0REQ0_N | I/O | NA | NA |
|
||||
| | GPIO0_21 | PCI0REQ1_N | I/O | NA | NA |
|
||||
| | GPIO0_22 | PCI1GNT0_N | I/O | NA | NA |
|
||||
| | GPIO0_23 | PCI1GNT1_N | I/O | NA | NA |
|
||||
| | GPIO0_24 | PCI1REQ0_N | I/O | NA | NA |
|
||||
| | GPIO0_25 | PCI1REQ1_N | I/O | NA | NA |
|
||||
| | GPIO0_26 | PCI2GNT0_N | I/O | NA | NA |
|
||||
| | GPIO0_27 | PCI2GNT1_N | I/O | NA | NA |
|
||||
| | GPIO0_28 | PCI2REQ0_N | I/O | NA | NA |
|
||||
| | GPIO0_29 | PCI2REQ1_N | I/O | NA | NA |
|
||||
| | GPIO0_30 | UART1RX | I | NA | NA |
|
||||
| | GPIO0_31 | UART1TX | O | NA | NA |
|
||||
| | | | | | |
|
||||
| +----------------------+------------------+-----+------------+-----+
|
||||
|
|
||||
+----------------------------------------------------------------------------*/
|
||||
|
||||
unsigned long auto_calc_speed(void);
|
||||
/*----------------------------------------------------------------------------+
|
||||
| Prototypes
|
||||
+----------------------------------------------------------------------------*/
|
||||
void print_evb440spe_info(void);
|
||||
|
||||
int onboard_pci_arbiter_selected(int core_pci);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif /* __YUCCA_H_ */
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user