Patchwork [U-Boot,v3,4/4] zipitz2: fix boot issue introduced by PXA low level init rework

login
register
mail settings
Submitter Vasily Khoruzhick
Date Jan. 13, 2012, 7:11 a.m.
Message ID <1326438704-22383-4-git-send-email-anarsoul@gmail.com>
Download mbox | patch
Permalink /patch/135728/
State Accepted
Commit 76d4ae251e4a2f7724f4462baccc2779074fa937
Delegated to: Marek Vasut
Headers show

Comments

Vasily Khoruzhick - Jan. 13, 2012, 7:11 a.m.
CONFIG_SYS_INIT_SP_ADDR points to RAM, but it's used before
DRAM controller init. Fix it by setting CONFIG_SYS_INIT_SP_ADDR
to SRAM

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
---
v2: no changes
v3: introduce PHYS_SRAM, use it for SYS_INIT_SP_ADDR calculation

 include/configs/zipitz2.h |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)
Marek Vasut - Jan. 13, 2012, 12:39 p.m.
> CONFIG_SYS_INIT_SP_ADDR points to RAM, but it's used before
> DRAM controller init. Fix it by setting CONFIG_SYS_INIT_SP_ADDR
> to SRAM
> 
> Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
> ---
> v2: no changes
> v3: introduce PHYS_SRAM, use it for SYS_INIT_SP_ADDR calculation
> 
>  include/configs/zipitz2.h |    8 +++++++-
>  1 files changed, 7 insertions(+), 1 deletions(-)
> 
> diff --git a/include/configs/zipitz2.h b/include/configs/zipitz2.h
> index 4f48d9b..8add384 100644
> --- a/include/configs/zipitz2.h
> +++ b/include/configs/zipitz2.h
> @@ -170,6 +170,12 @@ unsigned char zipitz2_spi_read(void);
>  #endif
> 
>  /*
> + * SRAM Map
> + */
> +#define	PHYS_SRAM			0x5c000000	/* SRAM Bank #1 
*/
> +#define	PHYS_SRAM_SIZE			0x00040000	/* 256k */
> +
> +/*
>   * DRAM Map
>   */
>  #define	CONFIG_NR_DRAM_BANKS		1		/* We have 1 
bank of DRAM */
> @@ -185,7 +191,7 @@ unsigned char zipitz2_spi_read(void);
>  #define	CONFIG_SYS_LOAD_ADDR		CONFIG_SYS_DRAM_BASE
> 
>  #define CONFIG_SYS_SDRAM_BASE		PHYS_SDRAM_1
> -#define	CONFIG_SYS_INIT_SP_ADDR		(GENERATED_GBL_DATA_SIZE + 
PHYS_SDRAM_1 +
> 2048) +#define	CONFIG_SYS_INIT_SP_ADDR		(GENERATED_GBL_DATA_SIZE 
+
> PHYS_SRAM + 2048)
> 
>  /*
>   * NOR FLASH

Applied

Patch

diff --git a/include/configs/zipitz2.h b/include/configs/zipitz2.h
index 4f48d9b..8add384 100644
--- a/include/configs/zipitz2.h
+++ b/include/configs/zipitz2.h
@@ -170,6 +170,12 @@  unsigned char zipitz2_spi_read(void);
 #endif
 
 /*
+ * SRAM Map
+ */
+#define	PHYS_SRAM			0x5c000000	/* SRAM Bank #1 */
+#define	PHYS_SRAM_SIZE			0x00040000	/* 256k */
+
+/*
  * DRAM Map
  */
 #define	CONFIG_NR_DRAM_BANKS		1		/* We have 1 bank of DRAM */
@@ -185,7 +191,7 @@  unsigned char zipitz2_spi_read(void);
 #define	CONFIG_SYS_LOAD_ADDR		CONFIG_SYS_DRAM_BASE
 
 #define CONFIG_SYS_SDRAM_BASE		PHYS_SDRAM_1
-#define	CONFIG_SYS_INIT_SP_ADDR		(GENERATED_GBL_DATA_SIZE + PHYS_SDRAM_1 + 2048)
+#define	CONFIG_SYS_INIT_SP_ADDR		(GENERATED_GBL_DATA_SIZE + PHYS_SRAM + 2048)
 
 /*
  * NOR FLASH