diff options
author | Mike Dunn <mikedunn@newsguy.com> | 2012-12-27 13:02:19 -0500 |
---|---|---|
committer | Haojian Zhuang <haojian.zhuang@linaro.org> | 2013-01-23 03:47:56 -0500 |
commit | 8b8842bfcb95b0e2c1f654be1e8c42f7fe02c21a (patch) | |
tree | 933408e7114d694acbe247ededcf18a783030297 /arch/arm/mach-pxa | |
parent | 7d1f9aeff1ee4a20b1aeb377dd0f579fe9647619 (diff) |
ARM: palmtreo: add docg4 device initialization
This patch adds initialization of the docg4 nand flash device to the treo680.
Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
Reviewed-by: Marek Vasut <marex@denx.de>
Acked-by: Tomas Cech <sleep_walker@suse.cz>
Signed-off-by: Haojian Zhuang <haojian.zhuang@gmail.com>
Diffstat (limited to 'arch/arm/mach-pxa')
-rw-r--r-- | arch/arm/mach-pxa/palmtreo.c | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/arch/arm/mach-pxa/palmtreo.c b/arch/arm/mach-pxa/palmtreo.c index 3f3c48f2f7ce..515343506821 100644 --- a/arch/arm/mach-pxa/palmtreo.c +++ b/arch/arm/mach-pxa/palmtreo.c | |||
@@ -396,6 +396,36 @@ static inline void palmtreo_leds_init(void) {} | |||
396 | #endif | 396 | #endif |
397 | 397 | ||
398 | /****************************************************************************** | 398 | /****************************************************************************** |
399 | * diskonchip docg4 flash | ||
400 | ******************************************************************************/ | ||
401 | #if defined(CONFIG_MACH_TREO680) | ||
402 | /* REVISIT: does the centro have this device also? */ | ||
403 | #if IS_ENABLED(CONFIG_MTD_NAND_DOCG4) | ||
404 | static struct resource docg4_resources[] = { | ||
405 | { | ||
406 | .start = 0x00000000, | ||
407 | .end = 0x00001FFF, | ||
408 | .flags = IORESOURCE_MEM, | ||
409 | }, | ||
410 | }; | ||
411 | |||
412 | static struct platform_device treo680_docg4_flash = { | ||
413 | .name = "docg4", | ||
414 | .id = -1, | ||
415 | .resource = docg4_resources, | ||
416 | .num_resources = ARRAY_SIZE(docg4_resources), | ||
417 | }; | ||
418 | |||
419 | static void __init treo680_docg4_flash_init(void) | ||
420 | { | ||
421 | platform_device_register(&treo680_docg4_flash); | ||
422 | } | ||
423 | #else | ||
424 | static inline void treo680_docg4_flash_init(void) {} | ||
425 | #endif | ||
426 | #endif | ||
427 | |||
428 | /****************************************************************************** | ||
399 | * Machine init | 429 | * Machine init |
400 | ******************************************************************************/ | 430 | ******************************************************************************/ |
401 | static void __init treo_reserve(void) | 431 | static void __init treo_reserve(void) |
@@ -430,6 +460,7 @@ static void __init treo680_init(void) | |||
430 | palmphone_common_init(); | 460 | palmphone_common_init(); |
431 | palm27x_mmc_init(GPIO_NR_TREO_SD_DETECT_N, GPIO_NR_TREO680_SD_READONLY, | 461 | palm27x_mmc_init(GPIO_NR_TREO_SD_DETECT_N, GPIO_NR_TREO680_SD_READONLY, |
432 | GPIO_NR_TREO680_SD_POWER, 0); | 462 | GPIO_NR_TREO680_SD_POWER, 0); |
463 | treo680_docg4_flash_init(); | ||
433 | } | 464 | } |
434 | #endif | 465 | #endif |
435 | 466 | ||