]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
TI: OMAP3: Remove SZ_xx references
authorSandeep Paulraj <s-paulraj@ti.com>
Wed, 9 Sep 2009 15:50:40 +0000 (11:50 -0400)
committerTom Rix <Tom.Rix@windriver.com>
Sun, 18 Oct 2009 21:52:52 +0000 (16:52 -0500)
This patch removes dependency on the sizes.h header file
and removes all references to SZ_xx.

Signed-off-by: Sandeep Paulraj <s-paulraj@ti.com>
cpu/arm_cortexa8/omap3/mem.c
cpu/arm_cortexa8/omap3/sys_info.c
include/configs/devkit8000.h
include/configs/omap3_beagle.h
include/configs/omap3_evm.h
include/configs/omap3_overo.h
include/configs/omap3_pandora.h
include/configs/omap3_zoom1.h
include/configs/omap3_zoom2.h

index 079c8487019cc14fca6750a4fef902f5ce374b82..b4dec39881d9c3fa8ef0b445fbfecd02b3f83f63 100644 (file)
@@ -92,7 +92,7 @@ void make_cs1_contiguous(void)
        u32 size, a_add_low, a_add_high;
 
        size = get_sdr_cs_size(CS0);
-       size /= SZ_32M;                 /* find size to offset CS1 */
+       size >>= 25;    /* divide by 32 MiB to find size to offset CS1 */
        a_add_high = (size & 3) << 8;   /* set up low field */
        a_add_low = (size & 0x3C) >> 2; /* set up high field */
        writel((a_add_high | a_add_low), &sdrc_base->cs_cfg);
@@ -249,7 +249,7 @@ void gpmc_init(void)
        enable_gpmc_cs_config(gpmc_config, &gpmc_cfg->cs[0], base, size);
 #if defined(CONFIG_ENV_IS_IN_NAND)
        f_off = SMNAND_ENV_OFFSET;
-       f_sec = SZ_128K;
+       f_sec = (128 << 10);    /* 128 KiB */
        /* env setup */
        boot_flash_base = base;
        boot_flash_off = f_off;
@@ -265,7 +265,7 @@ void gpmc_init(void)
        enable_gpmc_cs_config(gpmc_config, &gpmc_cfg->cs[0], base, size);
 #if defined(CONFIG_ENV_IS_IN_ONENAND)
        f_off = ONENAND_ENV_OFFSET;
-       f_sec = SZ_128K;
+       f_sec = (128 << 10);    /* 128 KiB */
        /* env setup */
        boot_flash_base = base;
        boot_flash_off = f_off;
index 765aaf2b376901394ea4ad1189ad73628ef1d1ac..31b20033ccc7fc531248558419cf7f171d7324a3 100644 (file)
@@ -124,7 +124,7 @@ u32 get_sdr_cs_size(u32 cs)
        /* get ram size field */
        size = readl(&sdrc_base->cs[cs].mcfg) >> 8;
        size &= 0x3FF;          /* remove unwanted bits */
-       size *= SZ_2M;          /* find size in MB */
+       size <<= 21;            /* multiply by 2 MiB to find size in MB */
        return size;
 }
 
index a8ac786c64cd6b8ba0cb54b5e41bf965ba51124c..bd5037e910d27156fb2b8dceb524e854422392ac 100644 (file)
@@ -30,7 +30,6 @@
 
 #ifndef __CONFIG_H
 #define __CONFIG_H
-#include <asm/sizes.h>
 
 /* High Level Configuration Options */
 #define CONFIG_ARMCORTEXA8     1       /* This is an ARM V7 CPU core */
@@ -59,9 +58,9 @@
 #define CONFIG_REVISION_TAG            1
 
 /* Size of malloc() pool */
-#define CONFIG_ENV_SIZE                        SZ_128K /* Total Size Environment */
+#define CONFIG_ENV_SIZE                        (128 << 10)     /* 128 KiB */
                                                /* Sector */
-#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + SZ_128K)
+#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + (128 << 10))
 #define CONFIG_SYS_GBL_DATA_SIZE       128     /* bytes reserved for */
                                                /* initial data */
 
 #define CONFIG_SYS_HZ                  1000
 
 /* The stack sizes are set up in start.S using the settings below */
-#define CONFIG_STACKSIZE               SZ_128K /* regular stack */
+#define CONFIG_STACKSIZE       (128 << 10)     /* regular stack 128 KiB */
 #ifdef CONFIG_USE_IRQ
