aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-at91
diff options
context:
space:
mode:
authorAndrew Victor <linux@maxim.org.za>2008-09-21 16:30:02 -0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2008-09-21 17:58:36 -0400
commite505240b6a6fd47b84cfeb1272ffeacd3e0874b3 (patch)
tree4a1b9b3715bcf2f52c4ba86e1212c9edd09badfe /arch/arm/mach-at91
parenta745a622434d9c3ff6505125b37fd6828ecadb87 (diff)
[ARM] 5257/2: [AT91] Use SZ_ definitions and MTDPART_OFS_NXTBLK instead of hex-values
In the various AT91 board files, replace hard-coded size values (eg, 0x800000) with the SZ_ size definitions (eg, SZ_8M) from sizes.h Also replace MTD partition offsets with MTDPART_OFS_NXTBLK. Signed-off-by: Andrew Victor <linux@maxim.org.za> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-at91')
-rw-r--r--arch/arm/mach-at91/board-cap9adk.c2
-rw-r--r--arch/arm/mach-at91/board-csb337.c4
-rw-r--r--arch/arm/mach-at91/board-csb637.c4
-rw-r--r--arch/arm/mach-at91/board-dk.c4
-rw-r--r--arch/arm/mach-at91/board-ecbat91.c2
-rw-r--r--arch/arm/mach-at91/board-ek.c4
-rw-r--r--arch/arm/mach-at91/board-picotux200.c2
-rw-r--r--arch/arm/mach-at91/board-qil-a9260.c14
-rw-r--r--arch/arm/mach-at91/board-sam9-l9260.c4
-rw-r--r--arch/arm/mach-at91/board-sam9260ek.c6
-rw-r--r--arch/arm/mach-at91/board-sam9261ek.c6
-rw-r--r--arch/arm/mach-at91/board-sam9263ek.c12
-rw-r--r--arch/arm/mach-at91/board-sam9g20ek.c8
-rw-r--r--arch/arm/mach-at91/board-sam9rlek.c6
-rw-r--r--arch/arm/mach-at91/board-usb-a9260.c14
-rw-r--r--arch/arm/mach-at91/board-usb-a9263.c14
-rw-r--r--arch/arm/mach-at91/board-yl-9200.c50
17 files changed, 78 insertions, 78 deletions
diff --git a/arch/arm/mach-at91/board-cap9adk.c b/arch/arm/mach-at91/board-cap9adk.c
index 196199552eb6..201b89392dcc 100644
--- a/arch/arm/mach-at91/board-cap9adk.c
+++ b/arch/arm/mach-at91/board-cap9adk.c
@@ -214,7 +214,7 @@ static struct physmap_flash_data cap9adk_nor_data = {
214}; 214};
215 215
216#define NOR_BASE AT91_CHIPSELECT_0 216#define NOR_BASE AT91_CHIPSELECT_0
217#define NOR_SIZE 0x800000 217#define NOR_SIZE SZ_8M
218 218
219static struct resource nor_flash_resources[] = { 219static struct resource nor_flash_resources[] = {
220 { 220 {
diff --git a/arch/arm/mach-at91/board-csb337.c b/arch/arm/mach-at91/board-csb337.c
index cb7c9a8fa487..4bdf69d552eb 100644
--- a/arch/arm/mach-at91/board-csb337.c
+++ b/arch/arm/mach-at91/board-csb337.c
@@ -28,7 +28,6 @@
28#include <linux/input.h> 28#include <linux/input.h>
29#include <linux/gpio_keys.h> 29#include <linux/gpio_keys.h>
30 30
31#include <mach/hardware.h>
32#include <asm/setup.h> 31#include <asm/setup.h>
33#include <asm/mach-types.h> 32#include <asm/mach-types.h>
34#include <asm/irq.h> 33#include <asm/irq.h>
@@ -37,6 +36,7 @@
37#include <asm/mach/map.h> 36#include <asm/mach/map.h>
38#include <asm/mach/irq.h> 37#include <asm/mach/irq.h>
39 38
39#include <mach/hardware.h>
40#include <mach/board.h> 40#include <mach/board.h>
41#include <mach/gpio.h> 41#include <mach/gpio.h>
42 42
@@ -114,7 +114,7 @@ static struct spi_board_info csb337_spi_devices[] = {
114}; 114};
115 115
116#define CSB_FLASH_BASE AT91_CHIPSELECT_0 116#define CSB_FLASH_BASE AT91_CHIPSELECT_0
117#define CSB_FLASH_SIZE 0x800000 117#define CSB_FLASH_SIZE SZ_8M
118 118
119static struct mtd_partition csb_flash_partitions[] = { 119static struct mtd_partition csb_flash_partitions[] = {
120 { 120 {
diff --git a/arch/arm/mach-at91/board-csb637.c b/arch/arm/mach-at91/board-csb637.c
index 8db8bd8babd9..cfa3f04b2205 100644
--- a/arch/arm/mach-at91/board-csb637.c
+++ b/arch/arm/mach-at91/board-csb637.c
@@ -25,7 +25,6 @@
25#include <linux/platform_device.h> 25#include <linux/platform_device.h>
26#include <linux/mtd/physmap.h> 26#include <linux/mtd/physmap.h>
27 27
28#include <mach/hardware.h>
29#include <asm/setup.h> 28#include <asm/setup.h>
30#include <asm/mach-types.h> 29#include <asm/mach-types.h>
31#include <asm/irq.h> 30#include <asm/irq.h>
@@ -34,6 +33,7 @@
34#include <asm/mach/map.h> 33#include <asm/mach/map.h>
35#include <asm/mach/irq.h> 34#include <asm/mach/irq.h>
36 35
36#include <mach/hardware.h>
37#include <mach/board.h> 37#include <mach/board.h>
38#include <mach/gpio.h> 38#include <mach/gpio.h>
39 39
@@ -72,7 +72,7 @@ static struct at91_udc_data __initdata csb637_udc_data = {
72}; 72};
73 73
74#define CSB_FLASH_BASE AT91_CHIPSELECT_0 74#define CSB_FLASH_BASE AT91_CHIPSELECT_0
75#define CSB_FLASH_SIZE 0x1000000 75#define CSB_FLASH_SIZE SZ_16M
76 76
77static struct mtd_partition csb_flash_partitions[] = { 77static struct mtd_partition csb_flash_partitions[] = {
78 { 78 {
diff --git a/arch/arm/mach-at91/board-dk.c b/arch/arm/mach-at91/board-dk.c
index 43e1aa7ecef7..0fd0f5bc77ea 100644
--- a/arch/arm/mach-at91/board-dk.c
+++ b/arch/arm/mach-at91/board-dk.c
@@ -29,7 +29,6 @@
29#include <linux/spi/spi.h> 29#include <linux/spi/spi.h>
30#include <linux/mtd/physmap.h> 30#include <linux/mtd/physmap.h>
31 31
32#include <mach/hardware.h>
33#include <asm/setup.h> 32#include <asm/setup.h>
34#include <asm/mach-types.h> 33#include <asm/mach-types.h>
35#include <asm/irq.h> 34#include <asm/irq.h>
@@ -38,6 +37,7 @@
38#include <asm/mach/map.h> 37#include <asm/mach/map.h>
39#include <asm/mach/irq.h> 38#include <asm/mach/irq.h>
40 39
40#include <mach/hardware.h>
41#include <mach/board.h> 41#include <mach/board.h>
42#include <mach/gpio.h> 42#include <mach/gpio.h>
43#include <mach/at91rm9200_mc.h> 43#include <mach/at91rm9200_mc.h>
@@ -157,7 +157,7 @@ static struct atmel_nand_data __initdata dk_nand_data = {
157}; 157};
158 158
159#define DK_FLASH_BASE AT91_CHIPSELECT_0 159#define DK_FLASH_BASE AT91_CHIPSELECT_0
160#define DK_FLASH_SIZE 0x200000 160#define DK_FLASH_SIZE SZ_2M
161 161
162static struct physmap_flash_data dk_flash_data = { 162static struct physmap_flash_data dk_flash_data = {
163 .width = 2, 163 .width = 2,
diff --git a/arch/arm/mach-at91/board-ecbat91.c b/arch/arm/mach-at91/board-ecbat91.c
index bfeee8a2af28..1d69908617f0 100644
--- a/arch/arm/mach-at91/board-ecbat91.c
+++ b/arch/arm/mach-at91/board-ecbat91.c
@@ -86,7 +86,7 @@ static struct mtd_partition __initdata my_flash0_partitions[] =
86 { /* 0x8400 */ 86 { /* 0x8400 */
87 .name = "Darrell-loader", 87 .name = "Darrell-loader",
88 .offset = 0, 88 .offset = 0,
89 .size = 12* 1056, 89 .size = 12 * 1056,
90 }, 90 },
91 { 91 {
92 .name = "U-boot", 92 .name = "U-boot",
diff --git a/arch/arm/mach-at91/board-ek.c b/arch/arm/mach-at91/board-ek.c
index 60626e7a3490..4cdfaac8e590 100644
--- a/arch/arm/mach-at91/board-ek.c
+++ b/arch/arm/mach-at91/board-ek.c
@@ -29,7 +29,6 @@
29#include <linux/spi/spi.h> 29#include <linux/spi/spi.h>
30#include <linux/mtd/physmap.h> 30#include <linux/mtd/physmap.h>
31 31
32#include <mach/hardware.h>
33#include <asm/setup.h> 32#include <asm/setup.h>
34#include <asm/mach-types.h> 33#include <asm/mach-types.h>
35#include <asm/irq.h> 34#include <asm/irq.h>
@@ -38,6 +37,7 @@
38#include <asm/mach/map.h> 37#include <asm/mach/map.h>
39#include <asm/mach/irq.h> 38#include <asm/mach/irq.h>
40 39
40#include <mach/hardware.h>
41#include <mach/board.h> 41#include <mach/board.h>
42#include <mach/gpio.h> 42#include <mach/gpio.h>
43#include <mach/at91rm9200_mc.h> 43#include <mach/at91rm9200_mc.h>
@@ -116,7 +116,7 @@ static struct i2c_board_info __initdata ek_i2c_devices[] = {
116}; 116};
117 117
118#define EK_FLASH_BASE AT91_CHIPSELECT_0 118#define EK_FLASH_BASE AT91_CHIPSELECT_0
119#define EK_FLASH_SIZE 0x200000 119#define EK_FLASH_SIZE SZ_2M
120 120
121static struct physmap_flash_data ek_flash_data = { 121static struct physmap_flash_data ek_flash_data = {
122 .width = 2, 122 .width = 2,
diff --git a/arch/arm/mach-at91/board-picotux200.c b/arch/arm/mach-at91/board-picotux200.c
index dbc912d633c7..859727e7ea30 100644
--- a/arch/arm/mach-at91/board-picotux200.c
+++ b/arch/arm/mach-at91/board-picotux200.c
@@ -105,7 +105,7 @@ static struct at91_mmc_data __initdata picotux200_mmc_data = {
105// }; 105// };
106 106
107#define PICOTUX200_FLASH_BASE AT91_CHIPSELECT_0 107#define PICOTUX200_FLASH_BASE AT91_CHIPSELECT_0
108#define PICOTUX200_FLASH_SIZE 0x400000 108#define PICOTUX200_FLASH_SIZE SZ_4M
109 109
110static struct physmap_flash_data picotux200_flash_data = { 110static struct physmap_flash_data picotux200_flash_data = {
111 .width = 2, 111 .width = 2,
diff --git a/arch/arm/mach-at91/board-qil-a9260.c b/arch/arm/mach-at91/board-qil-a9260.c
index 4c28413426c2..cfb4571a2e27 100644
--- a/arch/arm/mach-at91/board-qil-a9260.c
+++ b/arch/arm/mach-at91/board-qil-a9260.c
@@ -30,7 +30,6 @@
30#include <linux/input.h> 30#include <linux/input.h>
31#include <linux/clk.h> 31#include <linux/clk.h>
32 32
33#include <mach/hardware.h>
34#include <asm/setup.h> 33#include <asm/setup.h>
35#include <asm/mach-types.h> 34#include <asm/mach-types.h>
36#include <asm/irq.h> 35#include <asm/irq.h>
@@ -39,6 +38,7 @@
39#include <asm/mach/map.h> 38#include <asm/mach/map.h>
40#include <asm/mach/irq.h> 39#include <asm/mach/irq.h>
41 40
41#include <mach/hardware.h>
42#include <mach/board.h> 42#include <mach/board.h>
43#include <mach/gpio.h> 43#include <mach/gpio.h>
44#include <mach/at91_shdwc.h> 44#include <mach/at91_shdwc.h>
@@ -119,18 +119,18 @@ static struct at91_eth_data __initdata ek_macb_data = {
119static struct mtd_partition __initdata ek_nand_partition[] = { 119static struct mtd_partition __initdata ek_nand_partition[] = {
120 { 120 {
121 .name = "Uboot & Kernel", 121 .name = "Uboot & Kernel",
122 .offset = 0x00000000, 122 .offset = 0,
123 .size = 16 * 1024 * 1024, 123 .size = SZ_16M,
124 }, 124 },
125 { 125 {
126 .name = "Root FS", 126 .name = "Root FS",
127 .offset = 0x01000000, 127 .offset = MTDPART_OFS_NXTBLK,
128 .size = 120 * 1024 * 1024, 128 .size = 120 * SZ_1M,
129 }, 129 },
130 { 130 {
131 .name = "FS", 131 .name = "FS",
132 .offset = 0x08800000, 132 .offset = MTDPART_OFS_NXTBLK,
133 .size = 120 * 1024 * 1024, 133 .size = 120 * SZ_1M,
134 }, 134 },
135}; 135};
136 136
diff --git a/arch/arm/mach-at91/board-sam9-l9260.c b/arch/arm/mach-at91/board-sam9-l9260.c
index e4910cb26c16..99bb4cc23a09 100644
--- a/arch/arm/mach-at91/board-sam9-l9260.c
+++ b/arch/arm/mach-at91/board-sam9-l9260.c
@@ -126,11 +126,11 @@ static struct mtd_partition __initdata ek_nand_partition[] = {
126 { 126 {
127 .name = "Bootloader Area", 127 .name = "Bootloader Area",
128 .offset = 0, 128 .offset = 0,
129 .size = 10 * 1024 * 1024, 129 .size = 10 * SZ_1M,
130 }, 130 },
131 { 131 {
132 .name = "User Area", 132 .name = "User Area",
133 .offset = 10 * 1024 * 1024, 133 .offset = MTDPART_OFS_NXTBLK,
134 .size = MTDPART_SIZ_FULL, 134 .size = MTDPART_SIZ_FULL,
135 }, 135 },
136}; 136};
diff --git a/arch/arm/mach-at91/board-sam9260ek.c b/arch/arm/mach-at91/board-sam9260ek.c
index 0a53c038b518..e22433d5dfb6 100644
--- a/arch/arm/mach-at91/board-sam9260ek.c
+++ b/arch/arm/mach-at91/board-sam9260ek.c
@@ -29,7 +29,6 @@
29#include <linux/clk.h> 29#include <linux/clk.h>
30#include <linux/i2c/at24.h> 30#include <linux/i2c/at24.h>
31 31
32#include <mach/hardware.h>
33#include <asm/setup.h> 32#include <asm/setup.h>
34#include <asm/mach-types.h> 33#include <asm/mach-types.h>
35#include <asm/irq.h> 34#include <asm/irq.h>
@@ -38,6 +37,7 @@
38#include <asm/mach/map.h> 37#include <asm/mach/map.h>
39#include <asm/mach/irq.h> 38#include <asm/mach/irq.h>
40 39
40#include <mach/hardware.h>
41#include <mach/board.h> 41#include <mach/board.h>
42#include <mach/gpio.h> 42#include <mach/gpio.h>
43 43
@@ -164,11 +164,11 @@ static struct mtd_partition __initdata ek_nand_partition[] = {
164 { 164 {
165 .name = "Partition 1", 165 .name = "Partition 1",
166 .offset = 0, 166 .offset = 0,
167 .size = 256 * 1024, 167 .size = SZ_256K,
168 }, 168 },
169 { 169 {
170 .name = "Partition 2", 170 .name = "Partition 2",
171 .offset = 256 * 1024, 171 .offset = MTDPART_OFS_NXTBLK,
172 .size = MTDPART_SIZ_FULL, 172 .size = MTDPART_SIZ_FULL,
173 }, 173 },
174}; 174};
diff --git a/arch/arm/mach-at91/board-sam9261ek.c b/arch/arm/mach-at91/board-sam9261ek.c
index 1a9963b811c7..03d3382cfef6 100644
--- a/arch/arm/mach-at91/board-sam9261ek.c
+++ b/arch/arm/mach-at91/board-sam9261ek.c
@@ -35,7 +35,6 @@
35 35
36#include <video/atmel_lcdc.h> 36#include <video/atmel_lcdc.h>
37 37
38#include <mach/hardware.h>
39#include <asm/setup.h> 38#include <asm/setup.h>
40#include <asm/mach-types.h> 39#include <asm/mach-types.h>
41#include <asm/irq.h> 40#include <asm/irq.h>
@@ -44,6 +43,7 @@
44#include <asm/mach/map.h> 43#include <asm/mach/map.h>
45#include <asm/mach/irq.h> 44#include <asm/mach/irq.h>
46 45
46#include <mach/hardware.h>
47#include <mach/board.h> 47#include <mach/board.h>
48#include <mach/gpio.h> 48#include <mach/gpio.h>
49#include <mach/at91sam9_smc.h> 49#include <mach/at91sam9_smc.h>
@@ -168,11 +168,11 @@ static struct mtd_partition __initdata ek_nand_partition[] = {
168 { 168 {
169 .name = "Partition 1", 169 .name = "Partition 1",
170 .offset = 0, 170 .offset = 0,
171 .size = 256 * 1024, 171 .size = SZ_256K,
172 }, 172 },
173 { 173 {
174 .name = "Partition 2", 174 .name = "Partition 2",
175 .offset = 256 * 1024 , 175 .offset = MTDPART_OFS_NXTBLK,
176 .size = MTDPART_SIZ_FULL, 176 .size = MTDPART_SIZ_FULL,
177 }, 177 },
178}; 178};
diff --git a/arch/arm/mach-at91/board-sam9263ek.c b/arch/arm/mach-at91/board-sam9263ek.c
index c51f2eb3874b..ad71f4a71451 100644
--- a/arch/arm/mach-at91/board-sam9263ek.c
+++ b/arch/arm/mach-at91/board-sam9263ek.c
@@ -33,7 +33,6 @@
33 33
34#include <video/atmel_lcdc.h> 34#include <video/atmel_lcdc.h>
35 35
36#include <mach/hardware.h>
37#include <asm/setup.h> 36#include <asm/setup.h>
38#include <asm/mach-types.h> 37#include <asm/mach-types.h>
39#include <asm/irq.h> 38#include <asm/irq.h>
@@ -42,6 +41,7 @@
42#include <asm/mach/map.h> 41#include <asm/mach/map.h>
43#include <asm/mach/irq.h> 42#include <asm/mach/irq.h>
44 43
44#include <mach/hardware.h>
45#include <mach/board.h> 45#include <mach/board.h>
46#include <mach/gpio.h> 46#include <mach/gpio.h>
47#include <mach/at91sam9_smc.h> 47#include <mach/at91sam9_smc.h>
@@ -173,11 +173,11 @@ static struct mtd_partition __initdata ek_nand_partition[] = {
173 { 173 {
174 .name = "Partition 1", 174 .name = "Partition 1",
175 .offset = 0, 175 .offset = 0,
176 .size = 64 * 1024 * 1024, 176 .size = SZ_64M,
177 }, 177 },
178 { 178 {
179 .name = "Partition 2", 179 .name = "Partition 2",
180 .offset = 64 * 1024 * 1024, 180 .offset = MTDPART_OFS_NXTBLK,
181 .size = MTDPART_SIZ_FULL, 181 .size = MTDPART_SIZ_FULL,
182 }, 182 },
183}; 183};
@@ -227,7 +227,7 @@ static struct i2c_board_info __initdata ek_i2c_devices[] = {
227#if defined(CONFIG_FB_ATMEL) || defined(CONFIG_FB_ATMEL_MODULE) 227#if defined(CONFIG_FB_ATMEL) || defined(CONFIG_FB_ATMEL_MODULE)
228static struct fb_videomode at91_tft_vga_modes[] = { 228static struct fb_videomode at91_tft_vga_modes[] = {
229 { 229 {
230 .name = "TX09D50VM1CCA @ 60", 230 .name = "TX09D50VM1CCA @ 60",
231 .refresh = 60, 231 .refresh = 60,
232 .xres = 240, .yres = 320, 232 .xres = 240, .yres = 320,
233 .pixclock = KHZ2PICOS(4965), 233 .pixclock = KHZ2PICOS(4965),
@@ -243,7 +243,7 @@ static struct fb_videomode at91_tft_vga_modes[] = {
243 243
244static struct fb_monspecs at91fb_default_monspecs = { 244static struct fb_monspecs at91fb_default_monspecs = {
245 .manufacturer = "HIT", 245 .manufacturer = "HIT",
246 .monitor = "TX09D70VM1CCA", 246 .monitor = "TX09D70VM1CCA",
247 247
248 .modedb = at91_tft_vga_modes, 248 .modedb = at91_tft_vga_modes,
249 .modedb_len = ARRAY_SIZE(at91_tft_vga_modes), 249 .modedb_len = ARRAY_SIZE(at91_tft_vga_modes),
@@ -254,7 +254,7 @@ static struct fb_monspecs at91fb_default_monspecs = {
254}; 254};
255 255
256#define AT91SAM9263_DEFAULT_LCDCON2 (ATMEL_LCDC_MEMOR_LITTLE \ 256#define AT91SAM9263_DEFAULT_LCDCON2 (ATMEL_LCDC_MEMOR_LITTLE \
257 | ATMEL_LCDC_DISTYPE_TFT \ 257 | ATMEL_LCDC_DISTYPE_TFT \
258 | ATMEL_LCDC_CLKMOD_ALWAYSACTIVE) 258 | ATMEL_LCDC_CLKMOD_ALWAYSACTIVE)
259 259
260static void at91_lcdc_power_control(int on) 260static void at91_lcdc_power_control(int on)
diff --git a/arch/arm/mach-at91/board-sam9g20ek.c b/arch/arm/mach-at91/board-sam9g20ek.c
index d4eba5c0ce02..b588ead14d68 100644
--- a/arch/arm/mach-at91/board-sam9g20ek.c
+++ b/arch/arm/mach-at91/board-sam9g20ek.c
@@ -122,16 +122,16 @@ static struct mtd_partition __initdata ek_nand_partition[] = {
122 { 122 {
123 .name = "Bootstrap", 123 .name = "Bootstrap",
124 .offset = 0, 124 .offset = 0,
125 .size = 4 * 1024 * 1024, 125 .size = 4 * SZ_1M,
126 }, 126 },
127 { 127 {
128 .name = "Partition 1", 128 .name = "Partition 1",
129 .offset = 4 * 1024 * 1024, 129 .offset = MTDPART_OFS_NXTBLK,
130 .size = 60 * 1024 * 1024, 130 .size = 60 * SZ_1M,
131 }, 131 },
132 { 132 {
133 .name = "Partition 2", 133 .name = "Partition 2",
134 .offset = 64 * 1024 * 1024, 134 .offset = MTDPART_OFS_NXTBLK,
135 .size = MTDPART_SIZ_FULL, 135 .size = MTDPART_SIZ_FULL,
136 }, 136 },
137}; 137};
diff --git a/arch/arm/mach-at91/board-sam9rlek.c b/arch/arm/mach-at91/board-sam9rlek.c
index c6dce49c388c..3d3f61572cff 100644
--- a/arch/arm/mach-at91/board-sam9rlek.c
+++ b/arch/arm/mach-at91/board-sam9rlek.c
@@ -18,7 +18,6 @@
18 18
19#include <video/atmel_lcdc.h> 19#include <video/atmel_lcdc.h>
20 20
21#include <mach/hardware.h>
22#include <asm/setup.h> 21#include <asm/setup.h>
23#include <asm/mach-types.h> 22#include <asm/mach-types.h>
24#include <asm/irq.h> 23#include <asm/irq.h>
@@ -27,6 +26,7 @@
27#include <asm/mach/map.h> 26#include <asm/mach/map.h>
28#include <asm/mach/irq.h> 27#include <asm/mach/irq.h>
29 28
29#include <mach/hardware.h>
30#include <mach/board.h> 30#include <mach/board.h>
31#include <mach/gpio.h> 31#include <mach/gpio.h>
32#include <mach/at91sam9_smc.h> 32#include <mach/at91sam9_smc.h>
@@ -81,11 +81,11 @@ static struct mtd_partition __initdata ek_nand_partition[] = {
81 { 81 {
82 .name = "Partition 1", 82 .name = "Partition 1",
83 .offset = 0, 83 .offset = 0,
84 .size = 256 * 1024, 84 .size = SZ_256K,
85 }, 85 },
86 { 86 {
87 .name = "Partition 2", 87 .name = "Partition 2",
88 .offset = 256 * 1024 , 88 .offset = MTDPART_OFS_NXTBLK,
89 .size = MTDPART_SIZ_FULL, 89 .size = MTDPART_SIZ_FULL,
90 }, 90 },
91}; 91};
diff --git a/arch/arm/mach-at91/board-usb-a9260.c b/arch/arm/mach-at91/board-usb-a9260.c
index f9d0b65da40b..7c350357333a 100644
--- a/arch/arm/mach-at91/board-usb-a9260.c
+++ b/arch/arm/mach-at91/board-usb-a9260.c
@@ -30,7 +30,6 @@
30#include <linux/input.h> 30#include <linux/input.h>
31#include <linux/clk.h> 31#include <linux/clk.h>
32 32
33#include <mach/hardware.h>
34#include <asm/setup.h> 33#include <asm/setup.h>
35#include <asm/mach-types.h> 34#include <asm/mach-types.h>
36#include <asm/irq.h> 35#include <asm/irq.h>
@@ -39,6 +38,7 @@
39#include <asm/mach/map.h> 38#include <asm/mach/map.h>
40#include <asm/mach/irq.h> 39#include <asm/mach/irq.h>
41 40
41#include <mach/hardware.h>
42#include <mach/board.h> 42#include <mach/board.h>
43#include <mach/gpio.h> 43#include <mach/gpio.h>
44#include <mach/at91_shdwc.h> 44#include <mach/at91_shdwc.h>
@@ -93,18 +93,18 @@ static struct at91_eth_data __initdata ek_macb_data = {
93static struct mtd_partition __initdata ek_nand_partition[] = { 93static struct mtd_partition __initdata ek_nand_partition[] = {
94 { 94 {
95 .name = "Uboot & Kernel", 95 .name = "Uboot & Kernel",
96 .offset = 0x00000000, 96 .offset = 0,
97 .size = 16 * 1024 * 1024, 97 .size = SZ_16M,
98 }, 98 },
99 { 99 {
100 .name = "Root FS", 100 .name = "Root FS",
101 .offset = 0x01000000, 101 .offset = MTDPART_OFS_NXTBLK,
102 .size = 120 * 1024 * 1024, 102 .size = 120 * SZ_1M,
103 }, 103 },
104 { 104 {
105 .name = "FS", 105 .name = "FS",
106 .offset = 0x08800000, 106 .offset = MTDPART_OFS_NXTBLK,
107 .size = 120 * 1024 * 1024, 107 .size = 120 * SZ_1M,
108 } 108 }
109}; 109};
110 110
diff --git a/arch/arm/mach-at91/board-usb-a9263.c b/arch/arm/mach-at91/board-usb-a9263.c
index 673e5c27214d..391b566c4571 100644
--- a/arch/arm/mach-at91/board-usb-a9263.c
+++ b/arch/arm/mach-at91/board-usb-a9263.c
@@ -29,7 +29,6 @@
29#include <linux/gpio_keys.h> 29#include <linux/gpio_keys.h>
30#include <linux/input.h> 30#include <linux/input.h>
31 31
32#include <mach/hardware.h>
33#include <asm/setup.h> 32#include <asm/setup.h>
34#include <asm/mach-types.h> 33#include <asm/mach-types.h>
35#include <asm/irq.h> 34#include <asm/irq.h>
@@ -38,6 +37,7 @@
38#include <asm/mach/map.h> 37#include <asm/mach/map.h>
39#include <asm/mach/irq.h> 38#include <asm/mach/irq.h>
40 39
40#include <mach/hardware.h>
41#include <mach/board.h> 41#include <mach/board.h>
42#include <mach/gpio.h> 42#include <mach/gpio.h>
43#include <mach/at91_shdwc.h> 43#include <mach/at91_shdwc.h>
@@ -106,18 +106,18 @@ static struct at91_eth_data __initdata ek_macb_data = {
106static struct mtd_partition __initdata ek_nand_partition[] = { 106static struct mtd_partition __initdata ek_nand_partition[] = {
107 { 107 {
108 .name = "Linux Kernel", 108 .name = "Linux Kernel",
109 .offset = 0x00000000, 109 .offset = 0,
110 .size = 16 * 1024 * 1024, 110 .size = SZ_16M,
111 }, 111 },
112 { 112 {
113 .name = "Root FS", 113 .name = "Root FS",
114 .offset = 0x01000000, 114 .offset = MTDPART_OFS_NXTBLK,
115 .size = 120 * 1024 * 1024, 115 .size = 120 * SZ_1M,
116 }, 116 },
117 { 117 {
118 .name = "FS", 118 .name = "FS",
119 .offset = 0x08800000, 119 .offset = MTDPART_OFS_NXTBLK,
120 .size = 120 * 1024 * 1024, 120 .size = 120 * SZ_1M,
121 } 121 }
122}; 122};
123 123
diff --git a/arch/arm/mach-at91/board-yl-9200.c b/arch/arm/mach-at91/board-yl-9200.c
index 36b380aad006..e22bf051f835 100644
--- a/arch/arm/mach-at91/board-yl-9200.c
+++ b/arch/arm/mach-at91/board-yl-9200.c
@@ -33,7 +33,6 @@
33#include <linux/gpio_keys.h> 33#include <linux/gpio_keys.h>
34#include <linux/input.h> 34#include <linux/input.h>
35 35
36#include <mach/hardware.h>
37#include <asm/setup.h> 36#include <asm/setup.h>
38#include <asm/mach-types.h> 37#include <asm/mach-types.h>
39#include <asm/irq.h> 38#include <asm/irq.h>
@@ -42,6 +41,7 @@
42#include <asm/mach/map.h> 41#include <asm/mach/map.h>
43#include <asm/mach/irq.h> 42#include <asm/mach/irq.h>
44 43
44#include <mach/hardware.h>
45#include <mach/board.h> 45#include <mach/board.h>
46#include <mach/gpio.h> 46#include <mach/gpio.h>
47#include <mach/at91rm9200_mc.h> 47#include <mach/at91rm9200_mc.h>
@@ -150,27 +150,27 @@ static struct mtd_partition __initdata yl9200_nand_partition[] = {
150 { 150 {
151 .name = "AT91 NAND partition 1, boot", 151 .name = "AT91 NAND partition 1, boot",
152 .offset = 0, 152 .offset = 0,
153 .size = 1 * SZ_256K 153 .size = SZ_256K
154 }, 154 },
155 { 155 {
156 .name = "AT91 NAND partition 2, kernel", 156 .name = "AT91 NAND partition 2, kernel",
157 .offset = 1 * SZ_256K, 157 .offset = MTDPART_OFS_NXTBLK,
158 .size = 2 * SZ_1M - 1 * SZ_256K 158 .size = (2 * SZ_1M) - SZ_256K
159 }, 159 },
160 { 160 {
161 .name = "AT91 NAND partition 3, filesystem", 161 .name = "AT91 NAND partition 3, filesystem",
162 .offset = 2 * SZ_1M, 162 .offset = MTDPART_OFS_NXTBLK,
163 .size = 14 * SZ_1M 163 .size = 14 * SZ_1M
164 }, 164 },
165 { 165 {
166 .name = "AT91 NAND partition 4, storage", 166 .name = "AT91 NAND partition 4, storage",
167 .offset = 16 * SZ_1M, 167 .offset = MTDPART_OFS_NXTBLK,
168 .size = 16 * SZ_1M 168 .size = SZ_16M
169 }, 169 },
170 { 170 {
171 .name = "AT91 NAND partition 5, ext-fs", 171 .name = "AT91 NAND partition 5, ext-fs",
172 .offset = 32 * SZ_1M, 172 .offset = MTDPART_OFS_NXTBLK,
173 .size = 32 * SZ_1M 173 .size = SZ_32M
174 } 174 }
175}; 175};
176 176
@@ -193,24 +193,24 @@ static struct atmel_nand_data __initdata yl9200_nand_data = {
193 * NOR Flash 193 * NOR Flash
194 */ 194 */
195#define YL9200_FLASH_BASE AT91_CHIPSELECT_0 195#define YL9200_FLASH_BASE AT91_CHIPSELECT_0
196#define YL9200_FLASH_SIZE 0x1000000 196#define YL9200_FLASH_SIZE SZ_16M
197 197
198static struct mtd_partition yl9200_flash_partitions[] = { 198static struct mtd_partition yl9200_flash_partitions[] = {
199 { 199 {
200 .name = "Bootloader", 200 .name = "Bootloader",
201 .size = 0x00040000,
202 .offset = 0, 201 .offset = 0,
202 .size = SZ_256K,
203 .mask_flags = MTD_WRITEABLE, /* force read-only */ 203 .mask_flags = MTD_WRITEABLE, /* force read-only */
204 }, 204 },
205 { 205 {
206 .name = "Kernel", 206 .name = "Kernel",
207 .size = 0x001C0000, 207 .offset = MTDPART_OFS_NXTBLK,
208 .offset = 0x00040000, 208 .size = (2 * SZ_1M) - SZ_256K
209 }, 209 },
210 { 210 {
211 .name = "Filesystem", 211 .name = "Filesystem",
212 .size = MTDPART_SIZ_FULL, 212 .offset = MTDPART_OFS_NXTBLK,
213 .offset = 0x00200000 213 .size = MTDPART_SIZ_FULL
214 } 214 }
215}; 215};
216 216
@@ -390,10 +390,6 @@ static struct spi_board_info yl9200_spi_devices[] = {
390#if defined(CONFIG_FB_S1D135XX) || defined(CONFIG_FB_S1D13XXX_MODULE) 390#if defined(CONFIG_FB_S1D135XX) || defined(CONFIG_FB_S1D13XXX_MODULE)
391#include <video/s1d13xxxfb.h> 391#include <video/s1d13xxxfb.h>
392 392
393#define AT91_FB_REG_BASE 0x80000000L
394#define AT91_FB_REG_SIZE 0x200
395#define AT91_FB_VMEM_BASE 0x80200000L
396#define AT91_FB_VMEM_SIZE 0x200000L
397 393
398static void __init yl9200_init_video(void) 394static void __init yl9200_init_video(void)
399{ 395{
@@ -516,29 +512,33 @@ static struct s1d13xxxfb_regval yl9200_s1dfb_initregs[] =
516 {S1DREG_COM_DISP_MODE, 0x01}, /* Display Mode Register, LCD only*/ 512 {S1DREG_COM_DISP_MODE, 0x01}, /* Display Mode Register, LCD only*/
517}; 513};
518 514
519static u64 s1dfb_dmamask = DMA_BIT_MASK(32);
520
521static struct s1d13xxxfb_pdata yl9200_s1dfb_pdata = { 515static struct s1d13xxxfb_pdata yl9200_s1dfb_pdata = {
522 .initregs = yl9200_s1dfb_initregs, 516 .initregs = yl9200_s1dfb_initregs,
523 .initregssize = ARRAY_SIZE(yl9200_s1dfb_initregs), 517 .initregssize = ARRAY_SIZE(yl9200_s1dfb_initregs),
524 .platform_init_video = yl9200_init_video, 518 .platform_init_video = yl9200_init_video,
525}; 519};
526 520
521#define YL9200_FB_REG_BASE AT91_CHIPSELECT_7
522#define YL9200_FB_VMEM_BASE YL9200_FB_REG_BASE + SZ_2M
523#define YL9200_FB_VMEM_SIZE SZ_2M
524
527static struct resource yl9200_s1dfb_resource[] = { 525static struct resource yl9200_s1dfb_resource[] = {
528 [0] = { /* video mem */ 526 [0] = { /* video mem */
529 .name = "s1d13xxxfb memory", 527 .name = "s1d13xxxfb memory",
530 .start = AT91_FB_VMEM_BASE, 528 .start = YL9200_FB_VMEM_BASE,
531 .end = AT91_FB_VMEM_BASE + AT91_FB_VMEM_SIZE -1, 529 .end = YL9200_FB_VMEM_BASE + YL9200_FB_VMEM_SIZE -1,
532 .flags = IORESOURCE_MEM, 530 .flags = IORESOURCE_MEM,
533 }, 531 },
534 [1] = { /* video registers */ 532 [1] = { /* video registers */
535 .name = "s1d13xxxfb registers", 533 .name = "s1d13xxxfb registers",
536 .start = AT91_FB_REG_BASE, 534 .start = YL9200_FB_REG_BASE,
537 .end = AT91_FB_REG_BASE + AT91_FB_REG_SIZE -1, 535 .end = YL9200_FB_REG_BASE + SZ_512 -1,
538 .flags = IORESOURCE_MEM, 536 .flags = IORESOURCE_MEM,
539 }, 537 },
540}; 538};
541 539
540static u64 s1dfb_dmamask = DMA_BIT_MASK(32);
541
542static struct platform_device yl9200_s1dfb_device = { 542static struct platform_device yl9200_s1dfb_device = {
543 .name = "s1d13806fb", 543 .name = "s1d13806fb",
544 .id = -1, 544 .id = -1,