diff options
author | Sukumar Ghorai <s-ghorai@ti.com> | 2010-07-09 05:14:46 -0400 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2010-08-02 08:41:17 -0400 |
commit | f450d86790ebf72ac93c7ea5addd6fa278aae64c (patch) | |
tree | 9ac542aca70b6845edad0ca026afc358e76bd97c /arch/arm/mach-omap2/board-devkit8000.c | |
parent | 2c01946c6b9ebaa5a89710bc42ca224a7f52f227 (diff) |
omap3 nand: fix issue in board file to detect nand
Board file modified for not to provide gpmc phys_base address to nand driver.
The gpmc_nand_init funciton is now used to detect the nand and required to
adopt _prob function as in nand/omap2.c
Signed-off-by: Sukumar Ghorai <s-ghorai@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap2/board-devkit8000.c')
-rw-r--r-- | arch/arm/mach-omap2/board-devkit8000.c | 25 |
1 files changed, 1 insertions, 24 deletions
diff --git a/arch/arm/mach-omap2/board-devkit8000.c b/arch/arm/mach-omap2/board-devkit8000.c index f8303f7bbe76..96e16f76ff44 100644 --- a/arch/arm/mach-omap2/board-devkit8000.c +++ b/arch/arm/mach-omap2/board-devkit8000.c | |||
@@ -59,9 +59,6 @@ | |||
59 | #include "mux.h" | 59 | #include "mux.h" |
60 | #include "hsmmc.h" | 60 | #include "hsmmc.h" |
61 | 61 | ||
62 | #define GPMC_CS0_BASE 0x60 | ||
63 | #define GPMC_CS_SIZE 0x30 | ||
64 | |||
65 | #define NAND_BLOCK_SIZE SZ_128K | 62 | #define NAND_BLOCK_SIZE SZ_128K |
66 | 63 | ||
67 | #define OMAP_DM9000_GPIO_IRQ 25 | 64 | #define OMAP_DM9000_GPIO_IRQ 25 |
@@ -105,20 +102,6 @@ static struct omap_nand_platform_data devkit8000_nand_data = { | |||
105 | .dma_channel = -1, /* disable DMA in OMAP NAND driver */ | 102 | .dma_channel = -1, /* disable DMA in OMAP NAND driver */ |
106 | }; | 103 | }; |
107 | 104 | ||
108 | static struct resource devkit8000_nand_resource = { | ||
109 | .flags = IORESOURCE_MEM, | ||
110 | }; | ||
111 | |||
112 | static struct platform_device devkit8000_nand_device = { | ||
113 | .name = "omap2-nand", | ||
114 | .id = -1, | ||
115 | .dev = { | ||
116 | .platform_data = &devkit8000_nand_data, | ||
117 | }, | ||
118 | .num_resources = 1, | ||
119 | .resource = &devkit8000_nand_resource, | ||
120 | }; | ||
121 | |||
122 | static struct omap2_hsmmc_info mmc[] = { | 105 | static struct omap2_hsmmc_info mmc[] = { |
123 | { | 106 | { |
124 | .mmc = 1, | 107 | .mmc = 1, |
@@ -591,8 +574,6 @@ static void __init devkit8000_flash_init(void) | |||
591 | u8 cs = 0; | 574 | u8 cs = 0; |
592 | u8 nandcs = GPMC_CS_NUM + 1; | 575 | u8 nandcs = GPMC_CS_NUM + 1; |
593 | 576 | ||
594 | u32 gpmc_base_add = OMAP34XX_GPMC_VIRT; | ||
595 | |||
596 | /* find out the chip-select on which NAND exists */ | 577 | /* find out the chip-select on which NAND exists */ |
597 | while (cs < GPMC_CS_NUM) { | 578 | while (cs < GPMC_CS_NUM) { |
598 | u32 ret = 0; | 579 | u32 ret = 0; |
@@ -614,13 +595,9 @@ static void __init devkit8000_flash_init(void) | |||
614 | 595 | ||
615 | if (nandcs < GPMC_CS_NUM) { | 596 | if (nandcs < GPMC_CS_NUM) { |
616 | devkit8000_nand_data.cs = nandcs; | 597 | devkit8000_nand_data.cs = nandcs; |
617 | devkit8000_nand_data.gpmc_cs_baseaddr = (void *) | ||
618 | (gpmc_base_add + GPMC_CS0_BASE + nandcs * GPMC_CS_SIZE); | ||
619 | devkit8000_nand_data.gpmc_baseaddr = (void *) | ||
620 | (gpmc_base_add); | ||
621 | 598 | ||
622 | printk(KERN_INFO "Registering NAND on CS%d\n", nandcs); | 599 | printk(KERN_INFO "Registering NAND on CS%d\n", nandcs); |
623 | if (platform_device_register(&devkit8000_nand_device) < 0) | 600 | if (gpmc_nand_init(&devkit8000_nand_data) < 0) |
624 | printk(KERN_ERR "Unable to register NAND device\n"); | 601 | printk(KERN_ERR "Unable to register NAND device\n"); |
625 | } | 602 | } |
626 | } | 603 | } |