All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH 1/4] arm/km: fix memory settings
@ 2012-11-02 10:15 Holger Brunck
  2012-11-02 10:15 ` [U-Boot] [PATCH 2/4] km/common: drop unneeded std* environment variables Holger Brunck
                   ` (5 more replies)
  0 siblings, 6 replies; 15+ messages in thread
From: Holger Brunck @ 2012-11-02 10:15 UTC (permalink / raw)
  To: u-boot

On kmcoge5un we faced some serious problems with the memory during
temperature tests. Reason was that we overwrite some registers for
memory settings which have to leave untouched. These where registers
0x20148 , 0x2014c and 0x20154.
So writing these registers is prohibited and this patch removes them
from all km related config files. Even if the problem was only
seen on kmcoge5un.

Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
---
 board/keymile/km_arm/kwbimage-memphis.cfg  |    6 +++---
 board/keymile/km_arm/kwbimage.cfg          |    6 +++---
 board/keymile/km_arm/kwbimage_128M16_1.cfg |   25 ++-----------------------
 board/keymile/km_arm/kwbimage_256M8_1.cfg  |   25 ++-----------------------
 4 files changed, 10 insertions(+), 52 deletions(-)

diff --git a/board/keymile/km_arm/kwbimage-memphis.cfg b/board/keymile/km_arm/kwbimage-memphis.cfg
index 6df2ad7..5aa0de2 100644
--- a/board/keymile/km_arm/kwbimage-memphis.cfg
+++ b/board/keymile/km_arm/kwbimage-memphis.cfg
@@ -55,9 +55,9 @@ DATA 0xFFD10008 0x00001100	# MPP Control 2 Register
 DATA 0xFFD100E0 0x1B1B1B1B	# IO Configuration 0 Register
 DATA 0xFFD20134 0x66666666	# L2 RAM Timing 0 Register
 DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1 Register
-DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3 Register
-DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1 Register
-DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0 Register
+
+# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them untouched!
+# If not it could cause KW Exceptions during boot in Fast Corners/High Voltage
 
 #Dram initalization
 DATA 0xFFD01400 0x430004E0	# SDRAM Configuration Register
diff --git a/board/keymile/km_arm/kwbimage.cfg b/board/keymile/km_arm/kwbimage.cfg
index b2f5193..e5e9942 100644
--- a/board/keymile/km_arm/kwbimage.cfg
+++ b/board/keymile/km_arm/kwbimage.cfg
@@ -52,9 +52,9 @@ DATA 0xFFD10008 0x00001100	# MPP Control 2 Register
 DATA 0xFFD100E0 0x1B1B1B1B	# IO Configuration 0 Register
 DATA 0xFFD20134 0x66666666	# L2 RAM Timing 0 Register
 DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1 Register
-DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3 Register
-DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1 Register
-DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0 Register
+
+# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them untouched!
+# If not it could cause KW Exceptions during boot in Fast Corners/High Voltage
 
 #Dram initalization
 DATA 0xFFD01400 0x43000400	# SDRAM Configuration Register
diff --git a/board/keymile/km_arm/kwbimage_128M16_1.cfg b/board/keymile/km_arm/kwbimage_128M16_1.cfg
index bcce907..5de8df7 100644
--- a/board/keymile/km_arm/kwbimage_128M16_1.cfg
+++ b/board/keymile/km_arm/kwbimage_128M16_1.cfg
@@ -98,29 +98,8 @@ DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1 Register
 # bit 19-18: 1, ECC RAM WTC RAM0
 # bit 31-20: ???,Reserve
 
-DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3 Register
-# bit 23-0:  0x000200, Addr Config tuning
-# bit 31-24: 0,        Reserved
-
-# ??? Missing register # CPU RAM Management Control2 Register
-
-DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1 Register
-# bit 15-0:  0x1C00, Opmux Tuning
-# bit 31-16: 0,      Pc Dp Tuning
-
-DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0 Register
-# bit 1-0:   1, addr clk tune
-# bit 3-2:   0, reserved
-# bit 5-4:   0, dtcmp clk tune
-# bit 7-6:   0, reserved
-# bit 9-8:   0, macdrv clk tune
-# bit 11-10: 0, opmuxgm2 clk tune
-# bit 15-14: 0, rf clk tune
-# bit 17-16: 0, rfbypass clk tune
-# bit 19-18: 0, pc dp clk tune
-# bit 23-20: 0, icache clk tune
-# bit 27:24: 0, dcache clk tune
-# bit 31:28: 0, regfile tunin
+# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them untouched!
+# If not it could cause KW Exceptions during boot in Fast Corners/High Voltage
 
 # SDRAM initalization
 DATA 0xFFD01400 0x430004E0	# SDRAM Configuration Register
diff --git a/board/keymile/km_arm/kwbimage_256M8_1.cfg b/board/keymile/km_arm/kwbimage_256M8_1.cfg
index 3e1237b..d0a09f6 100644
--- a/board/keymile/km_arm/kwbimage_256M8_1.cfg
+++ b/board/keymile/km_arm/kwbimage_256M8_1.cfg
@@ -100,29 +100,8 @@ DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1 Register
 # bit 19-18: 1, ECC RAM WTC RAM0
 # bit 31-20: ?,Reserved
 
-DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3 Register
-# bit 23-0:  0x000200, Addr Config tuning
-# bit 31-24: 0,        Reserved
-
-# ??? Missing register # CPU RAM Management Control2 Register
-
-DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1 Register
-# bit 15-0:  0x1C00, Opmux Tuning
-# bit 31-16: 0,      Pc Dp Tuning
-
-DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0 Register
-# bit 1-0:   1, addr clk tune
-# bit 3-2:   0, reserved
-# bit 5-4:   0, dtcmp clk tune
-# bit 7-6:   0, reserved
-# bit 9-8:   0, macdrv clk tune
-# bit 11-10: 0, opmuxgm2 clk tune
-# bit 15-14: 0, rf clk tune
-# bit 17-16: 0, rfbypass clk tune
-# bit 19-18: 0, pc dp clk tune
-# bit 23-20: 0, icache clk tune
-# bit 27:24: 0, dcache clk tune
-# bit 31:28: 0, regfile tunin
+# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them untouched!
+# If not it could cause KW Exceptions during boot in Fast Corners/High Voltage
 
 # SDRAM initalization
 DATA 0xFFD01400 0x430004E0	# SDRAM Configuration Register
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 2/4] km/common: drop unneeded std* environment variables
  2012-11-02 10:15 [U-Boot] [PATCH 1/4] arm/km: fix memory settings Holger Brunck
