diff options
| author | Ingo Molnar <mingo@elte.hu> | 2008-11-10 03:16:27 -0500 |
|---|---|---|
| committer | Ingo Molnar <mingo@elte.hu> | 2008-11-10 03:16:27 -0500 |
| commit | 4ecd33d930591d41fe356160593a9076467b961c (patch) | |
| tree | b9051a334540bbce38db1b2b03cebb4cf1d51f73 /arch/mips/alchemy/common | |
| parent | 7d5a78cd98c3a5eb83bd6a061c5ea6ef1e9b8fcb (diff) | |
| parent | f7160c7573615ec82c691e294cf80d920b5d588d (diff) | |
Merge commit 'v2.6.28-rc4' into x86/apic
Diffstat (limited to 'arch/mips/alchemy/common')
| -rw-r--r-- | arch/mips/alchemy/common/platform.c | 98 |
1 files changed, 74 insertions, 24 deletions
diff --git a/arch/mips/alchemy/common/platform.c b/arch/mips/alchemy/common/platform.c index dc8a67efac2..5c76c6448e0 100644 --- a/arch/mips/alchemy/common/platform.c +++ b/arch/mips/alchemy/common/platform.c | |||
| @@ -17,6 +17,8 @@ | |||
| 17 | #include <linux/init.h> | 17 | #include <linux/init.h> |
| 18 | 18 | ||
| 19 | #include <asm/mach-au1x00/au1xxx.h> | 19 | #include <asm/mach-au1x00/au1xxx.h> |
| 20 | #include <asm/mach-au1x00/au1xxx_dbdma.h> | ||
| 21 | #include <asm/mach-au1x00/au1100_mmc.h> | ||
| 20 | 22 | ||
| 21 | #define PORT(_base, _irq) \ | 23 | #define PORT(_base, _irq) \ |
| 22 | { \ | 24 | { \ |
| @@ -163,24 +165,6 @@ static struct resource au1xxx_usb_gdt_resources[] = { | |||
| 163 | }, | 165 | }, |
| 164 | }; | 166 | }; |
| 165 | 167 | ||
| 166 | static struct resource au1xxx_mmc_resources[] = { | ||
| 167 | [0] = { | ||
| 168 | .start = SD0_PHYS_ADDR, | ||
| 169 | .end = SD0_PHYS_ADDR + 0x7ffff, | ||
| 170 | .flags = IORESOURCE_MEM, | ||
| 171 | }, | ||
| 172 | [1] = { | ||
| 173 | .start = SD1_PHYS_ADDR, | ||
| 174 | .end = SD1_PHYS_ADDR + 0x7ffff, | ||
| 175 | .flags = IORESOURCE_MEM, | ||
| 176 | }, | ||
| 177 | [2] = { | ||
| 178 | .start = AU1200_SD_INT, | ||
| 179 | .end = AU1200_SD_INT, | ||
| 180 | .flags = IORESOURCE_IRQ, | ||
| 181 | } | ||
| 182 | }; | ||
| 183 | |||
| 184 | static u64 udc_dmamask = DMA_32BIT_MASK; | 168 | static u64 udc_dmamask = DMA_32BIT_MASK; |
| 185 | 169 | ||
| 186 | static struct platform_device au1xxx_usb_gdt_device = { | 170 | static struct platform_device au1xxx_usb_gdt_device = { |
| @@ -249,16 +233,79 @@ static struct platform_device au1200_lcd_device = { | |||
| 249 | 233 | ||
| 250 | static u64 au1xxx_mmc_dmamask = DMA_32BIT_MASK; | 234 | static u64 au1xxx_mmc_dmamask = DMA_32BIT_MASK; |
| 251 | 235 | ||
| 252 | static struct platform_device au1xxx_mmc_device = { | 236 | extern struct au1xmmc_platform_data au1xmmc_platdata[2]; |
| 237 | |||
| 238 | static struct resource au1200_mmc0_resources[] = { | ||
| 239 | [0] = { | ||
| 240 | .start = SD0_PHYS_ADDR, | ||
| 241 | .end = SD0_PHYS_ADDR + 0x7ffff, | ||
| 242 | .flags = IORESOURCE_MEM, | ||
| 243 | }, | ||
| 244 | [1] = { | ||
| 245 | .start = AU1200_SD_INT, | ||
| 246 | .end = AU1200_SD_INT, | ||
| 247 | .flags = IORESOURCE_IRQ, | ||
| 248 | }, | ||
| 249 | [2] = { | ||
| 250 | .start = DSCR_CMD0_SDMS_TX0, | ||
| 251 | .end = DSCR_CMD0_SDMS_TX0, | ||
| 252 | .flags = IORESOURCE_DMA, | ||
| 253 | }, | ||
| 254 | [3] = { | ||
| 255 | .start = DSCR_CMD0_SDMS_RX0, | ||
| 256 | .end = DSCR_CMD0_SDMS_RX0, | ||
| 257 | .flags = IORESOURCE_DMA, | ||
| 258 | } | ||
| 259 | }; | ||
| 260 | |||
| 261 | static struct platform_device au1200_mmc0_device = { | ||
| 253 | .name = "au1xxx-mmc", | 262 | .name = "au1xxx-mmc", |
| 254 | .id = 0, | 263 | .id = 0, |
| 255 | .dev = { | 264 | .dev = { |
| 256 | .dma_mask = &au1xxx_mmc_dmamask, | 265 | .dma_mask = &au1xxx_mmc_dmamask, |
| 257 | .coherent_dma_mask = DMA_32BIT_MASK, | 266 | .coherent_dma_mask = DMA_32BIT_MASK, |
| 267 | .platform_data = &au1xmmc_platdata[0], | ||
| 258 | }, | 268 | }, |
| 259 | .num_resources = ARRAY_SIZE(au1xxx_mmc_resources), | 269 | .num_resources = ARRAY_SIZE(au1200_mmc0_resources), |
| 260 | .resource = au1xxx_mmc_resources, | 270 | .resource = au1200_mmc0_resources, |
| 261 | }; | 271 | }; |
| 272 | |||
| 273 | #ifndef CONFIG_MIPS_DB1200 | ||
| 274 | static struct resource au1200_mmc1_resources[] = { | ||
| 275 | [0] = { | ||
| 276 | .start = SD1_PHYS_ADDR, | ||
| 277 | .end = SD1_PHYS_ADDR + 0x7ffff, | ||
| 278 | .flags = IORESOURCE_MEM, | ||
| 279 | }, | ||
| 280 | [1] = { | ||
| 281 | .start = AU1200_SD_INT, | ||
| 282 | .end = AU1200_SD_INT, | ||
| 283 | .flags = IORESOURCE_IRQ, | ||
| 284 | }, | ||
| 285 | [2] = { | ||
| 286 | .start = DSCR_CMD0_SDMS_TX1, | ||
| 287 | .end = DSCR_CMD0_SDMS_TX1, | ||
| 288 | .flags = IORESOURCE_DMA, | ||
| 289 | }, | ||
| 290 | [3] = { | ||
| 291 | .start = DSCR_CMD0_SDMS_RX1, | ||
| 292 | .end = DSCR_CMD0_SDMS_RX1, | ||
| 293 | .flags = IORESOURCE_DMA, | ||
| 294 | } | ||
| 295 | }; | ||
| 296 | |||
| 297 | static struct platform_device au1200_mmc1_device = { | ||
| 298 | .name = "au1xxx-mmc", | ||
| 299 | .id = 1, | ||
| 300 | .dev = { | ||
| 301 | .dma_mask = &au1xxx_mmc_dmamask, | ||
| 302 | .coherent_dma_mask = DMA_32BIT_MASK, | ||
| 303 | .platform_data = &au1xmmc_platdata[1], | ||
| 304 | }, | ||
| 305 | .num_resources = ARRAY_SIZE(au1200_mmc1_resources), | ||
| 306 | .resource = au1200_mmc1_resources, | ||
| 307 | }; | ||
| 308 | #endif /* #ifndef CONFIG_MIPS_DB1200 */ | ||
| 262 | #endif /* #ifdef CONFIG_SOC_AU1200 */ | 309 | #endif /* #ifdef CONFIG_SOC_AU1200 */ |
| 263 | 310 | ||
| 264 | static struct platform_device au1x00_pcmcia_device = { | 311 | static struct platform_device au1x00_pcmcia_device = { |
| @@ -296,7 +343,10 @@ static struct platform_device *au1xxx_platform_devices[] __initdata = { | |||
| 296 | &au1xxx_usb_gdt_device, | 343 | &au1xxx_usb_gdt_device, |
| 297 | &au1xxx_usb_otg_device, | 344 | &au1xxx_usb_otg_device, |
| 298 | &au1200_lcd_device, | 345 | &au1200_lcd_device, |
| 299 | &au1xxx_mmc_device, | 346 | &au1200_mmc0_device, |
| 347 | #ifndef CONFIG_MIPS_DB1200 | ||
| 348 | &au1200_mmc1_device, | ||
| 349 | #endif | ||
| 300 | #endif | 350 | #endif |
| 301 | #ifdef SMBUS_PSC_BASE | 351 | #ifdef SMBUS_PSC_BASE |
| 302 | &pbdb_smbus_device, | 352 | &pbdb_smbus_device, |
