diff mbox

[U-Boot,31/32] sc520: Release CAR and enable caching

Message ID 1296822959-3927-32-git-send-email-graeme.russ@gmail.com
State Accepted
Commit 6002bf03b4965053d7112c4ea2125d0b6548b0e9
Delegated to: Graeme Russ
Headers show

Commit Message

Graeme Russ Feb. 4, 2011, 12:35 p.m. UTC
Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
---
 arch/i386/cpu/sc520/sc520.c |   16 +++++++++++-----
 1 files changed, 11 insertions(+), 5 deletions(-)

Comments

Graeme Russ Feb. 12, 2011, 4:31 a.m. UTC | #1
On 04/02/11 23:35, Graeme Russ wrote:
> Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
> ---
>  arch/i386/cpu/sc520/sc520.c |   16 +++++++++++-----
>  1 files changed, 11 insertions(+), 5 deletions(-)
> 

Applied to u-boot-x86

Regards,

Graeme
diff mbox

Patch

diff --git a/arch/i386/cpu/sc520/sc520.c b/arch/i386/cpu/sc520/sc520.c
index e5dcac6..d0c313b 100644
--- a/arch/i386/cpu/sc520/sc520.c
+++ b/arch/i386/cpu/sc520/sc520.c
@@ -51,14 +51,20 @@  int cpu_init_f(void)
 	    "popl	%%ecx\n"
 	    "loop 0b\n": : : "ecx");
 
-	if (gd->flags & GD_FLG_COLD_BOOT) {
-		/* turn on the SDRAM write buffer */
-		writeb(0x11, &sc520_mmcr->dbctl);
-	}
-
 	return x86_cpu_init_f();
 }
 
+int cpu_init_r(void)
+{
+	/* Disable the PAR used for CAR */
+	writel(0x0000000, &sc520_mmcr->par[2]);
+
+	/* turn on the SDRAM write buffer */
+	writeb(0x11, &sc520_mmcr->dbctl);
+
+	return x86_cpu_init_r();
+}
+
 #ifdef CONFIG_SYS_SC520_RESET
 void reset_cpu(ulong addr)
 {