diff options
Diffstat (limited to 'arch/arm/mach-s3c2410/devs.c')
-rw-r--r-- | arch/arm/mach-s3c2410/devs.c | 74 |
1 files changed, 46 insertions, 28 deletions
diff --git a/arch/arm/mach-s3c2410/devs.c b/arch/arm/mach-s3c2410/devs.c index f58406e6ef5a..ca09ba516e4c 100644 --- a/arch/arm/mach-s3c2410/devs.c +++ b/arch/arm/mach-s3c2410/devs.c @@ -10,6 +10,7 @@ * published by the Free Software Foundation. * * Modifications: + * 15-Jan-2006 LCVR Using S3C24XX_PA_##x macro for common S3C24XX devices * 10-Mar-2005 LCVR Changed S3C2410_{VA,SZ} to S3C24XX_{VA,SZ} * 10-Feb-2005 BJD Added camera from guillaume.gourat@nexvision.tv * 29-Aug-2004 BJD Added timers 0 through 3 @@ -46,8 +47,8 @@ struct platform_device *s3c24xx_uart_devs[3]; static struct resource s3c_usb_resource[] = { [0] = { - .start = S3C2410_PA_USBHOST, - .end = S3C2410_PA_USBHOST + S3C24XX_SZ_USBHOST - 1, + .start = S3C24XX_PA_USBHOST, + .end = S3C24XX_PA_USBHOST + S3C24XX_SZ_USBHOST - 1, .flags = IORESOURCE_MEM, }, [1] = { @@ -76,8 +77,8 @@ EXPORT_SYMBOL(s3c_device_usb); static struct resource s3c_lcd_resource[] = { [0] = { - .start = S3C2410_PA_LCD, - .end = S3C2410_PA_LCD + S3C24XX_SZ_LCD - 1, + .start = S3C24XX_PA_LCD, + .end = S3C24XX_PA_LCD + S3C24XX_SZ_LCD - 1, .flags = IORESOURCE_MEM, }, [1] = { @@ -139,8 +140,8 @@ EXPORT_SYMBOL(s3c_device_nand); static struct resource s3c_usbgadget_resource[] = { [0] = { - .start = S3C2410_PA_USBDEV, - .end = S3C2410_PA_USBDEV + S3C24XX_SZ_USBDEV - 1, + .start = S3C24XX_PA_USBDEV, + .end = S3C24XX_PA_USBDEV + S3C24XX_SZ_USBDEV - 1, .flags = IORESOURCE_MEM, }, [1] = { @@ -164,8 +165,8 @@ EXPORT_SYMBOL(s3c_device_usbgadget); static struct resource s3c_wdt_resource[] = { [0] = { - .start = S3C2410_PA_WATCHDOG, - .end = S3C2410_PA_WATCHDOG + S3C24XX_SZ_WATCHDOG - 1, + .start = S3C24XX_PA_WATCHDOG, + .end = S3C24XX_PA_WATCHDOG + S3C24XX_SZ_WATCHDOG - 1, .flags = IORESOURCE_MEM, }, [1] = { @@ -189,8 +190,8 @@ EXPORT_SYMBOL(s3c_device_wdt); static struct resource s3c_i2c_resource[] = { [0] = { - .start = S3C2410_PA_IIC, - .end = S3C2410_PA_IIC + S3C24XX_SZ_IIC - 1, + .start = S3C24XX_PA_IIC, + .end = S3C24XX_PA_IIC + S3C24XX_SZ_IIC - 1, .flags = IORESOURCE_MEM, }, [1] = { @@ -214,8 +215,8 @@ EXPORT_SYMBOL(s3c_device_i2c); static struct resource s3c_iis_resource[] = { [0] = { - .start = S3C2410_PA_IIS, - .end = S3C2410_PA_IIS + S3C24XX_SZ_IIS -1, + .start = S3C24XX_PA_IIS, + .end = S3C24XX_PA_IIS + S3C24XX_SZ_IIS -1, .flags = IORESOURCE_MEM, } }; @@ -239,8 +240,8 @@ EXPORT_SYMBOL(s3c_device_iis); static struct resource s3c_rtc_resource[] = { [0] = { - .start = S3C2410_PA_RTC, - .end = S3C2410_PA_RTC + 0xff, + .start = S3C24XX_PA_RTC, + .end = S3C24XX_PA_RTC + 0xff, .flags = IORESOURCE_MEM, }, [1] = { @@ -268,12 +269,17 @@ EXPORT_SYMBOL(s3c_device_rtc); static struct resource s3c_adc_resource[] = { [0] = { - .start = S3C2410_PA_ADC, - .end = S3C2410_PA_ADC + S3C24XX_SZ_ADC - 1, + .start = S3C24XX_PA_ADC, + .end = S3C24XX_PA_ADC + S3C24XX_SZ_ADC - 1, .flags = IORESOURCE_MEM, }, [1] = { .start = IRQ_TC, + .end = IRQ_TC, + .flags = IORESOURCE_IRQ, + }, + [2] = { + .start = IRQ_ADC, .end = IRQ_ADC, .flags = IORESOURCE_IRQ, } @@ -316,8 +322,8 @@ EXPORT_SYMBOL(s3c_device_sdi); static struct resource s3c_spi0_resource[] = { [0] = { - .start = S3C2410_PA_SPI, - .end = S3C2410_PA_SPI + 0x1f, + .start = S3C24XX_PA_SPI, + .end = S3C24XX_PA_SPI + 0x1f, .flags = IORESOURCE_MEM, }, [1] = { @@ -328,11 +334,17 @@ static struct resource s3c_spi0_resource[] = { }; +static u64 s3c_device_spi0_dmamask = 0xffffffffUL; + struct platform_device s3c_device_spi0 = { .name = "s3c2410-spi", .id = 0, .num_resources = ARRAY_SIZE(s3c_spi0_resource), .resource = s3c_spi0_resource, + .dev = { + .dma_mask = &s3c_device_spi0_dmamask, + .coherent_dma_mask = 0xffffffffUL + } }; EXPORT_SYMBOL(s3c_device_spi0); @@ -341,8 +353,8 @@ EXPORT_SYMBOL(s3c_device_spi0); static struct resource s3c_spi1_resource[] = { [0] = { - .start = S3C2410_PA_SPI + 0x20, - .end = S3C2410_PA_SPI + 0x20 + 0x1f, + .start = S3C24XX_PA_SPI + 0x20, + .end = S3C24XX_PA_SPI + 0x20 + 0x1f, .flags = IORESOURCE_MEM, }, [1] = { @@ -353,11 +365,17 @@ static struct resource s3c_spi1_resource[] = { }; +static u64 s3c_device_spi1_dmamask = 0xffffffffUL; + struct platform_device s3c_device_spi1 = { .name = "s3c2410-spi", .id = 1, .num_resources = ARRAY_SIZE(s3c_spi1_resource), .resource = s3c_spi1_resource, + .dev = { + .dma_mask = &s3c_device_spi1_dmamask, + .coherent_dma_mask = 0xffffffffUL + } }; EXPORT_SYMBOL(s3c_device_spi1); @@ -366,8 +384,8 @@ EXPORT_SYMBOL(s3c_device_spi1); static struct resource s3c_timer0_resource[] = { [0] = { - .start = S3C2410_PA_TIMER + 0x0C, - .end = S3C2410_PA_TIMER + 0x0C + 0xB, + .start = S3C24XX_PA_TIMER + 0x0C, + .end = S3C24XX_PA_TIMER + 0x0C + 0xB, .flags = IORESOURCE_MEM, }, [1] = { @@ -391,8 +409,8 @@ EXPORT_SYMBOL(s3c_device_timer0); static struct resource s3c_timer1_resource[] = { [0] = { - .start = S3C2410_PA_TIMER + 0x18, - .end = S3C2410_PA_TIMER + 0x23, + .start = S3C24XX_PA_TIMER + 0x18, + .end = S3C24XX_PA_TIMER + 0x23, .flags = IORESOURCE_MEM, }, [1] = { @@ -416,8 +434,8 @@ EXPORT_SYMBOL(s3c_device_timer1); static struct resource s3c_timer2_resource[] = { [0] = { - .start = S3C2410_PA_TIMER + 0x24, - .end = S3C2410_PA_TIMER + 0x2F, + .start = S3C24XX_PA_TIMER + 0x24, + .end = S3C24XX_PA_TIMER + 0x2F, .flags = IORESOURCE_MEM, }, [1] = { @@ -441,8 +459,8 @@ EXPORT_SYMBOL(s3c_device_timer2); static struct resource s3c_timer3_resource[] = { [0] = { - .start = S3C2410_PA_TIMER + 0x30, - .end = S3C2410_PA_TIMER + 0x3B, + .start = S3C24XX_PA_TIMER + 0x30, + .end = S3C24XX_PA_TIMER + 0x3B, .flags = IORESOURCE_MEM, }, [1] = { |