-#define CONFIG_STACKSIZE_IRQ           SZ_4K   /* IRQ stack */
-#define CONFIG_STACKSIZE_FIQ           SZ_4K   /* FIQ stack */
+#define CONFIG_STACKSIZE_IRQ           (4 << 10)       /* IRQ stack 4 KiB */
+#define CONFIG_STACKSIZE_FIQ           (4 << 10)       /* FIQ stack 4 KiB */
 #endif
 
 /*  Physical Memory Map  */
 #define CONFIG_NR_DRAM_BANKS           2 /* CS1 may or may not be populated */
 #define PHYS_SDRAM_1                   OMAP34XX_SDRC_CS0
-#define PHYS_SDRAM_1_SIZE              SZ_128M /* at least 128 meg */
+#define PHYS_SDRAM_1_SIZE              (128 << 20)     /* at least 128 MiB */
 #define PHYS_SDRAM_2                   OMAP34XX_SDRC_CS1
 
 /* SDRAM Bank Allocation method */
 /* NAND and environment organization  */
 #define PISMO1_NAND_SIZE               GPMC_SIZE_128M
 
-#define CONFIG_SYS_MONITOR_LEN         SZ_256K /* Reserve 2 sectors */
+#define CONFIG_SYS_MONITOR_LEN         (256 << 10)     /* Reserve 2 sectors */
 
 #define CONFIG_ENV_IS_IN_NAND          1
 #define SMNAND_ENV_OFFSET              0x260000 /* environment starts here */
index 18dd3bce7f95186ab23e813a6573618cc0d1e752..19a5ec92ece5f029cf6cbd3d977538bdf6b5088a 100644 (file)
@@ -27,7 +27,6 @@
 
 #ifndef __CONFIG_H
 #define __CONFIG_H
-#include <asm/sizes.h>
 
 /*
  * High Level Configuration Options
@@ -62,9 +61,9 @@
 /*
  * Size of malloc() pool
  */
-#define CONFIG_ENV_SIZE                        SZ_128K /* Total Size Environment */
+#define CONFIG_ENV_SIZE                        (128 << 10)     /* 128 KiB */
                                                /* Sector */
-#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + SZ_128K)
+#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + (128 << 10))
 #define CONFIG_SYS_GBL_DATA_SIZE       128     /* bytes reserved for */
                                                /* initial data */
 
  *
  * The stack sizes are set up in start.S using the settings below
  */
-#define CONFIG_STACKSIZE       SZ_128K /* regular stack */
+#define CONFIG_STACKSIZE       (128 << 10)     /* regular stack 128 KiB */
 #ifdef CONFIG_USE_IRQ
-#define CONFIG_STACKSIZE_IRQ   SZ_4K   /* IRQ stack */
-#define CONFIG_STACKSIZE_FIQ   SZ_4K   /* FIQ stack */
+#define CONFIG_STACKSIZE_IRQ   (4 << 10)       /* IRQ stack 4 KiB */
+#define CONFIG_STACKSIZE_FIQ   (4 << 10)       /* FIQ stack 4 KiB */
 #endif
 
 /*-----------------------------------------------------------------------
  */
 #define CONFIG_NR_DRAM_BANKS   2       /* CS1 may or may not be populated */
 #define PHYS_SDRAM_1           OMAP34XX_SDRC_CS0
-#define PHYS_SDRAM_1_SIZE      SZ_32M  /* at least 32 meg */
+#define PHYS_SDRAM_1_SIZE      (32 << 20)      /* at least 32 MiB */
 #define PHYS_SDRAM_2           OMAP34XX_SDRC_CS1
 
 /* SDRAM Bank Allocation method */
 #define CONFIG_SYS_MAX_FLASH_SECT      520     /* max number of sectors on */
                                                /* one chip */
 #define CONFIG_SYS_MAX_FLASH_BANKS     2       /* max number of flash banks */
-#define CONFIG_SYS_MONITOR_LEN         SZ_256K /* Reserve 2 sectors */
+#define CONFIG_SYS_MONITOR_LEN         (256 << 10)     /* Reserve 2 sectors */
 
 #define CONFIG_SYS_FLASH_BASE          boot_flash_base
 
index 72e9626963400061059aa7205c9526823ddb02c7..a5514aeb9b4684159257671685f75971486800fe 100644 (file)
@@ -32,7 +32,6 @@
 
 #ifndef __CONFIG_H
 #define __CONFIG_H
