aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-at91/at91cap9_devices.c8
-rw-r--r--arch/arm/mach-at91/at91rm9200_devices.c8
-rw-r--r--arch/arm/mach-at91/at91sam9260_devices.c8
-rw-r--r--arch/arm/mach-at91/at91sam9261_devices.c12
-rw-r--r--arch/arm/mach-at91/at91sam9263_devices.c8
-rw-r--r--arch/arm/mach-at91/at91sam9rl_devices.c12
-rw-r--r--arch/arm/mach-at91/board-cam60.c2
-rw-r--r--arch/arm/mach-at91/board-cap9adk.c2
-rw-r--r--arch/arm/mach-at91/board-dk.c2
-rw-r--r--arch/arm/mach-at91/board-kb9202.c2
-rw-r--r--arch/arm/mach-at91/board-sam9-l9260.c2
-rw-r--r--arch/arm/mach-at91/board-sam9260ek.c2
-rw-r--r--arch/arm/mach-at91/board-sam9261ek.c2
-rw-r--r--arch/arm/mach-at91/board-sam9263ek.c2
-rw-r--r--arch/arm/mach-at91/board-sam9rlek.c2
-rwxr-xr-xarch/arm/mach-at91/board-yl-9200.c2
-rw-r--r--arch/avr32/boards/atstk1000/Kconfig4
-rw-r--r--arch/avr32/boards/atstk1000/Makefile1
-rw-r--r--arch/avr32/boards/atstk1000/atstk1002.c78
-rw-r--r--arch/avr32/mach-at32ap/at32ap700x.c52
-rw-r--r--arch/avr32/mach-at32ap/hsmc.c2
21 files changed, 172 insertions, 41 deletions
diff --git a/arch/arm/mach-at91/at91cap9_devices.c b/arch/arm/mach-at91/at91cap9_devices.c
index be526746e01e..fe5148e9f0cc 100644
--- a/arch/arm/mach-at91/at91cap9_devices.c
+++ b/arch/arm/mach-at91/at91cap9_devices.c
@@ -278,7 +278,7 @@ void __init at91_add_device_mmc(short mmc_id, struct at91_mmc_data *data) {}
278 * -------------------------------------------------------------------- */ 278 * -------------------------------------------------------------------- */
279 279
280#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE) 280#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE)
281static struct at91_nand_data nand_data; 281static struct atmel_nand_data nand_data;
282 282
283#define NAND_BASE AT91_CHIPSELECT_3 283#define NAND_BASE AT91_CHIPSELECT_3
284 284
@@ -296,7 +296,7 @@ static struct resource nand_resources[] = {
296}; 296};
297 297
298static struct platform_device at91cap9_nand_device = { 298static struct platform_device at91cap9_nand_device = {
299 .name = "at91_nand", 299 .name = "atmel_nand",
300 .id = -1, 300 .id = -1,
301 .dev = { 301 .dev = {
302 .platform_data = &nand_data, 302 .platform_data = &nand_data,
@@ -305,7 +305,7 @@ static struct platform_device at91cap9_nand_device = {
305 .num_resources = ARRAY_SIZE(nand_resources), 305 .num_resources = ARRAY_SIZE(nand_resources),
306}; 306};
307 307
308void __init at91_add_device_nand(struct at91_nand_data *data) 308void __init at91_add_device_nand(struct atmel_nand_data *data)
309{ 309{
310 unsigned long csa, mode; 310 unsigned long csa, mode;
311 311
@@ -346,7 +346,7 @@ void __init at91_add_device_nand(struct at91_nand_data *data)
346 platform_device_register(&at91cap9_nand_device); 346 platform_device_register(&at91cap9_nand_device);
347} 347}
348#else 348#else
349void __init at91_add_device_nand(struct at91_nand_data *data) {} 349void __init at91_add_device_nand(struct atmel_nand_data *data) {}
350#endif 350#endif
351 351
352 352
diff --git a/arch/arm/mach-at91/at91rm9200_devices.c b/arch/arm/mach-at91/at91rm9200_devices.c
index de19bee83f75..8ced9bc82099 100644
--- a/arch/arm/mach-at91/at91rm9200_devices.c
+++ b/arch/arm/mach-at91/at91rm9200_devices.c
@@ -369,7 +369,7 @@ void __init at91_add_device_mmc(short mmc_id, struct at91_mmc_data *data) {}
369 * -------------------------------------------------------------------- */ 369 * -------------------------------------------------------------------- */
370 370
371#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE) 371#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE)
372static struct at91_nand_data nand_data; 372static struct atmel_nand_data nand_data;
373 373
374#define NAND_BASE AT91_CHIPSELECT_3 374#define NAND_BASE AT91_CHIPSELECT_3
375 375
@@ -382,7 +382,7 @@ static struct resource nand_resources[] = {
382}; 382};
383 383
384static struct platform_device at91rm9200_nand_device = { 384static struct platform_device at91rm9200_nand_device = {
385 .name = "at91_nand", 385 .name = "atmel_nand",
386 .id = -1, 386 .id = -1,
387 .dev = { 387 .dev = {
388 .platform_data = &nand_data, 388 .platform_data = &nand_data,
@@ -391,7 +391,7 @@ static struct platform_device at91rm9200_nand_device = {
391 .num_resources = ARRAY_SIZE(nand_resources), 391 .num_resources = ARRAY_SIZE(nand_resources),
392}; 392};
393 393
394void __init at91_add_device_nand(struct at91_nand_data *data) 394void __init at91_add_device_nand(struct atmel_nand_data *data)
395{ 395{
396 unsigned int csa; 396 unsigned int csa;
397 397
@@ -429,7 +429,7 @@ void __init at91_add_device_nand(struct at91_nand_data *data)
429 platform_device_register(&at91rm9200_nand_device); 429 platform_device_register(&at91rm9200_nand_device);
430} 430}
431#else 431#else
432void __init at91_add_device_nand(struct at91_nand_data *data) {} 432void __init at91_add_device_nand(struct atmel_nand_data *data) {}
433#endif 433#endif
434 434
435 435
diff --git a/arch/arm/mach-at91/at91sam9260_devices.c b/arch/arm/mach-at91/at91sam9260_devices.c
index 393a32aefce5..3aa62b1151b8 100644
--- a/arch/arm/mach-at91/at91sam9260_devices.c
+++ b/arch/arm/mach-at91/at91sam9260_devices.c
@@ -283,7 +283,7 @@ void __init at91_add_device_mmc(short mmc_id, struct at91_mmc_data *data) {}
283 * -------------------------------------------------------------------- */ 283 * -------------------------------------------------------------------- */
284 284
285#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE) 285#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE)
286static struct at91_nand_data nand_data; 286static struct atmel_nand_data nand_data;
287 287
288#define NAND_BASE AT91_CHIPSELECT_3 288#define NAND_BASE AT91_CHIPSELECT_3
289 289
@@ -301,7 +301,7 @@ static struct resource nand_resources[] = {
301}; 301};
302 302
303static struct platform_device at91sam9260_nand_device = { 303static struct platform_device at91sam9260_nand_device = {
304 .name = "at91_nand", 304 .name = "atmel_nand",
305 .id = -1, 305 .id = -1,
306 .dev = { 306 .dev = {
307 .platform_data = &nand_data, 307 .platform_data = &nand_data,
@@ -310,7 +310,7 @@ static struct platform_device at91sam9260_nand_device = {
310 .num_resources = ARRAY_SIZE(nand_resources), 310 .num_resources = ARRAY_SIZE(nand_resources),
311}; 311};
312 312
313void __init at91_add_device_nand(struct at91_nand_data *data) 313void __init at91_add_device_nand(struct atmel_nand_data *data)
314{ 314{
315 unsigned long csa, mode; 315 unsigned long csa, mode;
316 316
@@ -351,7 +351,7 @@ void __init at91_add_device_nand(struct at91_nand_data *data)
351 platform_device_register(&at91sam9260_nand_device); 351 platform_device_register(&at91sam9260_nand_device);
352} 352}
353#else 353#else
354void __init at91_add_device_nand(struct at91_nand_data *data) {} 354void __init at91_add_device_nand(struct atmel_nand_data *data) {}
355#endif 355#endif
356 356
357 357
diff --git a/arch/arm/mach-at91/at91sam9261_devices.c b/arch/arm/mach-at91/at91sam9261_devices.c
index 0babb645b83c..247e8e7cebea 100644
--- a/arch/arm/mach-at91/at91sam9261_devices.c
+++ b/arch/arm/mach-at91/at91sam9261_devices.c
@@ -199,7 +199,7 @@ void __init at91_add_device_mmc(short mmc_id, struct at91_mmc_data *data) {}
199 * -------------------------------------------------------------------- */ 199 * -------------------------------------------------------------------- */
200 200
201#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE) 201#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE)
202static struct at91_nand_data nand_data; 202static struct atmel_nand_data nand_data;
203 203
204#define NAND_BASE AT91_CHIPSELECT_3 204#define NAND_BASE AT91_CHIPSELECT_3
205 205
@@ -211,8 +211,8 @@ static struct resource nand_resources[] = {
211 } 211 }
212}; 212};
213 213
214static struct platform_device at91_nand_device = { 214static struct platform_device atmel_nand_device = {
215 .name = "at91_nand", 215 .name = "atmel_nand",
216 .id = -1, 216 .id = -1,
217 .dev = { 217 .dev = {
218 .platform_data = &nand_data, 218 .platform_data = &nand_data,
@@ -221,7 +221,7 @@ static struct platform_device at91_nand_device = {
221 .num_resources = ARRAY_SIZE(nand_resources), 221 .num_resources = ARRAY_SIZE(nand_resources),
222}; 222};
223 223
224void __init at91_add_device_nand(struct at91_nand_data *data) 224void __init at91_add_device_nand(struct atmel_nand_data *data)
225{ 225{
226 unsigned long csa, mode; 226 unsigned long csa, mode;
227 227
@@ -262,11 +262,11 @@ void __init at91_add_device_nand(struct at91_nand_data *data)
262 at91_set_A_periph(AT91_PIN_PC1, 0); /* NANDWE */ 262 at91_set_A_periph(AT91_PIN_PC1, 0); /* NANDWE */
263 263
264 nand_data = *data; 264 nand_data = *data;
265 platform_device_register(&at91_nand_device); 265 platform_device_register(&atmel_nand_device);
266} 266}
267 267
268#else 268#else
269void __init at91_add_device_nand(struct at91_nand_data *data) {} 269void __init at91_add_device_nand(struct atmel_nand_data *data) {}
270#endif 270#endif
271 271
272 272
diff --git a/arch/arm/mach-at91/at91sam9263_devices.c b/arch/arm/mach-at91/at91sam9263_devices.c
index 719667e25c98..f1dfbfe094a2 100644
--- a/arch/arm/mach-at91/at91sam9263_devices.c
+++ b/arch/arm/mach-at91/at91sam9263_devices.c
@@ -353,7 +353,7 @@ void __init at91_add_device_mmc(short mmc_id, struct at91_mmc_data *data) {}
353 * -------------------------------------------------------------------- */ 353 * -------------------------------------------------------------------- */
354 354
355#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE) 355#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE)
356static struct at91_nand_data nand_data; 356static struct atmel_nand_data nand_data;
357 357
358#define NAND_BASE AT91_CHIPSELECT_3 358#define NAND_BASE AT91_CHIPSELECT_3
359 359
@@ -371,7 +371,7 @@ static struct resource nand_resources[] = {
371}; 371};
372 372
373static struct platform_device at91sam9263_nand_device = { 373static struct platform_device at91sam9263_nand_device = {
374 .name = "at91_nand", 374 .name = "atmel_nand",
375 .id = -1, 375 .id = -1,
376 .dev = { 376 .dev = {
377 .platform_data = &nand_data, 377 .platform_data = &nand_data,
@@ -380,7 +380,7 @@ static struct platform_device at91sam9263_nand_device = {
380 .num_resources = ARRAY_SIZE(nand_resources), 380 .num_resources = ARRAY_SIZE(nand_resources),
381}; 381};
382 382
383void __init at91_add_device_nand(struct at91_nand_data *data) 383void __init at91_add_device_nand(struct atmel_nand_data *data)
384{ 384{
385 unsigned long csa, mode; 385 unsigned long csa, mode;
386 386
@@ -421,7 +421,7 @@ void __init at91_add_device_nand(struct at91_nand_data *data)
421 platform_device_register(&at91sam9263_nand_device); 421 platform_device_register(&at91sam9263_nand_device);
422} 422}
423#else 423#else
424void __init at91_add_device_nand(struct at91_nand_data *data) {} 424void __init at91_add_device_nand(struct atmel_nand_data *data) {}
425#endif 425#endif
426 426
427 427
diff --git a/arch/arm/mach-at91/at91sam9rl_devices.c b/arch/arm/mach-at91/at91sam9rl_devices.c
index 450db304936f..9945cd25d0ab 100644
--- a/arch/arm/mach-at91/at91sam9rl_devices.c
+++ b/arch/arm/mach-at91/at91sam9rl_devices.c
@@ -100,7 +100,7 @@ void __init at91_add_device_mmc(short mmc_id, struct at91_mmc_data *data) {}
100 * -------------------------------------------------------------------- */ 100 * -------------------------------------------------------------------- */
101 101
102#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE) 102#if defined(CONFIG_MTD_NAND_AT91) || defined(CONFIG_MTD_NAND_AT91_MODULE)
103static struct at91_nand_data nand_data; 103static struct atmel_nand_data nand_data;
104 104
105#define NAND_BASE AT91_CHIPSELECT_3 105#define NAND_BASE AT91_CHIPSELECT_3
106 106
@@ -117,8 +117,8 @@ static struct resource nand_resources[] = {
117 } 117 }
118}; 118};
119 119
120static struct platform_device at91_nand_device = { 120static struct platform_device atmel_nand_device = {
121 .name = "at91_nand", 121 .name = "atmel_nand",
122 .id = -1, 122 .id = -1,
123 .dev = { 123 .dev = {
124 .platform_data = &nand_data, 124 .platform_data = &nand_data,
@@ -127,7 +127,7 @@ static struct platform_device at91_nand_device = {
127 .num_resources = ARRAY_SIZE(nand_resources), 127 .num_resources = ARRAY_SIZE(nand_resources),
128}; 128};
129 129
130void __init at91_add_device_nand(struct at91_nand_data *data) 130void __init at91_add_device_nand(struct atmel_nand_data *data)
131{ 131{
132 unsigned long csa; 132 unsigned long csa;
133 133
@@ -164,11 +164,11 @@ void __init at91_add_device_nand(struct at91_nand_data *data)
164 at91_set_A_periph(AT91_PIN_PB5, 0); /* NANDWE */ 164 at91_set_A_periph(AT91_PIN_PB5, 0); /* NANDWE */
165 165
166 nand_data = *data; 166 nand_data = *data;
167 platform_device_register(&at91_nand_device); 167 platform_device_register(&atmel_nand_device);
168} 168}
169 169
170#else 170#else
171void __init at91_add_device_nand(struct at91_nand_data *data) {} 171void __init at91_add_device_nand(struct atmel_nand_data *data) {}
172#endif 172#endif
173 173
174 174
diff --git a/arch/arm/mach-at91/board-cam60.c b/arch/arm/mach-at91/board-cam60.c
index b22a1a004055..af2c33aff1a8 100644
--- a/arch/arm/mach-at91/board-cam60.c
+++ b/arch/arm/mach-at91/board-cam60.c
@@ -142,7 +142,7 @@ static struct mtd_partition * __init nand_partitions(int size, int *num_partitio
142 return cam60_nand_partition; 142 return cam60_nand_partition;
143} 143}
144 144
145static struct at91_nand_data __initdata cam60_nand_data = { 145static struct atmel_nand_data __initdata cam60_nand_data = {
146 .ale = 21, 146 .ale = 21,
147 .cle = 22, 147 .cle = 22,
148 // .det_pin = ... not there 148 // .det_pin = ... not there
diff --git a/arch/arm/mach-at91/board-cap9adk.c b/arch/arm/mach-at91/board-cap9adk.c
index e5512d1ff217..7144e1a89a2a 100644
--- a/arch/arm/mach-at91/board-cap9adk.c
+++ b/arch/arm/mach-at91/board-cap9adk.c
@@ -175,7 +175,7 @@ static struct mtd_partition * __init nand_partitions(int size, int *num_partitio
175 return cap9adk_nand_partitions; 175 return cap9adk_nand_partitions;
176} 176}
177 177
178static struct at91_nand_data __initdata cap9adk_nand_data = { 178static struct atmel_nand_data __initdata cap9adk_nand_data = {
179 .ale = 21, 179 .ale = 21,
180 .cle = 22, 180 .cle = 22,
181// .det_pin = ... not connected 181// .det_pin = ... not connected
diff --git a/arch/arm/mach-at91/board-dk.c b/arch/arm/mach-at91/board-dk.c
index c1a813c7169b..ffecacb71f89 100644
--- a/arch/arm/mach-at91/board-dk.c
+++ b/arch/arm/mach-at91/board-dk.c
@@ -150,7 +150,7 @@ static struct mtd_partition * __init nand_partitions(int size, int *num_partitio
150 return dk_nand_partition; 150 return dk_nand_partition;
151} 151}
152 152
153static struct at91_nand_data __initdata dk_nand_data = { 153static struct atmel_nand_data __initdata dk_nand_data = {
154 .ale = 22, 154 .ale = 22,
155 .cle = 21, 155 .cle = 21,
156 .det_pin = AT91_PIN_PB1, 156 .det_pin = AT91_PIN_PB1,
diff --git a/arch/arm/mach-at91/board-kb9202.c b/arch/arm/mach-at91/board-kb9202.c
index 4b39b9cda75b..153450f168f2 100644
--- a/arch/arm/mach-at91/board-kb9202.c
+++ b/arch/arm/mach-at91/board-kb9202.c
@@ -102,7 +102,7 @@ static struct mtd_partition * __init nand_partitions(int size, int *num_partitio
102 return kb9202_nand_partition; 102 return kb9202_nand_partition;
103} 103}
104 104
105static struct at91_nand_data __initdata kb9202_nand_data = { 105static struct atmel_nand_data __initdata kb9202_nand_data = {
106 .ale = 22, 106 .ale = 22,
107 .cle = 21, 107 .cle = 21,
108 // .det_pin = ... not there 108 // .det_pin = ... not there
diff --git a/arch/arm/mach-at91/board-sam9-l9260.c b/arch/arm/mach-at91/board-sam9-l9260.c
index 8f76af5e219a..57a6221943ed 100644
--- a/arch/arm/mach-at91/board-sam9-l9260.c
+++ b/arch/arm/mach-at91/board-sam9-l9260.c
@@ -141,7 +141,7 @@ static struct mtd_partition * __init nand_partitions(int size, int *num_partitio
141 return ek_nand_partition; 141 return ek_nand_partition;
142} 142}
143 143
144static struct at91_nand_data __initdata ek_nand_data = { 144static struct atmel_nand_data __initdata ek_nand_data = {
145 .ale = 21, 145 .ale = 21,
146 .cle = 22, 146 .cle = 22,
147// .det_pin = ... not connected 147// .det_pin = ... not connected
diff --git a/arch/arm/mach-at91/board-sam9260ek.c b/arch/arm/mach-at91/board-sam9260ek.c
index 4d1d9c777084..6a680795c3c8 100644
--- a/arch/arm/mach-at91/board-sam9260ek.c
+++ b/arch/arm/mach-at91/board-sam9260ek.c
@@ -178,7 +178,7 @@ static struct mtd_partition * __init nand_partitions(int size, int *num_partitio
178 return ek_nand_partition; 178 return ek_nand_partition;
179} 179}
180 180
181static struct at91_nand_data __initdata ek_nand_data = { 181static struct atmel_nand_data __initdata ek_nand_data = {
182 .ale = 21, 182 .ale = 21,
183 .cle = 22, 183 .cle = 22,
184// .det_pin = ... not connected 184// .det_pin = ... not connected
diff --git a/arch/arm/mach-at91/board-sam9261ek.c b/arch/arm/mach-at91/board-sam9261ek.c
index 08382c0df221..43dfbd0d543a 100644
--- a/arch/arm/mach-at91/board-sam9261ek.c
+++ b/arch/arm/mach-at91/board-sam9261ek.c
@@ -183,7 +183,7 @@ static struct mtd_partition * __init nand_partitions(int size, int *num_partitio
183 return ek_nand_partition; 183 return ek_nand_partition;
184} 184}
185 185
186static struct at91_nand_data __initdata ek_nand_data = { 186static struct atmel_nand_data __initdata ek_nand_data = {
187 .ale = 22, 187 .ale = 22,
188 .cle = 21, 188 .cle = 21,
189// .det_pin = ... not connected 189// .det_pin = ... not connected
diff --git a/arch/arm/mach-at91/board-sam9263ek.c b/arch/arm/mach-at91/board-sam9263ek.c
index b4cd5d0ed597..6605a0980117 100644
--- a/arch/arm/mach-at91/board-sam9263ek.c
+++ b/arch/arm/mach-at91/board-sam9263ek.c
@@ -187,7 +187,7 @@ static struct mtd_partition * __init nand_partitions(int size, int *num_partitio
187 return ek_nand_partition; 187 return ek_nand_partition;
188} 188}
189 189
190static struct at91_nand_data __initdata ek_nand_data = { 190static struct atmel_nand_data __initdata ek_nand_data = {
191 .ale = 21, 191 .ale = 21,
192 .cle = 22, 192 .cle = 22,
193// .det_pin = ... not connected 193// .det_pin = ... not connected
diff --git a/arch/arm/mach-at91/board-sam9rlek.c b/arch/arm/mach-at91/board-sam9rlek.c
index ffc0597aee8d..35e69e51f376 100644
--- a/arch/arm/mach-at91/board-sam9rlek.c
+++ b/arch/arm/mach-at91/board-sam9rlek.c
@@ -88,7 +88,7 @@ static struct mtd_partition * __init nand_partitions(int size, int *num_partitio
88 return ek_nand_partition; 88 return ek_nand_partition;
89} 89}
90 90
91static struct at91_nand_data __initdata ek_nand_data = { 91static struct atmel_nand_data __initdata ek_nand_data = {
92 .ale = 21, 92 .ale = 21,
93 .cle = 22, 93 .cle = 22,
94// .det_pin = ... not connected 94// .det_pin = ... not connected
diff --git a/arch/arm/mach-at91/board-yl-9200.c b/arch/arm/mach-at91/board-yl-9200.c
index b5717108991d..e642b3a8bd10 100755
--- a/arch/arm/mach-at91/board-yl-9200.c
+++ b/arch/arm/mach-at91/board-yl-9200.c
@@ -251,7 +251,7 @@ static struct mtd_partition * __init nand_partitions(int size, int *num_partitio
251 return yl_9200_nand_partition; 251 return yl_9200_nand_partition;
252} 252}
253 253
254static struct at91_nand_data __initdata yl_9200_nand_data = { 254static struct atmel_nand_data __initdata yl_9200_nand_data = {
255 .ale= 6, 255 .ale= 6,
256 .cle= 7, 256 .cle= 7,
257 /*.det_pin = AT91_PIN_PCxx,*/ /*we don't have a det pin because NandFlash is fixed to board*/ 257 /*.det_pin = AT91_PIN_PCxx,*/ /*we don't have a det pin because NandFlash is fixed to board*/
diff --git a/arch/avr32/boards/atstk1000/Kconfig b/arch/avr32/boards/atstk1000/Kconfig
index af90b00100fd..8dc48214f0b7 100644
--- a/arch/avr32/boards/atstk1000/Kconfig
+++ b/arch/avr32/boards/atstk1000/Kconfig
@@ -18,6 +18,10 @@ config BOARD_ATSTK1004
18 bool "ATSTK1004" 18 bool "ATSTK1004"
19 select CPU_AT32AP7002 19 select CPU_AT32AP7002
20 20
21config BOARD_ATSTK1006
22 bool "ATSTK1006"
23 select CPU_AT32AP7000
24
21endchoice 25endchoice
22 26
23 27
diff --git a/arch/avr32/boards/atstk1000/Makefile b/arch/avr32/boards/atstk1000/Makefile
index beead86462e8..edecee03742d 100644
--- a/arch/avr32/boards/atstk1000/Makefile
+++ b/arch/avr32/boards/atstk1000/Makefile
@@ -2,3 +2,4 @@ obj-y += setup.o flash.o
2obj-$(CONFIG_BOARD_ATSTK1002) += atstk1002.o 2obj-$(CONFIG_BOARD_ATSTK1002) += atstk1002.o
3obj-$(CONFIG_BOARD_ATSTK1003) += atstk1003.o 3obj-$(CONFIG_BOARD_ATSTK1003) += atstk1003.o
4obj-$(CONFIG_BOARD_ATSTK1004) += atstk1004.o 4obj-$(CONFIG_BOARD_ATSTK1004) += atstk1004.o
5obj-$(CONFIG_BOARD_ATSTK1006) += atstk1002.o
diff --git a/arch/avr32/boards/atstk1000/atstk1002.c b/arch/avr32/boards/atstk1000/atstk1002.c
index 000eb4220a12..5bfaf4d87b3f 100644
--- a/arch/avr32/boards/atstk1000/atstk1002.c
+++ b/arch/avr32/boards/atstk1000/atstk1002.c
@@ -1,7 +1,7 @@
1/* 1/*
2 * ATSTK1002 daughterboard-specific init code 2 * ATSTK1002/ATSTK1006 daughterboard-specific init code
3 * 3 *
4 * Copyright (C) 2005-2006 Atmel Corporation 4 * Copyright (C) 2005-2007 Atmel Corporation
5 * 5 *
6 * This program is free software; you can redistribute it and/or modify 6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as 7 * it under the terms of the GNU General Public License version 2 as
@@ -29,6 +29,74 @@
29#include "atstk1000.h" 29#include "atstk1000.h"
30 30
31 31
32/*
33 * The ATSTK1006 daughterboard is very similar to the ATSTK1002. Both
34 * have the AT32AP7000 chip on board; the difference is that the
35 * STK1006 has 128 MB SDRAM (the STK1002 uses the 8 MB SDRAM chip on
36 * the STK1000 motherboard) and 256 MB NAND flash (the STK1002 has
37 * none.)
38 *
39 * The RAM difference is handled by the boot loader, so the only
40 * difference we end up handling here is the NAND flash.
41 */
42#ifdef CONFIG_BOARD_ATSTK1006
43#include <linux/mtd/partitions.h>
44#include <asm/arch/smc.h>
45
46static struct smc_timing nand_timing __initdata = {
47 .ncs_read_setup = 0,
48 .nrd_setup = 10,
49 .ncs_write_setup = 0,
50 .nwe_setup = 10,
51
52 .ncs_read_pulse = 30,
53 .nrd_pulse = 15,
54 .ncs_write_pulse = 30,
55 .nwe_pulse = 15,
56
57 .read_cycle = 30,
58 .write_cycle = 30,
59
60 .ncs_read_recover = 0,
61 .nrd_recover = 15,
62 .ncs_write_recover = 0,
63 /* WE# high -> RE# low min 60 ns */
64 .nwe_recover = 50,
65};
66
67static struct smc_config nand_config __initdata = {
68 .bus_width = 1,
69 .nrd_controlled = 1,
70 .nwe_controlled = 1,
71 .nwait_mode = 0,
72 .byte_write = 0,
73 .tdf_cycles = 2,
74 .tdf_mode = 0,
75};
76
77static struct mtd_partition nand_partitions[] = {
78 {
79 .name = "main",
80 .offset = 0x00000000,
81 .size = MTDPART_SIZ_FULL,
82 },
83};
84
85static struct mtd_partition *nand_part_info(int size, int *num_partitions)
86{
87 *num_partitions = ARRAY_SIZE(nand_partitions);
88 return nand_partitions;
89}
90
91struct atmel_nand_data atstk1006_nand_data __initdata = {
92 .cle = 21,
93 .ale = 22,
94 .rdy_pin = GPIO_PIN_PB(30),
95 .enable_pin = GPIO_PIN_PB(29),
96 .partition_info = nand_part_info,
97};
98#endif
99
32struct eth_addr { 100struct eth_addr {
33 u8 addr[6]; 101 u8 addr[6];
34}; 102};
@@ -212,6 +280,12 @@ static int __init atstk1002_init(void)
212 280
213 at32_add_system_devices(); 281 at32_add_system_devices();
214 282
283#ifdef CONFIG_BOARD_ATSTK1006
284 smc_set_timing(&nand_config, &nand_timing);
285 smc_set_configuration(3, &nand_config);
286 at32_add_device_nand(0, &atstk1006_nand_data);
287#endif
288
215#ifdef CONFIG_BOARD_ATSTK100X_SW2_CUSTOM 289#ifdef CONFIG_BOARD_ATSTK100X_SW2_CUSTOM
216 at32_add_device_usart(1); 290 at32_add_device_usart(1);
217#else 291#else
diff --git a/arch/avr32/mach-at32ap/at32ap700x.c b/arch/avr32/mach-at32ap/at32ap700x.c
index 0f24b4f85c17..b65d3e0667a8 100644
--- a/arch/avr32/mach-at32ap/at32ap700x.c
+++ b/arch/avr32/mach-at32ap/at32ap700x.c
@@ -1730,6 +1730,58 @@ fail:
1730#endif 1730#endif
1731 1731
1732/* -------------------------------------------------------------------- 1732/* --------------------------------------------------------------------
1733 * NAND Flash / SmartMedia
1734 * -------------------------------------------------------------------- */
1735static struct resource smc_cs3_resource[] __initdata = {
1736 {
1737 .start = 0x0c000000,
1738 .end = 0x0fffffff,
1739 .flags = IORESOURCE_MEM,
1740 }, {
1741 .start = 0xfff03c00,
1742 .end = 0xfff03fff,
1743 .flags = IORESOURCE_MEM,
1744 },
1745};
1746
1747struct platform_device *__init
1748at32_add_device_nand(unsigned int id, struct atmel_nand_data *data)
1749{
1750 struct platform_device *pdev;
1751
1752 if (id != 0 || !data)
1753 return NULL;
1754
1755 pdev = platform_device_alloc("atmel_nand", id);
1756 if (!pdev)
1757 goto fail;
1758
1759 if (platform_device_add_resources(pdev, smc_cs3_resource,
1760 ARRAY_SIZE(smc_cs3_resource)))
1761 goto fail;
1762
1763 if (platform_device_add_data(pdev, data,
1764 sizeof(struct atmel_nand_data)))
1765 goto fail;
1766
1767 set_ebi_sfr_bits(HMATRIX_BIT(CS3A));
1768 if (data->enable_pin)
1769 at32_select_gpio(data->enable_pin,
1770 AT32_GPIOF_OUTPUT | AT32_GPIOF_HIGH);
1771 if (data->rdy_pin)
1772 at32_select_gpio(data->rdy_pin, 0);
1773 if (data->det_pin)
1774 at32_select_gpio(data->det_pin, 0);
1775
1776 platform_device_add(pdev);
1777 return pdev;
1778
1779fail:
1780 platform_device_put(pdev);
1781 return NULL;
1782}
1783
1784/* --------------------------------------------------------------------
1733 * AC97C 1785 * AC97C
1734 * -------------------------------------------------------------------- */ 1786 * -------------------------------------------------------------------- */
1735static struct resource atmel_ac97c0_resource[] __initdata = { 1787static struct resource atmel_ac97c0_resource[] __initdata = {
diff --git a/arch/avr32/mach-at32ap/hsmc.c b/arch/avr32/mach-at32ap/hsmc.c
index fa427ed42787..b2d9bc61a35c 100644
--- a/arch/avr32/mach-at32ap/hsmc.c
+++ b/arch/avr32/mach-at32ap/hsmc.c
@@ -278,4 +278,4 @@ static int __init hsmc_init(void)
278{ 278{
279 return platform_driver_register(&hsmc_driver); 279 return platform_driver_register(&hsmc_driver);
280} 280}
281arch_initcall(hsmc_init); 281core_initcall(hsmc_init);