Move S3C24XX ADC driver to plat-samsung
Subsystems (3)
PATCH 1/2 Move S3C24XX ADC driver to plat-samsung
Move S3C24XX ADC driver to plat-samsung
Signed-off-by Maurus Cuelenaere <[email protected]>
--- arch/arm/configs/mini2440_defconfig | 2 +- arch/arm/configs/s3c2410_defconfig | 2 +- arch/arm/plat-s3c/include/plat/adc.h | 35 --- arch/arm/plat-s3c24xx/Kconfig | 7 - arch/arm/plat-s3c24xx/Makefile | 1 - arch/arm/plat-s3c24xx/adc.c | 435 ------------------------------ arch/arm/plat-samsung/Kconfig | 9 + arch/arm/plat-samsung/Makefile | 4 + arch/arm/plat-samsung/adc.c | 435 ++++++++++++++++++++++++++++++ arch/arm/plat-samsung/include/plat/adc.h | 35 +++ 10 files changed, 485 insertions(+), 480 deletions(-) delete mode 100644 arch/arm/plat-s3c/include/plat/adc.h delete mode 100644 arch/arm/plat-s3c24xx/adc.c create mode 100644 arch/arm/plat-samsung/adc.c create mode 100644 arch/arm/plat-samsung/include/plat/adc.h
(quoted diff) +0 -0
b/arch/arm/configs/mini2440_defconfig
index d2a90eb..4c46644 100644
arch/arm/configs/mini2440_defconfig +1 -1
@@ -184,7 +184,7 @@ CONFIG_S3C24XX_PWM=y CONFIG_S3C24XX_GPIO_EXTRA=0 CONFIG_S3C2410_DMA=y # CONFIG_S3C2410_DMA_DEBUG is not set -CONFIG_S3C24XX_ADC=y +CONFIG_S3C_ADC=y CONFIG_PLAT_S3C=y CONFIG_CPU_LLSERIAL_S3C2440_ONLY=y CONFIG_CPU_LLSERIAL_S3C2440=y
(quoted diff) +0 -0
b/arch/arm/configs/s3c2410_defconfig
index 2f10dae..9697e97 100644
arch/arm/configs/s3c2410_defconfig +1 -1
@@ -187,7 +187,7 @@ CONFIG_S3C24XX_GPIO_EXTRA128=y CONFIG_PM_SIMTEC=y CONFIG_S3C2410_DMA=y # CONFIG_S3C2410_DMA_DEBUG is not set -CONFIG_S3C24XX_ADC=y +CONFIG_S3C_ADC=y CONFIG_MACH_SMDK=y CONFIG_PLAT_S3C=y CONFIG_CPU_LLSERIAL_S3C2410=y
(quoted diff) +0 -0
b/arch/arm/plat-s3c/include/plat/adc.h
deleted file mode 100644
index 5f3b1cd..0000000
arch/arm/plat-s3c/include/plat/adc.h deleted +0 -35
@@ -1,35 +0,0 @@ -/* arch/arm/plat-s3c/include/plat/adc.h -* -* Copyright (c) 2008 Simtec Electronics -* http://armlinux.simnte.co.uk/ -* Ben Dooks <[email protected]> -* -* S3C24XX ADC driver information -* -* This program is free software; you can redistribute it and/or modify -* it under the terms of the GNU General Public License version 2 as -* published by the Free Software Foundation. -*/ - -#ifndef __ASM_PLAT_ADC_H -#define __ASM_PLAT_ADC_H __FILE__ - -struct s3c_adc_client ; - -extern int s3c_adc_start (struct s3c_adc_client *client, -unsigned int channel,unsigned int nr_samples); - -extern int s3c_adc_read (struct s3c_adc_client *client,unsigned int ch); - -extern struct s3c_adc_client * -s3c_adc_register (struct platform_device *pdev, -void (*select)(struct s3c_adc_client *client, -unsigned selected), -void (*conv)(struct s3c_adc_client *client, -unsigned d0,unsigned d1, -unsigned *samples_left), -unsigned int is_ts); - -extern void s3c_adc_release (struct s3c_adc_client *client); - -#endif /* __ASM_PLAT_ADC_H */
arch/arm/plat-s3c24xx/Kconfig +0 -7
@@ -117,13 +117,6 @@ config S3C2410_DMA_DEBUG Enable debugging output for the DMA code. This option sends info to the kernel log, at priority KERN_DEBUG. -config S3C24XX_ADC - bool "ADC common driver support" - help - Core support for the ADC block found in the S3C24XX SoC systems - for drivers such as the touchscreen and hwmon to use to share - this resource. - # SPI default pin configuration code config S3C24XX_SPI_BUS0_GPE11_GPE12_GPE13
arch/arm/plat-s3c24xx/Makefile +0 -1
@@ -38,7 +38,6 @@ obj-$(CONFIG_PM) += irq-pm.o obj-$(CONFIG_PM) += sleep.o obj-$(CONFIG_S3C2410_CLOCK) += s3c2410-clock.o obj-$(CONFIG_S3C2410_DMA) += dma.o -obj-$(CONFIG_S3C24XX_ADC) += adc.o obj-$(CONFIG_S3C2410_IOTIMING) += s3c2410-iotiming.o obj-$(CONFIG_S3C2412_IOTIMING) += s3c2412-iotiming.o obj-$(CONFIG_S3C2410_CPUFREQ_UTILS) += s3c2410-cpufreq-utils.o
arch/arm/plat-s3c24xx/adc.c deleted +0 -435
435 lines not on this page · raw message
arch/arm/plat-samsung/Kconfig +9 -0
@@ -74,6 +74,15 @@ config SAMSUNG_GPIO_EXTRA provides. This allows expanding the GPIO space for use with GPIO expanders. +# ADC driver + +config S3C_ADC + bool "ADC common driver support" + help + Core support for the ADC block found in the Samsung SoC systems + for drivers such as the touchscreen and hwmon to use to share + this resource. + # device definitions to compile in config S3C_DEV_HSMMC
arch/arm/plat-samsung/Makefile +4 -0
@@ -20,6 +20,10 @@ obj-$(CONFIG_SAMSUNG_CLKSRC) += clock-clksrc.o obj-$(CONFIG_SAMSUNG_IRQ_UART) += irq-uart.o obj-$(CONFIG_SAMSUNG_IRQ_VIC_TIMER) += irq-vic-timer.o +# ADC + +obj-$(CONFIG_S3C_ADC) += adc.o + # devices obj-$(CONFIG_S3C_DEV_HSMMC) += dev-hsmmc.o
arch/arm/plat-samsung/adc.c new file +435 -0
435 lines not on this page · raw message
(quoted diff) +0 -0
b/arch/arm/plat-samsung/include/plat/adc.h
new file mode 100644
index 0000000..e8382c7
arch/arm/plat-samsung/include/plat/adc.h new file +35 -0
@@ -0,0 +1,35 @@ +/* arch/arm/plat-samsung/include/plat/adc.h +* +* Copyright (c) 2008 Simtec Electronics +* http://armlinux.simnte.co.uk/ +* Ben Dooks <[email protected]> +* +* S3C ADC driver information +* +* This program is free software; you can redistribute it and/or modify +* it under the terms of the GNU General Public License version 2 as +* published by the Free Software Foundation. +*/ + +#ifndef __ASM_PLAT_ADC_H +#define __ASM_PLAT_ADC_H __FILE__ + +struct s3c_adc_client ; + +extern int s3c_adc_start (struct s3c_adc_client *client, +unsigned int channel,unsigned int nr_samples); + +extern int s3c_adc_read (struct s3c_adc_client *client,unsigned int ch); + +extern struct s3c_adc_client * +s3c_adc_register (struct platform_device *pdev, +void (*select)(struct s3c_adc_client *client, +unsigned selected), +void (*conv)(struct s3c_adc_client *client, +unsigned d0,unsigned d1, +unsigned *samples_left), +unsigned int is_ts); + +extern void s3c_adc_release (struct s3c_adc_client *client); + +#endif /* __ASM_PLAT_ADC_H */
Signature · 1 line
1.6.6