Patchwork [U-Boot,2/3] tegra2: Fix default RAM size selection in odmdata

login
register
mail settings
Submitter Stephen Warren
Date Jan. 6, 2012, 10:14 p.m.
Message ID <1325888082-20027-2-git-send-email-swarren@nvidia.com>
Download mbox | patch
Permalink /patch/134708/
State Accepted
Commit 9057e652c30d8b2f4d9f3613a3923bd191843487
Headers show

Comments

Stephen Warren - Jan. 6, 2012, 10:14 p.m.
A value of 0 in the odmdata RAM size field means default, which is 512MB
not 1GB. Fix this. For reference, see:

http://nv-tegra.nvidia.com/gitweb/?p=linux-2.6.git;a=blob;\
f=arch/arm/mach-tegra/odm_kit/query/harmony/tegra_devkit_custopt.h;\
h=1ec7010911454f19a5018952fd245785a62c59ad;\
hb=0e52d7fe25b11a656c376a37890be219470661fb

v2: New patch

Signed-off-by: Stephen Warren <swarren@nvidia.com>
---
 arch/arm/cpu/armv7/tegra2/board.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
Simon Glass - Jan. 9, 2012, 7:39 p.m.
On Fri, Jan 6, 2012 at 2:14 PM, Stephen Warren <swarren@nvidia.com> wrote:
> A value of 0 in the odmdata RAM size field means default, which is 512MB
> not 1GB. Fix this. For reference, see:
>
> http://nv-tegra.nvidia.com/gitweb/?p=linux-2.6.git;a=blob;\
> f=arch/arm/mach-tegra/odm_kit/query/harmony/tegra_devkit_custopt.h;\
> h=1ec7010911454f19a5018952fd245785a62c59ad;\
> hb=0e52d7fe25b11a656c376a37890be219470661fb
>
> v2: New patch
>
> Signed-off-by: Stephen Warren <swarren@nvidia.com>

Tested on a Seaboard with 1GB RAM.

Acked-by: Simon Glass <sjg@chromium.org>
Tested-by: Simon Glass <sjg@chromium.org>

> ---
>  arch/arm/cpu/armv7/tegra2/board.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/arch/arm/cpu/armv7/tegra2/board.c b/arch/arm/cpu/armv7/tegra2/board.c
> index ea06570..404d34c 100644
> --- a/arch/arm/cpu/armv7/tegra2/board.c
> +++ b/arch/arm/cpu/armv7/tegra2/board.c
> @@ -58,9 +58,9 @@ unsigned int query_sdram_size(void)
>        case 1:
>                return 0x10000000;      /* 256 MB */
>        case 2:
> +       default:
>                return 0x20000000;      /* 512 MB */
>        case 3:
> -       default:
>                return 0x40000000;      /* 1GB */
>        }
>  }
> --
> 1.7.0.4
>

Patch

diff --git a/arch/arm/cpu/armv7/tegra2/board.c b/arch/arm/cpu/armv7/tegra2/board.c
index ea06570..404d34c 100644
--- a/arch/arm/cpu/armv7/tegra2/board.c
+++ b/arch/arm/cpu/armv7/tegra2/board.c
@@ -58,9 +58,9 @@  unsigned int query_sdram_size(void)
 	case 1:
 		return 0x10000000;	/* 256 MB */
 	case 2:
+	default:
 		return 0x20000000;	/* 512 MB */
 	case 3:
-	default:
 		return 0x40000000;	/* 1GB */
 	}
 }