-#include <asm/sizes.h>
 
 /*
  * High Level Configuration Options
@@ -67,9 +66,9 @@
 /*
  * Size of malloc() pool
  */
-#define CONFIG_ENV_SIZE                        SZ_128K /* Total Size Environment */
+#define CONFIG_ENV_SIZE                        (128 << 10)     /* 128 KiB */
                                                /* Sector */
-#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + SZ_128K)
+#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + (128 << 10))
 #define CONFIG_SYS_GBL_DATA_SIZE       128     /* bytes reserved for */
                                                /* initial data */
 /*
  *
  * The stack sizes are set up in start.S using the settings below
  */
-#define CONFIG_STACKSIZE       SZ_128K /* regular stack */
+#define CONFIG_STACKSIZE       (128 << 10)     /* regular stack 128 KiB */
 #ifdef CONFIG_USE_IRQ
-#define CONFIG_STACKSIZE_IRQ   SZ_4K   /* IRQ stack */
-#define CONFIG_STACKSIZE_FIQ   SZ_4K   /* FIQ stack */
+#define CONFIG_STACKSIZE_IRQ   (4 << 10)       /* IRQ stack 4 KiB */
+#define CONFIG_STACKSIZE_FIQ   (4 << 10)       /* FIQ stack 4 KiB */
 #endif
 
 /*-----------------------------------------------------------------------
  */
 #define CONFIG_NR_DRAM_BANKS   2       /* CS1 may or may not be populated */
 #define PHYS_SDRAM_1           OMAP34XX_SDRC_CS0
-#define PHYS_SDRAM_1_SIZE      SZ_32M  /* at least 32 meg */
+#define PHYS_SDRAM_1_SIZE      (32 << 20)      /* at least 32 MiB */
 #define PHYS_SDRAM_2           OMAP34XX_SDRC_CS1
 
 /* SDRAM Bank Allocation method */
 #define CONFIG_SYS_MAX_FLASH_SECT      520     /* max number of sectors */
                                                /* on one chip */
 #define CONFIG_SYS_MAX_FLASH_BANKS     2       /* max number of flash banks */
-#define CONFIG_SYS_MONITOR_LEN         SZ_256K /* Reserve 2 sectors */
+#define CONFIG_SYS_MONITOR_LEN         (256 << 10)     /* Reserve 2 sectors */
 
 #define CONFIG_SYS_FLASH_BASE          boot_flash_base
 
index 8554c01599f7c8f68baa55e0f08d5ecdeeb5c727..ffb515d32237d747953a6a2931b71b2122a35697 100644 (file)
@@ -19,7 +19,6 @@
 
 #ifndef __CONFIG_H
 #define __CONFIG_H
-#include <asm/sizes.h>
 
 /*
  * High Level Configuration Options
@@ -54,9 +53,9 @@
 /*
  * Size of malloc() pool
  */
-#define CONFIG_ENV_SIZE                        SZ_128K /* Total Size Environment */
+#define CONFIG_ENV_SIZE                        (128 << 10)     /* 128 KiB */
                                                /* Sector */
-#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + SZ_128K)
+#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + (128 << 10))
 #define CONFIG_SYS_GBL_DATA_SIZE       128     /* bytes reserved for */
                                                /* initial data */
 
  *
  * The stack sizes are set up in start.S using the settings below
  */
-#define CONFIG_STACKSIZE       SZ_128K /* regular stack */
+#define CONFIG_STACKSIZE       (128 << 10)     /* regular stack 128 KiB */
 #ifdef CONFIG_USE_IRQ
-#define CONFIG_STACKSIZE_IRQ   SZ_4K   /* IRQ stack */
-#define CONFIG_STACKSIZE_FIQ   SZ_4K   /* FIQ stack */
+#define CONFIG_STACKSIZE_IRQ   (4 << 10)       /* IRQ stack 4 KiB */
+#define CONFIG_STACKSIZE_FIQ   (4 << 10)       /* FIQ stack 4 KiB */
 #endif
 
 /*-----------------------------------------------------------------------
  */
 #define CONFIG_NR_DRAM_BANKS   2       /* CS1 may or may not be populated */
 #define PHYS_SDRAM_1           OMAP34XX_SDRC_CS0
