a092ca25ec1a3521791991bc254d2ac88e3dcf93
[openembedded.git] /
1 From 7f50d09f9a00b7f2a392a5b0b9f2f19a96a90c16 Mon Sep 17 00:00:00 2001
2 From: Steve Sakoman <steve@sakoman.com>
3 Date: Tue, 23 Mar 2010 09:04:50 -0700
4 Subject: [PATCH 14/50] OMAP3: board.c: don't attempt to set up second RAM bank, assume x-load has already done this
5
6 ---
7  cpu/arm_cortexa8/omap3/board.c |   19 +++++++++----------
8  1 files changed, 9 insertions(+), 10 deletions(-)
9
10 diff --git a/cpu/arm_cortexa8/omap3/board.c b/cpu/arm_cortexa8/omap3/board.c
11 index 7b78fa4..0126152 100644
12 --- a/cpu/arm_cortexa8/omap3/board.c
13 +++ b/cpu/arm_cortexa8/omap3/board.c
14 @@ -232,6 +232,7 @@ void s_init(void)
15  
16         per_clocks_enable();
17  
18 +       /* FIXME: u-boot's sdrc setup is broken */
19         if (!in_sdram)
20                 sdrc_init();
21  }
22 @@ -281,16 +282,14 @@ int dram_init(void)
23  {
24         DECLARE_GLOBAL_DATA_PTR;
25         unsigned int size0 = 0, size1 = 0;
26 -
27 -       /*
28 -        * If a second bank of DDR is attached to CS1 this is
29 -        * where it can be started.  Early init code will init
30 -        * memory on CS0.
31 -        */
32 -       if ((sysinfo.mtype == DDR_COMBO) || (sysinfo.mtype == DDR_STACKED)) {
33 -               do_sdrc_init(CS1, NOT_EARLY);
34 -               make_cs1_contiguous();
35 -       }
36 +       struct sdrc *sdrc_base = (struct sdrc *)OMAP34XX_SDRC_BASE;
37 +       struct sdrc_actim *sdrc_actim_base = (struct sdrc_actim *)SDRC_ACTIM_CTRL1_BASE;
38 +
39 +       /* x-load sets up the second bank but */
40 +       /* doesn't test to see if it is there */
41 +       /* do so now, disable if not present  */
42 +       if (!mem_ok(CS1))
43 +               writel(0, &sdrc_base->cs[1].mcfg);
44  
45         size0 = get_sdr_cs_size(CS0);
46         size1 = get_sdr_cs_size(CS1);
47 -- 
48 1.6.6.1
49