From 678a0222edc9da43a22145d68647500ee85e6c04 Mon Sep 17 00:00:00 2001 From: Roland Stigge Date: Fri, 17 Feb 2012 14:58:14 +0100 Subject: ARM: LPC32xx: ADC support for mach-lpc32xx This patch adds the mach specific support for the LPC32XX ADC driver (the latter being already in staging/iio) Signed-off-by: Roland Stigge Acked-by: Jonathan Cameron Acked-by: Wolfram Sang Signed-off-by: Arnd Bergmann --- arch/arm/mach-lpc32xx/common.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'arch/arm/mach-lpc32xx/common.c') diff --git a/arch/arm/mach-lpc32xx/common.c b/arch/arm/mach-lpc32xx/common.c index 369b152896cd..6c76bb36559b 100644 --- a/arch/arm/mach-lpc32xx/common.c +++ b/arch/arm/mach-lpc32xx/common.c @@ -137,6 +137,28 @@ struct platform_device lpc32xx_rtc_device = { .resource = lpc32xx_rtc_resources, }; +/* + * ADC support + */ +static struct resource adc_resources[] = { + { + .start = LPC32XX_ADC_BASE, + .end = LPC32XX_ADC_BASE + SZ_4K - 1, + .flags = IORESOURCE_MEM, + }, { + .start = IRQ_LPC32XX_TS_IRQ, + .end = IRQ_LPC32XX_TS_IRQ, + .flags = IORESOURCE_IRQ, + }, +}; + +struct platform_device lpc32xx_adc_device = { + .name = "lpc32xx-adc", + .id = -1, + .num_resources = ARRAY_SIZE(adc_resources), + .resource = adc_resources, +}; + /* * Returns the unique ID for the device */ -- cgit v1.2.1