-#define PHYS_SDRAM_1_SIZE      SZ_32M  /* at least 32 meg */
+#define PHYS_SDRAM_1_SIZE      (32 << 20)      /* at least 32 MiB */
 #define PHYS_SDRAM_2           OMAP34XX_SDRC_CS1
 
 /* SDRAM Bank Allocation method */
 #define CONFIG_SYS_MAX_FLASH_SECT      520     /* max number of sectors on */
                                                /* one chip */
 #define CONFIG_SYS_MAX_FLASH_BANKS     2       /* max number of flash banks */
-#define CONFIG_SYS_MONITOR_LEN         SZ_256K /* Reserve 2 sectors */
+#define CONFIG_SYS_MONITOR_LEN         (256 << 10)     /* Reserve 2 sectors */
 
 #define CONFIG_SYS_FLASH_BASE          boot_flash_base
 
index 064c0bc69006348b3c6d74a71c82d5da27a05244..6f21af3d1332358ec5a04bd24d58f92a6de027dc 100644 (file)
@@ -22,7 +22,6 @@
 
 #ifndef __CONFIG_H
 #define __CONFIG_H
-#include <asm/sizes.h>
 
 /*
  * High Level Configuration Options
@@ -57,9 +56,9 @@
 /*
  * Size of malloc() pool
  */
-#define CONFIG_ENV_SIZE                        SZ_128K /* Total Size Environment */
+#define CONFIG_ENV_SIZE                        (128 << 10)     /* 128 KiB */
                                                /* Sector */
-#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + SZ_128K)
+#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + (128 << 10))
 #define CONFIG_SYS_GBL_DATA_SIZE       128     /* bytes reserved for */
                                                /* initial data */
 
  *
  * The stack sizes are set up in start.S using the settings below
  */
-#define CONFIG_STACKSIZE       SZ_128K /* regular stack */
+#define CONFIG_STACKSIZE       (128 << 10)     /* regular stack 128 KiB */
 #ifdef CONFIG_USE_IRQ
-#define CONFIG_STACKSIZE_IRQ   SZ_4K   /* IRQ stack */
-#define CONFIG_STACKSIZE_FIQ   SZ_4K   /* FIQ stack */
+#define CONFIG_STACKSIZE_IRQ   (4 << 10)       /* IRQ stack 4 KiB */
+#define CONFIG_STACKSIZE_FIQ   (4 << 10)       /* FIQ stack 4 KiB */
 #endif
 
 /*-----------------------------------------------------------------------
  */
 #define CONFIG_NR_DRAM_BANKS   2       /* CS1 may or may not be populated */
 #define PHYS_SDRAM_1           OMAP34XX_SDRC_CS0
-#define PHYS_SDRAM_1_SIZE      SZ_32M  /* at least 32 meg */
+#define PHYS_SDRAM_1_SIZE      (32 << 20)      /* at least 32 MiB */
 #define PHYS_SDRAM_2           OMAP34XX_SDRC_CS1
 
 /* SDRAM Bank Allocation method */
 #define CONFIG_SYS_MAX_FLASH_SECT      520     /* max number of sectors on */
                                                /* one chip */
 #define CONFIG_SYS_MAX_FLASH_BANKS     2       /* max number of flash banks */
-#define CONFIG_SYS_MONITOR_LEN         SZ_256K /* Reserve 2 sectors */
+#define CONFIG_SYS_MONITOR_LEN         (256 << 10)     /* Reserve 2 sectors */
 
 #define CONFIG_SYS_FLASH_BASE          boot_flash_base
 
index b55b8f02222d5e7268f1b9aaf577b6ac5d2aacc8..da4b677f93c450c9bd0c62dac14b32726a95653c 100644 (file)
@@ -28,7 +28,6 @@
 
 #ifndef __CONFIG_H
 #define __CONFIG_H
-#include <asm/sizes.h>
 
 /*
  * High Level Configuration Options
@@ -63,9 +62,9 @@
 /*
  * Size of malloc() pool
  */
-#define CONFIG_ENV_SIZE                        SZ_128K /* Total Size Environment */
+#define CONFIG_ENV_SIZE                        (128 << 10)     /* 128 KiB */
                                                /* Sector */
-#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + SZ_128K)
+#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + (128 << 10))
 #define CONFIG_SYS_GBL_DATA_SIZE       128     /* bytes reserved for */
                                                /* initial data */
 
  *
  * The stack sizes are set up in start.S using the settings below
  */