@ 2012-11-02 10:15 ` Holger Brunck
  2012-12-20  6:39   ` Prafulla Wadaskar
  2012-11-02 10:15 ` [U-Boot] [PATCH 3/4] km/common: cosmetic change reported from checkpatch Holger Brunck
                   ` (4 subsequent siblings)
  5 siblings, 1 reply; 15+ messages in thread
From: Holger Brunck @ 2012-11-02 10:15 UTC (permalink / raw)
  To: u-boot

These variables are only used if CONFIG_SYS_CONSOLE_IS_IN_ENV
is set. This isn't the case, so we can drop them safely.

Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
cc: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
---
 include/configs/km/keymile-common.h |    3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/include/configs/km/keymile-common.h b/include/configs/km/keymile-common.h
index 05480d4..f64748e 100644
--- a/include/configs/km/keymile-common.h
+++ b/include/configs/km/keymile-common.h
@@ -253,9 +253,6 @@
 	"load=tftpboot ${load_addr_r} ${u-boot}\0"			\
 	"mtdids=" MTDIDS_DEFAULT "\0"					\
 	"mtdparts=" MTDPARTS_DEFAULT "\0"				\
-	"stderr=serial\0"						\
-	"stdin=serial\0"						\
-	"stdout=serial\0"						\
 	""
 #endif /* CONFIG_KM_DEF_ENV */
 
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 3/4] km/common: cosmetic change reported from checkpatch
  2012-11-02 10:15 [U-Boot] [PATCH 1/4] arm/km: fix memory settings Holger Brunck
  2012-11-02 10:15 ` [U-Boot] [PATCH 2/4] km/common: drop unneeded std* environment variables Holger Brunck
@ 2012-11-02 10:15 ` Holger Brunck
  2012-11-10  7:21   ` Prafulla Wadaskar
  2012-12-20  6:39   ` Prafulla Wadaskar
  2012-11-02 10:15 ` [U-Boot] [PATCH 4/4] arm/km: remove duplicate code Holger Brunck
                   ` (3 subsequent siblings)
  5 siblings, 2 replies; 15+ messages in thread
From: Holger Brunck @ 2012-11-02 10:15 UTC (permalink / raw)
  To: u-boot

Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
cc: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
---
 board/keymile/common/common.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/board/keymile/common/common.c b/board/keymile/common/common.c
index a90f112..6f407b7 100644
--- a/board/keymile/common/common.c
+++ b/board/keymile/common/common.c
@@ -121,7 +121,7 @@ int i2c_make_abort(void)
 {
 
 #if defined(CONFIG_HARD_I2C) && !defined(MACH_TYPE_KM_KIRKWOOD)
-	immap_t *immap = (immap_t *)CONFIG_SYS_IMMR ;
+	immap_t *immap = (immap_t *)CONFIG_SYS_IMMR;
 	i2c8260_t *i2c	= (i2c8260_t *)&immap->im_i2c;
 
 	/*
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 4/4] arm/km: remove duplicate code
  2012-11-02 10:15 [U-Boot] [PATCH 1/4] arm/km: fix memory settings Holger Brunck
  2012-11-02 10:15 ` [U-Boot] [PATCH 2/4] km/common: drop unneeded std* environment variables Holger Brunck
  2012-11-02 10:15 ` [U-Boot] [PATCH 3/4] km/common: cosmetic change reported from checkpatch Holger Brunck
@ 2012-11-02 10:15 ` Holger Brunck
  2012-11-10  7:21   ` Prafulla Wadaskar
  2012-12-20  6:39   ` Prafulla Wadaskar
  2012-11-10  7:19 ` [U-Boot] [PATCH 1/4] arm/km: fix memory settings Prafulla Wadaskar
                   ` (2 subsequent siblings)
  5 siblings, 2 replies; 15+ messages in thread
From: Holger Brunck @ 2012-11-02 10:15 UTC (permalink / raw)
  To: u-boot

From: Valentin Longchamp <valentin.longchamp@keymile.com>

This patch removes 2 small portions of board specific code that are
duplicated with common ARM code and thus unnecessary. These 2 portions
of code concern the mach id that is given by u-boot to the Linux kernel
to identify the system's MACH.

The first one was the possibility to change the MACH thanks to the
'mach_id' enviroment variable. This is possible thanks to the 'machid'
env variable (see arch/arm/lib/bootm.c:boot_jump_linux()).

The seconde one is the setting of the bi_arch_number. This is already
done in arch/arm/lib/board.c:board_init_f() since km_arm.h does #define
CONFIG_MACH_TYPE.

Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
---
 board/keymile/km_arm/km_arm.c |   14 --------------
 1 files changed, 0 insertions(+), 14 deletions(-)

diff --git a/board/keymile/km_arm/km_arm.c b/board/keymile/km_arm/km_arm.c
index 0c4dddc..262b8d2 100644
--- a/board/keymile/km_arm/km_arm.c
+++ b/board/keymile/km_arm/km_arm.c
@@ -193,15 +193,6 @@ void set_bootcount_addr(void)
 
 int misc_init_r(void)
 {
-	char *str;
-	int mach_type;
-
-	str = getenv("mach_type");
-	if (str != NULL) {
-		mach_type = simple_strtoul(str, NULL, 10);
-		printf("Overwriting MACH_TYPE with %d!!!\n", mach_type);
-		gd->bd->bi_arch_number = mach_type;
-	}
 #if defined(CONFIG_KM_MGCOGE3UN)
 	char *wait_for_ne;
 	wait_for_ne = getenv("waitforne");
@@ -258,11 +249,6 @@ int board_early_init_f(void)
 
 int board_init(void)
 {
-	/*
-	 * arch number of board
-	 */
-	gd->bd->bi_arch_number = MACH_TYPE_KM_KIRKWOOD;
-
 	/* address of boot parameters */
 	gd->bd->bi_boot_params = kw_sdram_bar(0) + 0x100;
 
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 1/4] arm/km: fix memory settings
  2012-11-02 10:15 [U-Boot] [PATCH 1/4] arm/km: fix memory settings Holger Brunck
                   ` (2 preceding siblings ...)
  2012-11-02 10:15 ` [U-Boot] [PATCH 4/4] arm/km: remove duplicate code Holger Brunck
