> -----Original Message-----
> From: [email protected] [mailto:linux-omap-
> [email protected]] On Behalf Of Vikram Pandita
> Sent: Saturday, July 10, 2010 12:39 PM
> To: [email protected]
> Cc: Pandita, Vikram
> Subject: [PATCH 3/3] omap4: SRAM start and size change for EMU/HS devices
> 
> On OMAP4 the SRAM configuration is:
> GP Device:
>         Start Address: 0x4030 0000
>         Size: 0xE000 (56KB)
> 
> EMU/HS Device:
>         Start Address: 0x4030 4000
>         Size: 0xA000 (40KB)
> 
> Implement this mapping in the sram file
> 
> Signed-off-by: Vikram Pandita <[email protected]>
> ---
>  arch/arm/plat-omap/sram.c |   17 +++++++++++++----
>  1 files changed, 13 insertions(+), 4 deletions(-)
> 
> diff --git a/arch/arm/plat-omap/sram.c b/arch/arm/plat-omap/sram.c
> index 112b807..3c7c9a6 100644
> --- a/arch/arm/plat-omap/sram.c
> +++ b/arch/arm/plat-omap/sram.c
> @@ -53,7 +53,7 @@
>  #define OMAP4_SRAM_PUB_PA    (OMAP4_SRAM_PA + 0x4000)
>  #define OMAP4_SRAM_PUB_VA    (OMAP4_SRAM_VA + 0x4000)
> 
> -#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
> +#if defined(CONFIG_ARCH_OMAP2PLUS)
Only this line needs to be added in this patch
>  #define SRAM_BOOTLOADER_SZ   0x00
>  #else
>  #define SRAM_BOOTLOADER_SZ   0x80
> @@ -134,9 +134,18 @@ void __init omap_detect_sram(void)
>                                       omap_sram_size = 0x8000; /* 32K */
>                               }
>                       } else if (cpu_is_omap44xx()) {
> -                             omap_sram_base = OMAP4_SRAM_PUB_VA;
> -                             omap_sram_start = OMAP4_SRAM_PUB_PA;
> -                             omap_sram_size = 0xa000; /* 40K */
> +                             if ((omap_type() == OMAP2_DEVICE_TYPE_EMU) ||
> +                                 (omap_type() == OMAP2_DEVICE_TYPE_SEC)) {
> +                                     /* 40K For Public SRAM */
> +                                     omap_sram_base = OMAP4_SRAM_PUB_VA;
> +                                     omap_sram_start = OMAP4_SRAM_PUB_PA;
> +                                     omap_sram_size = 0xA000;
> +                             } else {
> +                                     /* 56 KB SRAM on GP device */
> +                                     omap_sram_base = OMAP4_SRAM_VA;
> +                                     omap_sram_start = OMAP4_SRAM_PA;
> +                                     omap_sram_size = 0xE000;

Not necessary. If the "is_sram_locked" retunrs the correct retun value then 
this already handled.

Just look below the else part which handles the GP and if already has EMU size.
> +                             }
>                       } else {
>                               omap_sram_base = OMAP2_SRAM_PUB_VA;
>                               omap_sram_start = OMAP2_SRAM_PUB_PA;
> --
> 1.6.6.1
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to [email protected]
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to