From 2ec7d42918f0170331cb4206d36d10837c815549 Mon Sep 17 00:00:00 2001 From: Chris Morgan Date: Thu, 1 Feb 2024 09:06:20 -0600 Subject: [PATCH] arm64: dts: rockchip: Add Touch to Anbernic RG-ARC D Add the Goodix GT927 touchscreen to the Anbernic RG-ARC D. Signed-off-by: Chris Morgan Tested-by: Trooper_Max Link: https://lore.kernel.org/r/20240201150620.886786-1-macroalpha82@gmail.com [renamed node to generic touchscreen@14] Signed-off-by: Heiko Stuebner --- .../dts/rockchip/rk3566-anbernic-rg-arc-d.dts | 26 ++++++++++++++++--- 1 file changed, 22 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts b/arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts index 795fbedc3c1b5..ab83e8a616159 100644 --- a/arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts +++ b/arch/arm64/boot/dts/rockchip/rk3566-anbernic-rg-arc-d.dts @@ -19,14 +19,32 @@ }; }; -/* - * Unknown Goodix touchscreen at i2c2 0x14. Needs testing before it's - * enabled. - */ &i2c2 { pinctrl-0 = <&i2c2m1_xfer>; pinctrl-names = "default"; status = "okay"; + + touchscreen@14 { + compatible = "goodix,gt927"; + reg = <0x14>; + interrupt-parent = <&gpio4>; + interrupts = ; + irq-gpios = <&gpio4 RK_PB1 GPIO_ACTIVE_HIGH>; + pinctrl-0 = <&touch_int>; + pinctrl-names = "default"; + reset-gpios = <&gpio4 RK_PA6 GPIO_ACTIVE_HIGH>; + touchscreen-inverted-y; + touchscreen-size-x = <640>; + touchscreen-size-y = <480>; + }; +}; + +&pinctrl { + touchscreen { + touch_int: touch_int { + rockchip,pins = <4 RK_PB1 RK_FUNC_GPIO &pcfg_pull_up>; + }; + }; }; &sdhci { -- 2.30.2