@ 2012-11-10  7:19 ` Prafulla Wadaskar
  2012-11-12 10:26   ` Holger Brunck
  2012-12-17 12:42 ` Holger Brunck
  2012-12-20  6:38 ` Prafulla Wadaskar
  5 siblings, 1 reply; 15+ messages in thread
From: Prafulla Wadaskar @ 2012-11-10  7:19 UTC (permalink / raw)
  To: u-boot



> -----Original Message-----
> From: Holger Brunck [mailto:holger.brunck at keymile.com]
> Sent: 02 November 2012 15:45
> To: u-boot at lists.denx.de
> Cc: Holger Brunck; Valentin Longchamp; Prafulla Wadaskar
> Subject: [PATCH 1/4] arm/km: fix memory settings
> 
> On kmcoge5un we faced some serious problems with the memory during
> temperature tests. Reason was that we overwrite some registers for
> memory settings which have to leave untouched. These where registers
> 0x20148 , 0x2014c and 0x20154.
> So writing these registers is prohibited and this patch removes them
> from all km related config files. Even if the problem was only
> seen on kmcoge5un.
> 
> Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
> Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
> cc: Prafulla Wadaskar <prafulla@marvell.com>
> ---
>  board/keymile/km_arm/kwbimage-memphis.cfg  |    6 +++---
>  board/keymile/km_arm/kwbimage.cfg          |    6 +++---
>  board/keymile/km_arm/kwbimage_128M16_1.cfg |   25 ++-----------------
> ------
>  board/keymile/km_arm/kwbimage_256M8_1.cfg  |   25 ++-----------------
> ------
>  4 files changed, 10 insertions(+), 52 deletions(-)
> 
> diff --git a/board/keymile/km_arm/kwbimage-memphis.cfg
> b/board/keymile/km_arm/kwbimage-memphis.cfg
> index 6df2ad7..5aa0de2 100644
> --- a/board/keymile/km_arm/kwbimage-memphis.cfg
> +++ b/board/keymile/km_arm/kwbimage-memphis.cfg
> @@ -55,9 +55,9 @@ DATA 0xFFD10008 0x00001100	# MPP Control 2
> Register
>  DATA 0xFFD100E0 0x1B1B1B1B	# IO Configuration 0 Register
>  DATA 0xFFD20134 0x66666666	# L2 RAM Timing 0 Register
>  DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1 Register
> -DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3 Register
> -DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1 Register
> -DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0 Register

I think this should be applicable to other Kirkwood boards too.

> +
> +# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them
> untouched!
> +# If not it could cause KW Exceptions during boot in Fast
> Corners/High Voltage

Since you are removing above three lines, do you think the above comments are needed in this cfg file? I think you can even remove these comments too because you are not at all providing configuration for this address.

I think simple you can remove these lines from the code.

Same applicable for rest of the files too.

Regards...
Prafulla . . .

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 4/4] arm/km: remove duplicate code
  2012-11-02 10:15 ` [U-Boot] [PATCH 4/4] arm/km: remove duplicate code Holger Brunck
@ 2012-11-10  7:21   ` Prafulla Wadaskar
  2012-12-20  6:39   ` Prafulla Wadaskar
  1 sibling, 0 replies; 15+ messages in thread
From: Prafulla Wadaskar @ 2012-11-10  7:21 UTC (permalink / raw)
  To: u-boot



> -----Original Message-----
> From: Holger Brunck [mailto:holger.brunck at keymile.com]
> Sent: 02 November 2012 15:45
> To: u-boot at lists.denx.de
> Cc: Valentin Longchamp; Holger Brunck; Prafulla Wadaskar
> Subject: [PATCH 4/4] arm/km: remove duplicate code
> 
> From: Valentin Longchamp <valentin.longchamp@keymile.com>
> 
> This patch removes 2 small portions of board specific code that are
> duplicated with common ARM code and thus unnecessary. These 2 portions
> of code concern the mach id that is given by u-boot to the Linux
> kernel
> to identify the system's MACH.
> 
> The first one was the possibility to change the MACH thanks to the
> 'mach_id' enviroment variable. This is possible thanks to the 'machid'
> env variable (see arch/arm/lib/bootm.c:boot_jump_linux()).
> 
> The seconde one is the setting of the bi_arch_number. This is already
> done in arch/arm/lib/board.c:board_init_f() since km_arm.h does
> #define
> CONFIG_MACH_TYPE.
> 
> Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
> cc: Holger Brunck <holger.brunck@keymile.com>
> cc: Prafulla Wadaskar <prafulla@marvell.com>
> ---
>  board/keymile/km_arm/km_arm.c |   14 --------------
>  1 files changed, 0 insertions(+), 14 deletions(-)
> 
> diff --git a/board/keymile/km_arm/km_arm.c
> b/board/keymile/km_arm/km_arm.c
> index 0c4dddc..262b8d2 100644
> --- a/board/keymile/km_arm/km_arm.c
> +++ b/board/keymile/km_arm/km_arm.c
> @@ -193,15 +193,6 @@ void set_bootcount_addr(void)
> 
>  int misc_init_r(void)
>  {
> -	char *str;
> -	int mach_type;
> -
> -	str = getenv("mach_type");
> -	if (str != NULL) {
> -		mach_type = simple_strtoul(str, NULL, 10);
> -		printf("Overwriting MACH_TYPE with %d!!!\n", mach_type);
> -		gd->bd->bi_arch_number = mach_type;
> -	}
>  #if defined(CONFIG_KM_MGCOGE3UN)
>  	char *wait_for_ne;
>  	wait_for_ne = getenv("waitforne");
> @@ -258,11 +249,6 @@ int board_early_init_f(void)
> 
>  int board_init(void)
>  {
> -	/*
> -	 * arch number of board
> -	 */
> -	gd->bd->bi_arch_number = MACH_TYPE_KM_KIRKWOOD;
> -
>  	/* address of boot parameters */
>  	gd->bd->bi_boot_params = kw_sdram_bar(0) + 0x100;
> 
> --


Acked-by: Prafulla Wadaskar <Prafulla@marvell.com>

Regards...
Prafulla . . .

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 3/4] km/common: cosmetic change reported from checkpatch
  2012-11-02 10:15 ` [U-Boot] [PATCH 3/4] km/common: cosmetic change reported from checkpatch Holger Brunck
