Message ID | 1363936068-17107-1-git-send-email-prabhakar@freescale.com |
---|---|
State | Superseded |
Delegated to: | Andy Fleming |
Headers | show |
On 03/22/2013 02:07:48 AM, Prabhakar Kushwaha wrote: > IFC errata A003399 is valid for IFC NOR boot i.e.if no on-board NOR > flash or > no NOR boot, do not compile its workaround. > > Signed-off-by: Prabhakar Kushwaha <prabhakar@freescale.com> > --- > Based upon git://git.denx.de/u-boot.git branch master > Changes for v2: > - Add CONFIG_A003399_NOR_WORKAROUND for errata workaround > - Add CONFIG_A003399_NOR_WORKAROUND in README > > README | 4 ++++ > arch/powerpc/cpu/mpc85xx/cpu_init_early.c | 9 ++++++--- > arch/powerpc/cpu/mpc8xxx/fsl_ifc.c | 2 +- > 3 files changed, 11 insertions(+), 4 deletions(-) > > diff --git a/README b/README > index 7f2506a..c4ad69d 100644 > --- a/README > +++ b/README > @@ -414,6 +414,10 @@ The following options need to be configured: > See Freescale App Note 4493 for more information about > this erratum. > > + CONFIG_A003399_NOR_WORKAROUND > + Enables a workaround for IFC erratum A003399. It is only > + requred during NOR boot. > + > CONFIG_SYS_FSL_CORENET_SNOOPVEC_COREONLY > > This is the value to write into CCSR offset 0x18600 > diff --git a/arch/powerpc/cpu/mpc85xx/cpu_init_early.c > b/arch/powerpc/cpu/mpc85xx/cpu_init_early.c > index dacfdd1..3a4bfc5 100644 > --- a/arch/powerpc/cpu/mpc85xx/cpu_init_early.c > +++ b/arch/powerpc/cpu/mpc85xx/cpu_init_early.c > @@ -25,7 +25,8 @@ > > DECLARE_GLOBAL_DATA_PTR; > > -#if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399) && > !defined(CONFIG_SYS_RAMBOOT) > +#if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399)\ > + && defined(CONFIG_A003399_NOR_WORKAROUND) Why would CONFIG_A003399_NOR_WORKAROUND be enabled if CONFIG_SYS_FSL_ERRATUM_IFC_A003399 isn't? -Scott
On 04/06/2013 02:03 AM, Scott Wood wrote: > On 03/22/2013 02:07:48 AM, Prabhakar Kushwaha wrote: >> IFC errata A003399 is valid for IFC NOR boot i.e.if no on-board NOR >> flash or >> no NOR boot, do not compile its workaround. >> >> Signed-off-by: Prabhakar Kushwaha <prabhakar@freescale.com> >> --- >> Based upon git://git.denx.de/u-boot.git branch master >> Changes for v2: >> - Add CONFIG_A003399_NOR_WORKAROUND for errata workaround >> - Add CONFIG_A003399_NOR_WORKAROUND in README >> >> README | 4 ++++ >> arch/powerpc/cpu/mpc85xx/cpu_init_early.c | 9 ++++++--- >> arch/powerpc/cpu/mpc8xxx/fsl_ifc.c | 2 +- >> 3 files changed, 11 insertions(+), 4 deletions(-) >> >> diff --git a/README b/README >> index 7f2506a..c4ad69d 100644 >> --- a/README >> +++ b/README >> @@ -414,6 +414,10 @@ The following options need to be configured: >> See Freescale App Note 4493 for more information about >> this erratum. >> >> + CONFIG_A003399_NOR_WORKAROUND >> + Enables a workaround for IFC erratum A003399. It is only >> + requred during NOR boot. >> + >> CONFIG_SYS_FSL_CORENET_SNOOPVEC_COREONLY >> >> This is the value to write into CCSR offset 0x18600 >> diff --git a/arch/powerpc/cpu/mpc85xx/cpu_init_early.c >> b/arch/powerpc/cpu/mpc85xx/cpu_init_early.c >> index dacfdd1..3a4bfc5 100644 >> --- a/arch/powerpc/cpu/mpc85xx/cpu_init_early.c >> +++ b/arch/powerpc/cpu/mpc85xx/cpu_init_early.c >> @@ -25,7 +25,8 @@ >> >> DECLARE_GLOBAL_DATA_PTR; >> >> -#if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399) && >> !defined(CONFIG_SYS_RAMBOOT) >> +#if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399)\ >> + && defined(CONFIG_A003399_NOR_WORKAROUND) > > Why would CONFIG_A003399_NOR_WORKAROUND be enabled if > CONFIG_SYS_FSL_ERRATUM_IFC_A003399 isn't? originally i tried the same but it did not work. As P1010RDB.h does not include config_mpc85xx.h. Only arch/powerpc/cpu/mpc85xx/*.c files includes both P1010RDB.h and config_mpc85xx.h Regards, Prabhakar
diff --git a/README b/README index 7f2506a..c4ad69d 100644 --- a/README +++ b/README @@ -414,6 +414,10 @@ The following options need to be configured: See Freescale App Note 4493 for more information about this erratum. + CONFIG_A003399_NOR_WORKAROUND + Enables a workaround for IFC erratum A003399. It is only + requred during NOR boot. + CONFIG_SYS_FSL_CORENET_SNOOPVEC_COREONLY This is the value to write into CCSR offset 0x18600 diff --git a/arch/powerpc/cpu/mpc85xx/cpu_init_early.c b/arch/powerpc/cpu/mpc85xx/cpu_init_early.c index dacfdd1..3a4bfc5 100644 --- a/arch/powerpc/cpu/mpc85xx/cpu_init_early.c +++ b/arch/powerpc/cpu/mpc85xx/cpu_init_early.c @@ -25,7 +25,8 @@ DECLARE_GLOBAL_DATA_PTR; -#if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399) && !defined(CONFIG_SYS_RAMBOOT) +#if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399)\ + && defined(CONFIG_A003399_NOR_WORKAROUND) void setup_ifc(void) { struct fsl_ifc *ifc_regs = (void *)CONFIG_SYS_IFC_ADDR; @@ -99,7 +100,8 @@ void cpu_init_early_f(void) #ifdef CONFIG_SYS_FSL_ERRATUM_P1010_A003549 ccsr_gur_t *gur = (void *)(CONFIG_SYS_MPC85xx_GUTS_ADDR); #endif -#if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399) && !defined(CONFIG_SYS_RAMBOOT) +#if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399)\ + && defined(CONFIG_A003399_NOR_WORKAROUND) ccsr_l2cache_t *l2cache = (void *)CONFIG_SYS_MPC85xx_L2_ADDR; u32 *dst, *src; void (*setup_ifc_sram)(void); @@ -138,7 +140,8 @@ void cpu_init_early_f(void) * Work Around for IFC Erratum A003399, issue will hit only when execution * from NOR Flash */ -#if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399) && !defined(CONFIG_SYS_RAMBOOT) +#if defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399)\ + && defined(CONFIG_A003399_NOR_WORKAROUND) #define SRAM_BASE_ADDR (0x00000000) /* TLB for SRAM */ mas0 = MAS0_TLBSEL(1) | MAS0_ESEL(9); diff --git a/arch/powerpc/cpu/mpc8xxx/fsl_ifc.c b/arch/powerpc/cpu/mpc8xxx/fsl_ifc.c index 56b319f..959a0e2 100644 --- a/arch/powerpc/cpu/mpc8xxx/fsl_ifc.c +++ b/arch/powerpc/cpu/mpc8xxx/fsl_ifc.c @@ -43,7 +43,7 @@ void init_early_memctl_regs(void) set_ifc_ftim(IFC_CS0, IFC_FTIM2, CONFIG_SYS_CS0_FTIM2); set_ifc_ftim(IFC_CS0, IFC_FTIM3, CONFIG_SYS_CS0_FTIM3); -#if !defined(CONFIG_SYS_FSL_ERRATUM_IFC_A003399) || defined(CONFIG_SYS_RAMBOOT) +#ifndef CONFIG_A003399_NOR_WORKAROUND #ifdef CONFIG_SYS_CSPR0_EXT set_ifc_cspr_ext(IFC_CS0, CONFIG_SYS_CSPR0_EXT); #endif
IFC errata A003399 is valid for IFC NOR boot i.e.if no on-board NOR flash or no NOR boot, do not compile its workaround. Signed-off-by: Prabhakar Kushwaha <prabhakar@freescale.com> --- Based upon git://git.denx.de/u-boot.git branch master Changes for v2: - Add CONFIG_A003399_NOR_WORKAROUND for errata workaround - Add CONFIG_A003399_NOR_WORKAROUND in README README | 4 ++++ arch/powerpc/cpu/mpc85xx/cpu_init_early.c | 9 ++++++--- arch/powerpc/cpu/mpc8xxx/fsl_ifc.c | 2 +- 3 files changed, 11 insertions(+), 4 deletions(-)