Enable focaltech touchscreen on DSI panel
-Bring in required DT properties and change interrupt to correct pin
-Rework R45/R46 on adapter board to connect to I2C2 bus instead of I2C1
-Tested: evtest
Change-Id: I66ec9ca7611b700dc1e1af01b66a1a9bdd752e3c
diff --git a/arch/arm64/boot/dts/mediatek/mt8167-coral-display-overlay.dts b/arch/arm64/boot/dts/mediatek/mt8167-coral-display-overlay.dts
index 82e7824..0cf4424 100644
--- a/arch/arm64/boot/dts/mediatek/mt8167-coral-display-overlay.dts
+++ b/arch/arm64/boot/dts/mediatek/mt8167-coral-display-overlay.dts
@@ -5,6 +5,8 @@
#include "mt8167-pinfunc.h"
#include <dt-bindings/input/input.h>
#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/interrupt-controller/arm-gic.h>
+#include <dt-bindings/interrupt-controller/irq.h>
/ {
compatible = "mediatek,mt8167";
@@ -22,6 +24,8 @@
ts_pin_nint: ts_pin_nint {
pins1 {
pinmux = <MT8167_PIN_16_EINT16__FUNC_GPIO16>;
+ input-enable;
+ bias-pull-up;
};
};
@@ -52,11 +56,15 @@
compatible = "focaltech,fts";
reg = <0x38>;
pinctrl-0 = <&ts_pin_nint>;
+ interrupt-parent = <&pio>;
+ interrupts = <16 IRQ_TYPE_EDGE_FALLING>;
focaltech,panel-type = <FT6236>;
focaltech,reset-gpio = <&pio 21 GPIO_ACTIVE_HIGH>;
focaltech,irq-gpio = <&pio 16 GPIO_ACTIVE_HIGH>;
focaltech,max-touch-number = <5>;
focaltech,display-coords = <0 0 320 480>;
+ touchscreen-size-x = <320>;
+ touchscreen-size-y = <480>;
};
};
};
diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig
index 2a80675..ab71467 100644
--- a/drivers/input/touchscreen/Kconfig
+++ b/drivers/input/touchscreen/Kconfig
@@ -1299,4 +1299,6 @@
To compile this driver as a module, choose M here: the
module will be called bu21023_ts.
+source "drivers/input/touchscreen/focaltech_touch/Kconfig"
+
endif
diff --git a/drivers/input/touchscreen/Makefile b/drivers/input/touchscreen/Makefile
index 5911a41..d469155 100644
--- a/drivers/input/touchscreen/Makefile
+++ b/drivers/input/touchscreen/Makefile
@@ -109,3 +109,4 @@
obj-$(CONFIG_TOUCHSCREEN_ZFORCE) += zforce_ts.o
obj-$(CONFIG_TOUCHSCREEN_COLIBRI_VF50) += colibri-vf50-ts.o
obj-$(CONFIG_TOUCHSCREEN_ROHM_BU21023) += rohm_bu21023.o
+obj-$(CONFIG_TOUCHSCREEN_FTS) += focaltech_touch/