@ 2012-11-10  7:21   ` Prafulla Wadaskar
  2012-12-20  6:39   ` Prafulla Wadaskar
  1 sibling, 0 replies; 15+ messages in thread
From: Prafulla Wadaskar @ 2012-11-10  7:21 UTC (permalink / raw)
  To: u-boot



> -----Original Message-----
> From: Holger Brunck [mailto:holger.brunck at keymile.com]
> Sent: 02 November 2012 15:45
> To: u-boot at lists.denx.de
> Cc: Holger Brunck; Valentin Longchamp; Prafulla Wadaskar
> Subject: [PATCH 3/4] km/common: cosmetic change reported from
> checkpatch
> 
> Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
> cc: Valentin Longchamp <valentin.longchamp@keymile.com>
> cc: Prafulla Wadaskar <prafulla@marvell.com>
> ---
>  board/keymile/common/common.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/board/keymile/common/common.c
> b/board/keymile/common/common.c
> index a90f112..6f407b7 100644
> --- a/board/keymile/common/common.c
> +++ b/board/keymile/common/common.c
> @@ -121,7 +121,7 @@ int i2c_make_abort(void)
>  {
> 
>  #if defined(CONFIG_HARD_I2C) && !defined(MACH_TYPE_KM_KIRKWOOD)
> -	immap_t *immap = (immap_t *)CONFIG_SYS_IMMR ;
> +	immap_t *immap = (immap_t *)CONFIG_SYS_IMMR;
>  	i2c8260_t *i2c	= (i2c8260_t *)&immap->im_i2c;
> 
>  	/*
> --


Acked-by: Prafulla Wadaskar <Prafulla@marvell.com>

Regards...
Prafulla . . .

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 1/4] arm/km: fix memory settings
  2012-11-10  7:19 ` [U-Boot] [PATCH 1/4] arm/km: fix memory settings Prafulla Wadaskar
@ 2012-11-12 10:26   ` Holger Brunck
  2012-11-12 10:42     ` Prafulla Wadaskar
  0 siblings, 1 reply; 15+ messages in thread
From: Holger Brunck @ 2012-11-12 10:26 UTC (permalink / raw)
  To: u-boot

Hi Prafulla,

On 11/10/2012 08:19 AM, Prafulla Wadaskar wrote:
>> On kmcoge5un we faced some serious problems with the memory during
>> temperature tests. Reason was that we overwrite some registers for
>> memory settings which have to leave untouched. These where registers
>> 0x20148 , 0x2014c and 0x20154.
>> So writing these registers is prohibited and this patch removes them
>> from all km related config files. Even if the problem was only
>> seen on kmcoge5un.
>>
>> Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
>> Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
>> cc: Prafulla Wadaskar <prafulla@marvell.com>
>> ---
>>  board/keymile/km_arm/kwbimage-memphis.cfg  |    6 +++---
>>  board/keymile/km_arm/kwbimage.cfg          |    6 +++---
>>  board/keymile/km_arm/kwbimage_128M16_1.cfg |   25 ++-----------------
>> ------
>>  board/keymile/km_arm/kwbimage_256M8_1.cfg  |   25 ++-----------------
>> ------
>>  4 files changed, 10 insertions(+), 52 deletions(-)
>>
>> diff --git a/board/keymile/km_arm/kwbimage-memphis.cfg
>> b/board/keymile/km_arm/kwbimage-memphis.cfg
>> index 6df2ad7..5aa0de2 100644
>> --- a/board/keymile/km_arm/kwbimage-memphis.cfg
>> +++ b/board/keymile/km_arm/kwbimage-memphis.cfg
>> @@ -55,9 +55,9 @@ DATA 0xFFD10008 0x00001100	# MPP Control 2
>> Register
>>  DATA 0xFFD100E0 0x1B1B1B1B	# IO Configuration 0 Register
>>  DATA 0xFFD20134 0x66666666	# L2 RAM Timing 0 Register
>>  DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1 Register
>> -DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3 Register
>> -DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1 Register
>> -DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0 Register
> 
> I think this should be applicable to other Kirkwood boards too.
> 
>> +
>> +# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them
>> untouched!
>> +# If not it could cause KW Exceptions during boot in Fast
>> Corners/High Voltage
> 
> Since you are removing above three lines, do you think the above comments are needed in this cfg file? I think you can even remove these comments too because you are not at all providing configuration for this address.
> 
> I think simple you can remove these lines from the code.
>

The comment was meant to be a warning for us for the future because the problems
which are due to this writes were hard to debug.

I would like to keep them and due to the fact that these are
"km only" files it should do no harm. But if you still insist I could also drop
them. Just let me know.

Regards
Holger

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 1/4] arm/km: fix memory settings
  2012-11-12 10:26   ` Holger Brunck
@ 2012-11-12 10:42     ` Prafulla Wadaskar
  0 siblings, 0 replies; 15+ messages in thread
From: Prafulla Wadaskar @ 2012-11-12 10:42 UTC (permalink / raw)
  To: u-boot



> -----Original Message-----
> From: Holger Brunck [mailto:holger.brunck at keymile.com]
> Sent: 12 November 2012 15:57
> To: Prafulla Wadaskar
> Cc: u-boot at lists.denx.de; Valentin Longchamp
> Subject: Re: [PATCH 1/4] arm/km: fix memory settings
> 
> Hi Prafulla,
> 
> On 11/10/2012 08:19 AM, Prafulla Wadaskar wrote:
> >> On kmcoge5un we faced some serious problems with the memory during
> >> temperature tests. Reason was that we overwrite some registers for
> >> memory settings which have to leave untouched. These where
> registers
> >> 0x20148 , 0x2014c and 0x20154.
> >> So writing these registers is prohibited and this patch removes
> them
> >> from all km related config files. Even if the problem was only
> >> seen on kmcoge5un.
> >>
> >> Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
> >> Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
> >> cc: Prafulla Wadaskar <prafulla@marvell.com>
> >> ---
> >>  board/keymile/km_arm/kwbimage-memphis.cfg  |    6 +++---
> >>  board/keymile/km_arm/kwbimage.cfg          |    6 +++---
> >>  board/keymile/km_arm/kwbimage_128M16_1.cfg |   25 ++--------------
> ---
> >> ------
> >>  board/keymile/km_arm/kwbimage_256M8_1.cfg  |   25 ++--------------
> ---
> >> ------
> >>  4 files changed, 10 insertions(+), 52 deletions(-)
> >>
> >> diff --git a/board/keymile/km_arm/kwbimage-memphis.cfg
> >> b/board/keymile/km_arm/kwbimage-memphis.cfg
> >> index 6df2ad7..5aa0de2 100644
> >> --- a/board/keymile/km_arm/kwbimage-memphis.cfg
> >> +++ b/board/keymile/km_arm/kwbimage-memphis.cfg
> >> @@ -55,9 +55,9 @@ DATA 0xFFD10008 0x00001100	# MPP Control 2
> >> Register
> >>  DATA 0xFFD100E0 0x1B1B1B1B	# IO Configuration 0 Register
> >>  DATA 0xFFD20134 0x66666666	# L2 RAM Timing 0 Register
> >>  DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1 Register
> >> -DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3
> Register
> >> -DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1
> Register
> >> -DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0
> Register
> >
> > I think this should be applicable to other Kirkwood boards too.
> >
> >> +
> >> +# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them
> >> untouched!
> >> +# If not it could cause KW Exceptions during boot in Fast
> >> Corners/High Voltage
> >
> > Since you are removing above three lines, do you think the above
> comments are needed in this cfg file? I think you can even remove
> these comments too because you are not at all providing configuration
> for this address.
> >
> > I think simple you can remove these lines from the code.
> >
> 
> The comment was meant to be a warning for us for the future because
> the problems
> which are due to this writes were hard to debug.
> 
> I would like to keep them and due to the fact that these are
> "km only" files it should do no harm. But if you still insist I could
> also drop
> them. Just let me know.

No need, that's your call :-) I will pull it.


Regards...
Prafulla . . .

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 1/4] arm/km: fix memory settings
  2012-11-02 10:15 [U-Boot] [PATCH 1/4] arm/km: fix memory settings Holger Brunck
                   ` (3 preceding siblings ...)
  2012-11-10  7:19 ` [U-Boot] [PATCH 1/4] arm/km: fix memory settings Prafulla Wadaskar
@ 2012-12-17 12:42 ` Holger Brunck
  2012-12-17 12:51   ` Prafulla Wadaskar
  2012-12-20  6:38 ` Prafulla Wadaskar
  5 siblings, 1 reply; 15+ messages in thread
From: Holger Brunck @ 2012-12-17 12:42 UTC (permalink / raw)
  To: u-boot

Hi Prafulla,

On 11/02/2012 11:15 AM, Holger Brunck wrote:
> On kmcoge5un we faced some serious problems with the memory during
> temperature tests. Reason was that we overwrite some registers for
> memory settings which have to leave untouched. These where registers
> 0x20148 , 0x2014c and 0x20154.
> So writing these registers is prohibited and this patch removes them
> from all km related config files. Even if the problem was only
> seen on kmcoge5un.
> 
> Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
> Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
> cc: Prafulla Wadaskar <prafulla@marvell.com>
> ---
>  board/keymile/km_arm/kwbimage-memphis.cfg  |    6 +++---
>  board/keymile/km_arm/kwbimage.cfg          |    6 +++---
>  board/keymile/km_arm/kwbimage_128M16_1.cfg |   25 ++-----------------------
>  board/keymile/km_arm/kwbimage_256M8_1.cfg  |   25 ++-----------------------
>  4 files changed, 10 insertions(+), 52 deletions(-)
> 

what about this patch serie? They were posted long time ago and we are already
at -rc2 and they are sitting wether in the ARM tree nor in your marvell tree. So
could you please pick up these four?

Thanks,
Holger

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 1/4] arm/km: fix memory settings
  2012-12-17 12:42 ` Holger Brunck
@ 2012-12-17 12:51   ` Prafulla Wadaskar
  0 siblings, 0 replies; 15+ messages in thread
From: Prafulla Wadaskar @ 2012-12-17 12:51 UTC (permalink / raw)
  To: u-boot



> -----Original Message-----
> From: Holger Brunck [mailto:holger.brunck at keymile.com]
> Sent: 17 December 2012 18:13
> To: Prafulla Wadaskar
> Cc: u-boot at lists.denx.de; albert.u.boot at aribaud.net; Longchamp,
> Valentin
> Subject: Re: [PATCH 1/4] arm/km: fix memory settings
> 
> Hi Prafulla,
> 
> On 11/02/2012 11:15 AM, Holger Brunck wrote:
> > On kmcoge5un we faced some serious problems with the memory during
> > temperature tests. Reason was that we overwrite some registers for
> > memory settings which have to leave untouched. These where registers
> > 0x20148 , 0x2014c and 0x20154.
> > So writing these registers is prohibited and this patch removes them
> > from all km related config files. Even if the problem was only
> > seen on kmcoge5un.
> >
> > Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
> > Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
> > cc: Prafulla Wadaskar <prafulla@marvell.com>
> > ---
> >  board/keymile/km_arm/kwbimage-memphis.cfg  |    6 +++---
> >  board/keymile/km_arm/kwbimage.cfg          |    6 +++---
> >  board/keymile/km_arm/kwbimage_128M16_1.cfg |   25 ++---------------
> --------
> >  board/keymile/km_arm/kwbimage_256M8_1.cfg  |   25 ++---------------
> --------
> >  4 files changed, 10 insertions(+), 52 deletions(-)
> >
> 
> what about this patch serie? They were posted long time ago and we are
> already
> at -rc2 and they are sitting wether in the ARM tree nor in your
> marvell tree. So
> could you please pick up these four?

Sure, I am doing the same, I will provide the pull request today.

Regards...
Prafulla . . .

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 1/4] arm/km: fix memory settings
  2012-11-02 10:15 [U-Boot] [PATCH 1/4] arm/km: fix memory settings Holger Brunck
                   ` (4 preceding siblings ...)
  2012-12-17 12:42 ` Holger Brunck
@ 2012-12-20  6:38 ` Prafulla Wadaskar
  5 siblings, 0 replies; 15+ messages in thread
From: Prafulla Wadaskar @ 2012-12-20  6:38 UTC (permalink / raw)
  To: u-boot



> -----Original Message-----
> From: Holger Brunck [mailto:holger.brunck at keymile.com]
> Sent: 02 November 2012 15:45
> To: u-boot at lists.denx.de
> Cc: Holger Brunck; Valentin Longchamp; Prafulla Wadaskar
> Subject: [PATCH 1/4] arm/km: fix memory settings
> 
> On kmcoge5un we faced some serious problems with the memory during
> temperature tests. Reason was that we overwrite some registers for
> memory settings which have to leave untouched. These where registers
> 0x20148 , 0x2014c and 0x20154.
> So writing these registers is prohibited and this patch removes them
> from all km related config files. Even if the problem was only
> seen on kmcoge5un.
> 
> Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
> Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
> cc: Prafulla Wadaskar <prafulla@marvell.com>
> ---
>  board/keymile/km_arm/kwbimage-memphis.cfg  |    6 +++---
>  board/keymile/km_arm/kwbimage.cfg          |    6 +++---
>  board/keymile/km_arm/kwbimage_128M16_1.cfg |   25 ++-----------------
> ------
>  board/keymile/km_arm/kwbimage_256M8_1.cfg  |   25 ++-----------------
> ------
>  4 files changed, 10 insertions(+), 52 deletions(-)
> 
> diff --git a/board/keymile/km_arm/kwbimage-memphis.cfg
> b/board/keymile/km_arm/kwbimage-memphis.cfg
> index 6df2ad7..5aa0de2 100644
> --- a/board/keymile/km_arm/kwbimage-memphis.cfg
> +++ b/board/keymile/km_arm/kwbimage-memphis.cfg
> @@ -55,9 +55,9 @@ DATA 0xFFD10008 0x00001100	# MPP Control 2
> Register
>  DATA 0xFFD100E0 0x1B1B1B1B	# IO Configuration 0 Register
>  DATA 0xFFD20134 0x66666666	# L2 RAM Timing 0 Register
>  DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1 Register
> -DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3 Register
> -DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1 Register
> -DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0 Register
> +
> +# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them
> untouched!
> +# If not it could cause KW Exceptions during boot in Fast
> Corners/High Voltage
> 
>  #Dram initalization
>  DATA 0xFFD01400 0x430004E0	# SDRAM Configuration Register
> diff --git a/board/keymile/km_arm/kwbimage.cfg
> b/board/keymile/km_arm/kwbimage.cfg
> index b2f5193..e5e9942 100644
> --- a/board/keymile/km_arm/kwbimage.cfg
> +++ b/board/keymile/km_arm/kwbimage.cfg
> @@ -52,9 +52,9 @@ DATA 0xFFD10008 0x00001100	# MPP Control 2
> Register
>  DATA 0xFFD100E0 0x1B1B1B1B	# IO Configuration 0 Register
>  DATA 0xFFD20134 0x66666666	# L2 RAM Timing 0 Register
>  DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1 Register
> -DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3 Register
> -DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1 Register
> -DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0 Register
> +
> +# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them
> untouched!
> +# If not it could cause KW Exceptions during boot in Fast
> Corners/High Voltage
> 
>  #Dram initalization
>  DATA 0xFFD01400 0x43000400	# SDRAM Configuration Register
> diff --git a/board/keymile/km_arm/kwbimage_128M16_1.cfg
> b/board/keymile/km_arm/kwbimage_128M16_1.cfg
> index bcce907..5de8df7 100644
> --- a/board/keymile/km_arm/kwbimage_128M16_1.cfg
> +++ b/board/keymile/km_arm/kwbimage_128M16_1.cfg
> @@ -98,29 +98,8 @@ DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1
> Register
>  # bit 19-18: 1, ECC RAM WTC RAM0
>  # bit 31-20: ???,Reserve
> 
> -DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3 Register
> -# bit 23-0:  0x000200, Addr Config tuning
> -# bit 31-24: 0,        Reserved
> -
> -# ??? Missing register # CPU RAM Management Control2 Register
> -
> -DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1 Register
> -# bit 15-0:  0x1C00, Opmux Tuning
> -# bit 31-16: 0,      Pc Dp Tuning
> -
> -DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0 Register
> -# bit 1-0:   1, addr clk tune
> -# bit 3-2:   0, reserved
> -# bit 5-4:   0, dtcmp clk tune
> -# bit 7-6:   0, reserved
> -# bit 9-8:   0, macdrv clk tune
> -# bit 11-10: 0, opmuxgm2 clk tune
> -# bit 15-14: 0, rf clk tune
> -# bit 17-16: 0, rfbypass clk tune
> -# bit 19-18: 0, pc dp clk tune
> -# bit 23-20: 0, icache clk tune
> -# bit 27:24: 0, dcache clk tune
> -# bit 31:28: 0, regfile tunin
> +# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them
> untouched!
> +# If not it could cause KW Exceptions during boot in Fast
> Corners/High Voltage
> 
>  # SDRAM initalization
>  DATA 0xFFD01400 0x430004E0	# SDRAM Configuration Register
> diff --git a/board/keymile/km_arm/kwbimage_256M8_1.cfg
> b/board/keymile/km_arm/kwbimage_256M8_1.cfg
> index 3e1237b..d0a09f6 100644
> --- a/board/keymile/km_arm/kwbimage_256M8_1.cfg
> +++ b/board/keymile/km_arm/kwbimage_256M8_1.cfg
> @@ -100,29 +100,8 @@ DATA 0xFFD20138 0x66666666	# L2 RAM Timing 1
> Register
>  # bit 19-18: 1, ECC RAM WTC RAM0
>  # bit 31-20: ?,Reserved
> 
> -DATA 0xFFD20154 0x00000200	# CPU RAM Management Control3 Register
> -# bit 23-0:  0x000200, Addr Config tuning
> -# bit 31-24: 0,        Reserved
> -
> -# ??? Missing register # CPU RAM Management Control2 Register
> -
> -DATA 0xFFD2014C 0x00001C00	# CPU RAM Management Control1 Register
> -# bit 15-0:  0x1C00, Opmux Tuning
> -# bit 31-16: 0,      Pc Dp Tuning
> -
> -DATA 0xFFD20148 0x00000001	# CPU RAM Management Control0 Register
> -# bit 1-0:   1, addr clk tune
> -# bit 3-2:   0, reserved
> -# bit 5-4:   0, dtcmp clk tune
> -# bit 7-6:   0, reserved
> -# bit 9-8:   0, macdrv clk tune
> -# bit 11-10: 0, opmuxgm2 clk tune
> -# bit 15-14: 0, rf clk tune
> -# bit 17-16: 0, rfbypass clk tune
> -# bit 19-18: 0, pc dp clk tune
> -# bit 23-20: 0, icache clk tune
> -# bit 27:24: 0, dcache clk tune
> -# bit 31:28: 0, regfile tunin
> +# NOTE: Don't write on 0x20148 , 0x2014c and 0x20154, leave them
> untouched!
> +# If not it could cause KW Exceptions during boot in Fast
> Corners/High Voltage
> 
>  # SDRAM initalization
>  DATA 0xFFD01400 0x430004E0	# SDRAM Configuration Register
> --
> 1.7.1

Applied to u-boot-marvell.git master branch

Regards...
Prafulla . . .

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 2/4] km/common: drop unneeded std* environment variables
  2012-11-02 10:15 ` [U-Boot] [PATCH 2/4] km/common: drop unneeded std* environment variables Holger Brunck
@ 2012-12-20  6:39   ` Prafulla Wadaskar
  0 siblings, 0 replies; 15+ messages in thread
From: Prafulla Wadaskar @ 2012-12-20  6:39 UTC (permalink / raw)
  To: u-boot



> -----Original Message-----
> From: Holger Brunck [mailto:holger.brunck at keymile.com]
> Sent: 02 November 2012 15:45
> To: u-boot at lists.denx.de
> Cc: Holger Brunck; Valentin Longchamp; Prafulla Wadaskar
> Subject: [PATCH 2/4] km/common: drop unneeded std* environment
> variables
> 
> These variables are only used if CONFIG_SYS_CONSOLE_IS_IN_ENV
> is set. This isn't the case, so we can drop them safely.
> 
> Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
> cc: Valentin Longchamp <valentin.longchamp@keymile.com>
> cc: Prafulla Wadaskar <prafulla@marvell.com>
> ---
>  include/configs/km/keymile-common.h |    3 ---
>  1 files changed, 0 insertions(+), 3 deletions(-)
> 
> diff --git a/include/configs/km/keymile-common.h
> b/include/configs/km/keymile-common.h
> index 05480d4..f64748e 100644
> --- a/include/configs/km/keymile-common.h
> +++ b/include/configs/km/keymile-common.h
> @@ -253,9 +253,6 @@
>  	"load=tftpboot ${load_addr_r} ${u-boot}\0"			\
>  	"mtdids=" MTDIDS_DEFAULT "\0"					\
>  	"mtdparts=" MTDPARTS_DEFAULT "\0"				\
> -	"stderr=serial\0"						\
> -	"stdin=serial\0"						\
> -	"stdout=serial\0"						\
>  	""
>  #endif /* CONFIG_KM_DEF_ENV */
> 
> --
> 1.7.1

Applied to u-boot-marvell.git master branch

Regards...
Prafulla . . .

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 3/4] km/common: cosmetic change reported from checkpatch
  2012-11-02 10:15 ` [U-Boot] [PATCH 3/4] km/common: cosmetic change reported from checkpatch Holger Brunck
  2012-11-10  7:21   ` Prafulla Wadaskar
