Patchwork [U-Boot] fsl_ifc:Fixed a bug in the erratum handling code for IFC_A003399

login
register
mail settings
Submitter poonam aggrwal
Date Nov. 1, 2011, 1:28 p.m.
Message ID <1320154100-4161-1-git-send-email-poonam.aggrwal@freescale.com>
Download mbox | patch
Permalink /patch/123069/
State Accepted
Delegated to: Kumar Gala
Headers show

Comments

poonam aggrwal - Nov. 1, 2011, 1:28 p.m.
Wrong pointer was being used to copy code into L2SRAM.
Also removed the unreferenced variable l2srbar.
Signed-off-by: Poonam Aggrwal <poonam.aggrwal@freescale.com>
---
Thanks Wolfgang and Kumar for identifying the issue.
 arch/powerpc/cpu/mpc85xx/cpu_init_early.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
Kumar Gala - Nov. 8, 2011, 2:42 p.m.
On Nov 1, 2011, at 8:28 AM, Poonam Aggrwal wrote:

> Wrong pointer was being used to copy code into L2SRAM.
> Also removed the unreferenced variable l2srbar.
> Signed-off-by: Poonam Aggrwal <poonam.aggrwal@freescale.com>
> ---
> Thanks Wolfgang and Kumar for identifying the issue.
> arch/powerpc/cpu/mpc85xx/cpu_init_early.c |    4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)

applied to 85xx

- k

Patch

diff --git a/arch/powerpc/cpu/mpc85xx/cpu_init_early.c b/arch/powerpc/cpu/mpc85xx/cpu_init_early.c
index 4ef3c9a..091af7c 100644
--- a/arch/powerpc/cpu/mpc85xx/cpu_init_early.c
+++ b/arch/powerpc/cpu/mpc85xx/cpu_init_early.c
@@ -71,7 +71,7 @@  void cpu_init_early_f(void)
 #endif
 #if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399) && !defined(CONFIG_SYS_RAMBOOT)
 	ccsr_l2cache_t *l2cache = (void *)CONFIG_SYS_MPC85xx_L2_ADDR;
-	u32  *l2srbar, *dst, *src;
+	u32  *dst, *src;
 	void (*setup_ifc_sram)(void);
 #endif
 
@@ -137,7 +137,7 @@  void cpu_init_early_f(void)
 	dst = (u32 *) SRAM_BASE_ADDR;
 	src = (u32 *) setup_ifc;
 	for (i = 0; i < 1024; i++)
-		*l2srbar++ = *src++;
+		*dst++ = *src++;
 
 	setup_ifc_sram();