drivers: input: touchscreen: Build correct gt9xx drivers
So we don't accidentally enable both versions of the same driver.
Change-Id: I25376b4a18d701198bf82621fe7cef185c2fd39d
Signed-off-by: Albert I <krascgq@outlook.co.id>
diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig
index a50eef7..364dc15 100644
--- a/drivers/input/touchscreen/Kconfig
+++ b/drivers/input/touchscreen/Kconfig
@@ -1148,16 +1148,6 @@
If unsure, say N.
-config TOUCHSCREEN_GT9XX_MIDO
- bool "Goodix touchpanel GT9xx series"
- depends on I2C
- help
- Say Y here if you have a Goodix GT9xx mido touchscreen.
- Gt9xx controllers are multi touch controllers which can
- report 5 touches at a time.
-
- If unsure, say N.
-
config TOUCHSCREEN_MAXIM_STI
tristate "Maxim based STI touchscreens"
depends on SPI_MASTER
diff --git a/drivers/input/touchscreen/Makefile b/drivers/input/touchscreen/Makefile
index 4792092..c138161 100644
--- a/drivers/input/touchscreen/Makefile
+++ b/drivers/input/touchscreen/Makefile
@@ -91,5 +91,8 @@
obj-$(CONFIG_TOUCHSCREEN_SYNAPTICS_DSX_FW_UPDATE) += synaptics_fw_update.o
obj-$(CONFIG_TOUCHSCREEN_FT5435) += ft5435/
obj-$(CONFIG_TOUCHSCREEN_IST3038C) += ist3038c/
+ifeq ($(CONFIG_MACH_XIAOMI_MIDO),y)
+obj-$(CONFIG_TOUCHSCREEN_GT9XX) += gt9xx_mido/
+else
obj-$(CONFIG_TOUCHSCREEN_GT9XX) += gt9xx/
-obj-$(CONFIG_TOUCHSCREEN_GT9XX_MIDO) += gt9xx_mido/
+endif
diff --git a/drivers/input/touchscreen/gt9xx_mido/Makefile b/drivers/input/touchscreen/gt9xx_mido/Makefile
index 100feff..7c7ed63 100644
--- a/drivers/input/touchscreen/gt9xx_mido/Makefile
+++ b/drivers/input/touchscreen/gt9xx_mido/Makefile
@@ -3,6 +3,6 @@
EXTRA_CFLAGS +=-Wno-error=date-time
EXTRA_CFLAGS +=-Wno-date-time
-obj-$(CONFIG_TOUCHSCREEN_GT9XX_MIDO) += gt9xx.o
-obj-$(CONFIG_TOUCHSCREEN_GT9XX_MIDO) += gt9xx_update.o
-obj-$(CONFIG_TOUCHSCREEN_GT9XX_MIDO) += goodix_tool.o
+obj-$(CONFIG_GT9XX_TOUCHPANEL_DRIVER) += gt9xx.o
+obj-$(CONFIG_GT9XX_TOUCHPANEL_UPDATE) += gt9xx_update.o
+obj-$(CONFIG_GT9XX_TOUCHPANEL_DEBUG) += goodix_tool.o