@ 2012-12-20  6:39   ` Prafulla Wadaskar
  1 sibling, 0 replies; 15+ messages in thread
From: Prafulla Wadaskar @ 2012-12-20  6:39 UTC (permalink / raw)
  To: u-boot



> -----Original Message-----
> From: Holger Brunck [mailto:holger.brunck at keymile.com]
> Sent: 02 November 2012 15:45
> To: u-boot at lists.denx.de
> Cc: Holger Brunck; Valentin Longchamp; Prafulla Wadaskar
> Subject: [PATCH 3/4] km/common: cosmetic change reported from
> checkpatch
> 
> Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
> cc: Valentin Longchamp <valentin.longchamp@keymile.com>
> cc: Prafulla Wadaskar <prafulla@marvell.com>
> ---
>  board/keymile/common/common.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/board/keymile/common/common.c
> b/board/keymile/common/common.c
> index a90f112..6f407b7 100644
> --- a/board/keymile/common/common.c
> +++ b/board/keymile/common/common.c
> @@ -121,7 +121,7 @@ int i2c_make_abort(void)
>  {
> 
>  #if defined(CONFIG_HARD_I2C) && !defined(MACH_TYPE_KM_KIRKWOOD)
> -	immap_t *immap = (immap_t *)CONFIG_SYS_IMMR ;
> +	immap_t *immap = (immap_t *)CONFIG_SYS_IMMR;
>  	i2c8260_t *i2c	= (i2c8260_t *)&immap->im_i2c;
> 
>  	/*
> --
> 1.7.1

Applied to u-boot-marvell.git master branch

Regards...
Prafulla . . .

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [U-Boot] [PATCH 4/4] arm/km: remove duplicate code
  2012-11-02 10:15 ` [U-Boot] [PATCH 4/4] arm/km: remove duplicate code Holger Brunck
  2012-11-10  7:21   ` Prafulla Wadaskar
@ 2012-12-20  6:39   ` Prafulla Wadaskar
  1 sibling, 0 replies; 15+ messages in thread
