]> git.karo-electronics.de Git - linux-beck.git/commitdiff
mfd/gpio: Move HTC GPIO driver to GPIO subsystem
authorLinus Walleij <linus.walleij@linaro.org>
Fri, 16 Sep 2016 11:48:12 +0000 (13:48 +0200)
committerLinus Walleij <linus.walleij@linaro.org>
Wed, 28 Sep 2016 16:28:34 +0000 (09:28 -0700)
The HTC GPIO driver is a pure GPIO driver and I just can not
see what it is doing inside MFD. Let's just move it to GPIO
and take this opportunity to move the platform data to
<linux/platform_data/gpio-htc-egpio.h>

Cc: arm@kernel.org
Cc: Russell King <linux@armlinux.org.uk>
Acked-by: Lee Jones <lee.jones@linaro.org>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
arch/arm/mach-pxa/hx4700.c
arch/arm/mach-pxa/magician.c
arch/arm/mach-sa1100/h3xxx.c
drivers/gpio/Kconfig
drivers/gpio/Makefile
drivers/gpio/gpio-htc-egpio.c [moved from drivers/mfd/htc-egpio.c with 99% similarity]
drivers/mfd/Kconfig
drivers/mfd/Makefile
include/linux/platform_data/gpio-htc-egpio.h [moved from include/linux/mfd/htc-egpio.h with 100% similarity]

index 4a2f9aba93ea9ee158c2b2283d80d3fac99fd056..66184f5cbe402c47d26ff5370b6b22967231c6d9 100644 (file)
 #include <linux/input.h>
 #include <linux/input/navpoint.h>
 #include <linux/lcd.h>
-#include <linux/mfd/htc-egpio.h>
 #include <linux/mfd/asic3.h>
 #include <linux/mtd/physmap.h>
 #include <linux/pda_power.h>
+#include <linux/platform_data/gpio-htc-egpio.h>
 #include <linux/pwm.h>
 #include <linux/pwm_backlight.h>
 #include <linux/regulator/driver.h>
index abc9181693674d0b11f34c52eb619bc31495fd20..265f48be32c197daf6e69094ca844cf4d3bde5fa 100644 (file)
 #include <linux/gpio.h>
 #include <linux/gpio_keys.h>
 #include <linux/input.h>
-#include <linux/mfd/htc-egpio.h>
 #include <linux/mfd/htc-pasic3.h>
 #include <linux/mtd/physmap.h>
 #include <linux/pda_power.h>
+#include <linux/platform_data/gpio-htc-egpio.h>
 #include <linux/pwm.h>
 #include <linux/pwm_backlight.h>
 #include <linux/regulator/driver.h>
index b1d4faa12f9af4a8f736947521cd6e3987648326..b69e76614d5ba76c6ed6bc745cb253e6a4db612a 100644 (file)
@@ -14,9 +14,9 @@
 #include <linux/gpio.h>
 #include <linux/gpio_keys.h>
 #include <linux/input.h>
-#include <linux/mfd/htc-egpio.h>
 #include <linux/mtd/mtd.h>
 #include <linux/mtd/partitions.h>
+#include <linux/platform_data/gpio-htc-egpio.h>
 #include <linux/platform_data/sa11x0-serial.h>
 #include <linux/platform_device.h>
 #include <linux/serial_core.h>
index 98dd47a30fc754af1aede05d31dc2c6179d6d2b1..03be200619a4735a6a66e4890dcc603856d96baa 100644 (file)
@@ -848,6 +848,14 @@ config GPIO_DLN2
          This driver can also be built as a module. If so, the module
          will be called gpio-dln2.
 
+config HTC_EGPIO
+       bool "HTC EGPIO support"
+       depends on GPIOLIB && ARM
+       help
+           This driver supports the CPLD egpio chip present on
+           several HTC phones.  It provides basic support for input
+           pins, output pins, and irqs.
+
 config GPIO_JANZ_TTL
        tristate "Janz VMOD-TTL Digital IO Module"
        depends on MFD_JANZ_CMODIO
index 2a035ed8f168196ec7596d303685b439b2c2938e..32ebc07074ed2f40730f65aaea45ddaced6f63eb 100644 (file)
@@ -45,6 +45,7 @@ obj-$(CONFIG_GPIO_ETRAXFS)    += gpio-etraxfs.o
 obj-$(CONFIG_GPIO_F7188X)      += gpio-f7188x.o
 obj-$(CONFIG_GPIO_GE_FPGA)     += gpio-ge.o
 obj-$(CONFIG_GPIO_GRGPIO)      += gpio-grgpio.o
+obj-$(CONFIG_HTC_EGPIO)                += gpio-htc-egpio.o
 obj-$(CONFIG_GPIO_ICH)         += gpio-ich.o
 obj-$(CONFIG_GPIO_IOP)         += gpio-iop.o
 obj-$(CONFIG_GPIO_IT87)                += gpio-it87.o
similarity index 99%
rename from drivers/mfd/htc-egpio.c
rename to drivers/gpio/gpio-htc-egpio.c
index 513cfc5c8fb62703529c2e714f70b7bbdf857306..0b4df6051097ef70cae55838572cc1d698438edd 100644 (file)
 #include <linux/irq.h>
 #include <linux/io.h>
 #include <linux/spinlock.h>
+#include <linux/platform_data/gpio-htc-egpio.h>
 #include <linux/platform_device.h>
 #include <linux/slab.h>
 #include <linux/module.h>
-#include <linux/mfd/htc-egpio.h>
 
 struct egpio_chip {
        int              reg_start;
index 2d1fb64205924de8ab87e14608004fc169557cea..8634d60837fc4ddc6afdd02025a8246ca1215382 100644 (file)
@@ -340,14 +340,6 @@ config MFD_HI655X_PMIC
        help
          Select this option to enable Hisilicon hi655x series pmic driver.
 
-config HTC_EGPIO
-       bool "HTC EGPIO support"
-       depends on GPIOLIB && ARM
-       help
-           This driver supports the CPLD egpio chip present on
-           several HTC phones.  It provides basic support for input
-           pins, output pins, and irqs.
-
 config HTC_PASIC3
        tristate "HTC PASIC3 LED/DS1WM chip support"
        select MFD_CORE
index 2ba3ba35f745309de62050ab8442cea87a0edb2e..a5f1bf153b647c60b40a607b470ad59c28a838de 100644 (file)
@@ -18,7 +18,6 @@ rtsx_pci-objs                 := rtsx_pcr.o rts5209.o rts5229.o rtl8411.o rts5227.o rts5249.o
 obj-$(CONFIG_MFD_RTSX_PCI)     += rtsx_pci.o
 obj-$(CONFIG_MFD_RTSX_USB)     += rtsx_usb.o
 
-obj-$(CONFIG_HTC_EGPIO)                += htc-egpio.o
 obj-$(CONFIG_HTC_PASIC3)       += htc-pasic3.o
 obj-$(CONFIG_HTC_I2CPLD)       += htc-i2cpld.o