summaryrefslogtreecommitdiff
path: root/board/st/u8500/u8500.c
diff options
context:
space:
mode:
authorMichael Brandt <Michael.Brandt@stericsson.com>2009-11-10 16:39:53 +0100
committerMichael Brandt <Michael.Brandt@stericsson.com>2009-11-10 16:39:53 +0100
commitc0b34f5c4bd037cd93709b30ee1a670723e77084 (patch)
treea5d62db45625ce06a2ac721e5e5cb8297c34a564 /board/st/u8500/u8500.c
parentc5fd9311b6c59a5fb4c6e7188c8bef96e3e2d86d (diff)
PACK2 changes
merged PACK2 changes: mmc and i2c frequency, put the second core into wfe, default bootcmd.
Diffstat (limited to 'board/st/u8500/u8500.c')
-rwxr-xr-xboard/st/u8500/u8500.c33
1 files changed, 20 insertions, 13 deletions
diff --git a/board/st/u8500/u8500.c b/board/st/u8500/u8500.c
index 0cca76cf3..4bb94e2b9 100755
--- a/board/st/u8500/u8500.c
+++ b/board/st/u8500/u8500.c
@@ -27,20 +27,26 @@
#include <asm/errno.h>
#include "common.h"
+#define NOMADIK_PER4_BASE (0x80150000)
+#define NOMADIK_BACKUPRAM0_BASE (NOMADIK_PER4_BASE + 0x00000)
+#define NOMADIK_BACKUPRAM1_BASE (NOMADIK_PER4_BASE + 0x01000)
-void init_regs(void);
-#if 0
-void *memcopy(void *dest, const void *src, size_t count)
+extern void (*handler)();
+extern unsigned volatile long magic_num;
+extern void secondary_wfe();
+
+void wake_up_other_cores()
{
- u16 *tmp = (u16 *) dest, *s = (u16 *) src;
+ handler = secondary_wfe;
+ *((volatile unsigned int *)(NOMADIK_BACKUPRAM0_BASE+0x1FF4))= handler;
+ *((volatile unsigned int *)(NOMADIK_BACKUPRAM0_BASE+0x1FF0))= 0xA1FEED01;
+ asm("SEV");
+ return;
+}
- count = count / 2;
- while (count--)
- *tmp++ = *s++;
+void init_regs(void);
- return dest;
-}
-#endif
+DECLARE_GLOBAL_DATA_PTR;
#if defined(CONFIG_SHOW_BOOT_PROGRESS)
void show_boot_progress(int progress)
{
@@ -60,7 +66,6 @@ static inline void delay(unsigned long loops)
int board_init(void)
{
- DECLARE_GLOBAL_DATA_PTR;
gd->bd->bi_arch_number = 0x1A4;
gd->bd->bi_boot_params = 0x00000100;
//enable the timers in PRCMU reg
@@ -86,12 +91,13 @@ Description:
******************************/
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_SIZE_1;
+#ifdef CONFIG_U8500_V1
gd->bd->bi_dram[1].start = PHYS_SDRAM_2;
gd->bd->bi_dram[1].size = PHYS_SDRAM_SIZE_2;
-
+#endif
+ wake_up_other_cores();
return 0;
}
@@ -103,6 +109,7 @@ unsigned int addr_vall_arr[] = {
0x8000F008, 0x00007FFF, // Clocks for I2C TODO Enable reqd only
0x8000E120, 0x003C0000, // GPIO for I2C/SD
0x8000E124, 0x00000000, // GPIO for I2C/SD
+0x80157020, 0x00000130, // I2C 48MHz clock
0x8012F000, 0x00007FFF, // Clocks for SD TODO Enable reqd only
0x8012F008, 0x00007FFF, // Clocks for SD TODO Enable reqd only
0xA03DF000, 0x0000000D, // Clock for MTU Timers