From: Prafulla Wadaskar @ 2012-12-20  6:39 UTC (permalink / raw)
  To: u-boot



> -----Original Message-----
> From: Holger Brunck [mailto:holger.brunck at keymile.com]
> Sent: 02 November 2012 15:45
> To: u-boot at lists.denx.de
> Cc: Valentin Longchamp; Holger Brunck; Prafulla Wadaskar
> Subject: [PATCH 4/4] arm/km: remove duplicate code
> 
> From: Valentin Longchamp <valentin.longchamp@keymile.com>
> 
> This patch removes 2 small portions of board specific code that are
> duplicated with common ARM code and thus unnecessary. These 2 portions
> of code concern the mach id that is given by u-boot to the Linux
> kernel
> to identify the system's MACH.
> 
> The first one was the possibility to change the MACH thanks to the
> 'mach_id' enviroment variable. This is possible thanks to the 'machid'
> env variable (see arch/arm/lib/bootm.c:boot_jump_linux()).
> 
> The seconde one is the setting of the bi_arch_number. This is already
> done in arch/arm/lib/board.c:board_init_f() since km_arm.h does
> #define
> CONFIG_MACH_TYPE.
> 
> Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
> cc: Holger Brunck <holger.brunck@keymile.com>
> cc: Prafulla Wadaskar <prafulla@marvell.com>
> ---
>  board/keymile/km_arm/km_arm.c |   14 --------------
>  1 files changed, 0 insertions(+), 14 deletions(-)
> 
> diff --git a/board/keymile/km_arm/km_arm.c
> b/board/keymile/km_arm/km_arm.c
> index 0c4dddc..262b8d2 100644
> --- a/board/keymile/km_arm/km_arm.c
> +++ b/board/keymile/km_arm/km_arm.c
> @@ -193,15 +193,6 @@ void set_bootcount_addr(void)
> 
>  int misc_init_r(void)
>  {
> -	char *str;
> -	int mach_type;
> -
> -	str = getenv("mach_type");
> -	if (str != NULL) {
> -		mach_type = simple_strtoul(str, NULL, 10);
> -		printf("Overwriting MACH_TYPE with %d!!!\n", mach_type);
> -		gd->bd->bi_arch_number = mach_type;
> -	}
>  #if defined(CONFIG_KM_MGCOGE3UN)
>  	char *wait_for_ne;
>  	wait_for_ne = getenv("waitforne");
> @@ -258,11 +249,6 @@ int board_early_init_f(void)
> 
>  int board_init(void)
>  {
> -	/*
> -	 * arch number of board
> -	 */
> -	gd->bd->bi_arch_number = MACH_TYPE_KM_KIRKWOOD;
> -
>  	/* address of boot parameters */
>  	gd->bd->bi_boot_params = kw_sdram_bar(0) + 0x100;
> 
> --
> 1.7.1

Applied to u-boot-marvell.git master branch

Regards...
Prafulla . . .

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2012-12-20  6:39 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-11-02 10:15 [U-Boot] [PATCH 1/4] arm/km: fix memory settings Holger Brunck
2012-11-02 10:15 ` [U-Boot] [PATCH 2/4] km/common: drop unneeded std* environment variables Holger Brunck
2012-12-20  6:39   ` Prafulla Wadaskar
2012-11-02 10:15 ` [U-Boot] [PATCH 3/4] km/common: cosmetic change reported from checkpatch Holger Brunck
2012-11-10  7:21   ` Prafulla Wadaskar
2012-12-20  6:39   ` Prafulla Wadaskar
2012-11-02 10:15 ` [U-Boot] [PATCH 4/4] arm/km: remove duplicate code Holger Brunck
2012-11-10  7:21   ` Prafulla Wadaskar
2012-12-20  6:39   ` Prafulla Wadaskar
2012-11-10  7:19 ` [U-Boot] [PATCH 1/4] arm/km: fix memory settings Prafulla Wadaskar
2012-11-12 10:26   ` Holger Brunck
2012-11-12 10:42     ` Prafulla Wadaskar
2012-12-17 12:42 ` Holger Brunck
2012-12-17 12:51   ` Prafulla Wadaskar
2012-12-20  6:38 ` Prafulla Wadaskar

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.