From b28c4af8e44b58e61791a82c2b71e0b13e9f5b6a Mon Sep 17 00:00:00 2001 From: Louis-Alexis Eyraud Date: Thu, 15 May 2025 12:04:11 +0200 Subject: [PATCH] arm64: dts: mt8365-evk: Add goodix touchscreen support The Mediatek Genio 350-EVK board has on the DSI0 connector a StarTek KD070FHFID015 display panel that uses a Goodix GT9271 I2C capacitive touch controller. The mt8365-evk devicetree already have the display panel support but lacks the touchscreen support, so add it. Signed-off-by: Louis-Alexis Eyraud Link: https://lore.kernel.org/r/20250515-mt8365-evk-enable-touchscreen-v1-1-7ba3c87b2a71@collabora.com [Angelo: Reordered regulator nodes and interurpts-extended property] Signed-off-by: AngeloGioacchino Del Regno --- arch/arm64/boot/dts/mediatek/mt8365-evk.dts | 40 +++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/arch/arm64/boot/dts/mediatek/mt8365-evk.dts b/arch/arm64/boot/dts/mediatek/mt8365-evk.dts index 1f8584bd66c3..c8418888268d 100644 --- a/arch/arm64/boot/dts/mediatek/mt8365-evk.dts +++ b/arch/arm64/boot/dts/mediatek/mt8365-evk.dts @@ -78,6 +78,21 @@ enable-active-high; }; + reg_vsys: regulator-vsys { + compatible = "regulator-fixed"; + regulator-name = "vsys"; + regulator-always-on; + regulator-boot-on; + }; + + touch0_fixed_3v3: regulator-vio33tp { + compatible = "regulator-fixed"; + regulator-name = "vio33_tp"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + vin-supply = <®_vsys>; + }; + reserved-memory { #address-cells = <2>; #size-cells = <2>; @@ -324,6 +339,18 @@ }; }; }; + + touchscreen@5d { + compatible = "goodix,gt9271"; + reg = <0x5d>; + interrupts-extended = <&pio 78 IRQ_TYPE_EDGE_FALLING>; + pinctrl-names = "default"; + pinctrl-0 = <&touch_pins>; + irq-gpios = <&pio 78 GPIO_ACTIVE_HIGH>; + reset-gpios = <&pio 79 GPIO_ACTIVE_LOW>; + AVDD28-supply = <&touch0_fixed_3v3>; + VDDIO-supply = <&mt6357_vrf12_reg>; + }; }; &mmc0 { @@ -650,6 +677,19 @@ }; }; + touch_pins: touch-pins { + ctp-int1-pins { + pinmux = ; + input-enable; + bias-disable; + }; + + rst-pins { + pinmux = ; + output-low; + }; + }; + uart0_pins: uart0-pins { pins { pinmux = , -- 2.50.1