3 * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
5 * See file CREDITS for list of people who contributed to this
8 * This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU General Public License as
10 * published by the Free Software Foundation; either version 2 of
11 * the License, or (at your option) any later version.
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
28 /* ------------------------------------------------------------------------- */
30 #define _NOT_USED_ 0xFFFFFFFF
32 const uint edo_60ns[] =
33 { 0x8ffbec24, 0x0ff3ec04, 0x0cf3ec04, 0x00f3ec04,
34 0x00f3ec00, 0x37f7ec47, _NOT_USED_, _NOT_USED_,
35 0x8fffec24, 0x0ffbec04, 0x08f3ec04, 0x07f3ec08,
36 0x08f3ec04, 0x07f3ec48, 0x08f3ec04, 0x07f3ec48,
37 0x08f3ec04, 0x07f3ec48, 0x1ff7ec47, _NOT_USED_,
38 _NOT_USED_, _NOT_USED_, _NOT_USED_, _NOT_USED_,
39 0x8fffcc24, 0x0fefcc04, 0x0cafcc00, 0x11bfcc47,
40 _NOT_USED_, _NOT_USED_, _NOT_USED_, _NOT_USED_,
41 0x8fffcc24, 0x0fefcc04, 0x0cafcc00, 0x03afcc4c,
42 0x0cafcc00, 0x03afcc4c, 0x0cafcc00, 0x03afcc4c,
43 0x0cafcc00, 0x33bfcc4f, _NOT_USED_, _NOT_USED_,
44 _NOT_USED_, _NOT_USED_, _NOT_USED_, _NOT_USED_,
45 0xc0ffcc84, 0x00ffcc04, 0x07ffcc04, 0x3fffcc06,
46 0xffffcc85, 0xffffcc05, _NOT_USED_, _NOT_USED_,
47 _NOT_USED_, _NOT_USED_, _NOT_USED_, _NOT_USED_,
48 0x33ffcc07, _NOT_USED_, _NOT_USED_, _NOT_USED_ };
50 /* ------------------------------------------------------------------------- */
53 * Check Board Identity:
58 puts ("Board: AMX860\n");
62 /* ------------------------------------------------------------------------- */
64 phys_size_t initdram (int board_type)
67 volatile immap_t *immap = (immap_t *)CONFIG_SYS_IMMR;
68 volatile memctl8xx_t *memctl = &immap->im_memctl;
70 /* AMX860: has 4 Mb of 60ns EDO DRAM, so start DRAM at 0 */
72 upmconfig(UPMA, (uint *) edo_60ns, sizeof(edo_60ns)/sizeof(uint));
74 #ifndef CONFIG_AMX_RAM_EXT
75 memctl->memc_mptpr = 0x0400; /* divide by 16 */
77 memctl->memc_mptpr = 0x0200;
80 memctl->memc_mamr = 0x30a21114;
81 memctl->memc_or2 = 0xffc00800;
82 #ifndef CONFIG_AMX_RAM_EXT
83 memctl->memc_br2 = 0x81;
87 memctl->memc_or1 = 0xff000800;
88 memctl->memc_br1 = 0x00000081;
89 memctl->memc_br2 = 0x01000081;