-#define CONFIG_STACKSIZE       SZ_128K /* regular stack */
+#define CONFIG_STACKSIZE       (128 << 10)     /* regular stack 128 KiB */
 #ifdef CONFIG_USE_IRQ
-#define CONFIG_STACKSIZE_IRQ   SZ_4K   /* IRQ stack */
-#define CONFIG_STACKSIZE_FIQ   SZ_4K   /* FIQ stack */
+#define CONFIG_STACKSIZE_IRQ   (4 << 10)       /* IRQ stack 4 KiB */
+#define CONFIG_STACKSIZE_FIQ   (4 << 10)       /* FIQ stack 4 KiB */
 #endif
 
 /*-----------------------------------------------------------------------
  */
 #define CONFIG_NR_DRAM_BANKS   2       /* CS1 may or may not be populated */
 #define PHYS_SDRAM_1           OMAP34XX_SDRC_CS0
-#define PHYS_SDRAM_1_SIZE      SZ_32M  /* at least 32 meg */
+#define PHYS_SDRAM_1_SIZE      (32 << 20)      /* at least 32 MiB */
 #define PHYS_SDRAM_2           OMAP34XX_SDRC_CS1
 
 /* SDRAM Bank Allocation method */
 #define CONFIG_SYS_MAX_FLASH_SECT      520     /* max number of sectors on */
                                                /* one chip */
 #define CONFIG_SYS_MAX_FLASH_BANKS     2       /* max number of flash banks */
-#define CONFIG_SYS_MONITOR_LEN         SZ_256K /* Reserve 2 sectors */
+#define CONFIG_SYS_MONITOR_LEN         (256 << 10)     /* Reserve 2 sectors */
 
 #define CONFIG_SYS_FLASH_BASE          boot_flash_base
 
index 75ab98098cb515f0d0915b32762cf22e5ac5631c..32cd6fdb141210dd0c8651430a43d947590b736d 100644 (file)
@@ -29,7 +29,6 @@
 
 #ifndef __CONFIG_H
 #define __CONFIG_H
-#include <asm/sizes.h>
 
 /*
  * High Level Configuration Options
@@ -64,9 +63,9 @@
 /*
  * Size of malloc() pool
  */
-#define CONFIG_ENV_SIZE                        SZ_128K /* Total Size Environment */
+#define CONFIG_ENV_SIZE                        (128 << 10)     /* 128 KiB */
                                                /* Sector */
-#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + SZ_128K)
+#define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + (128 << 10))
 #define CONFIG_SYS_GBL_DATA_SIZE       128     /* bytes reserved for */
                                                /* initial data */
 /*
  *
  * The stack sizes are set up in start.S using these settings
  */
-#define CONFIG_STACKSIZE       SZ_128K
+#define CONFIG_STACKSIZE       (128 << 10)     /* regular stack 128 KiB */
 #ifdef CONFIG_USE_IRQ
-#define CONFIG_STACKSIZE_IRQ   SZ_4K
-#define CONFIG_STACKSIZE_FIQ   SZ_4K
+#define CONFIG_STACKSIZE_IRQ   (4 << 10)       /* IRQ stack 4 KiB */
+#define CONFIG_STACKSIZE_FIQ   (4 << 10)       /* FIQ stack 4 KiB */
 #endif
 
 /*-----------------------------------------------------------------------
  */
 #define CONFIG_NR_DRAM_BANKS   2       /* CS1 may or may not be populated */
 #define PHYS_SDRAM_1           OMAP34XX_SDRC_CS0
-#define PHYS_SDRAM_1_SIZE      SZ_32M  /* at least 32 meg */
+#define PHYS_SDRAM_1_SIZE      (32 << 20)      /* at least 32 MiB */
 #define PHYS_SDRAM_2           OMAP34XX_SDRC_CS1
 
 /* SDRAM Bank Allocation method */
 #define CONFIG_SYS_MAX_FLASH_SECT      520     /* max number of sectors on */
                                                /* one chip */
 #define CONFIG_SYS_MAX_FLASH_BANKS     2       /* max number of flash banks */
-#define CONFIG_SYS_MONITOR_LEN         SZ_256K /* Reserve 2 sectors */
+#define CONFIG_SYS_MONITOR_LEN         (256 << 10)     /* Reserve 2 sectors */
 
 #define CONFIG_SYS_FLASH_BASE          boot_flash_base