ARM: dts: ux500: samsung-golden: Add touch screen
authorStephan Gerhold <stephan@gerhold.net>
Thu, 19 Dec 2019 20:20:49 +0000 (21:20 +0100)
committerLinus Walleij <linus.walleij@linaro.org>
Wed, 25 Dec 2019 23:11:35 +0000 (00:11 +0100)
samsung-golden has an Atmel mXT224S touch controller connected to I2C.
It is supported by the existing driver for atmel,maxtouch, so all we
need to do to make it work is to define the necessary device tree nodes.

The atmel_mxt_ts driver does not support controlling regulators yet,
so add regulator-always-on for now to turn on the necessary regulators.

Signed-off-by: Stephan Gerhold <stephan@gerhold.net>
Link: https://lore.kernel.org/r/20191219202052.19039-7-stephan@gerhold.net
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
arch/arm/boot/dts/ste-ux500-samsung-golden.dts

index 14a084e..e75a425 100644 (file)
                        };
                };
 
+               i2c@80110000 {
+                       status = "okay";
+
+                       pinctrl-names = "default", "sleep";
+                       pinctrl-0 = <&i2c3_c_2_default>;
+                       pinctrl-1 = <&i2c3_c_2_sleep>;
+
+                       touchscreen@4a {
+                               compatible = "atmel,maxtouch";
+                               reg = <0x4a>;
+
+                               /* GPIO218 (TSP_INT_1V8) */
+                               interrupt-parent = <&gpio6>;
+                               interrupts = <26 IRQ_TYPE_EDGE_FALLING>;
+
+                               pinctrl-names = "default";
+                               pinctrl-0 = <&tsp_default>;
+                       };
+               };
+
                prcmu@80157000 {
                        ab8505 {
                                ab8500_usb {
                                                regulator-name = "vreg_tsp_a3v3";
                                                regulator-min-microvolt = <3300000>;
                                                regulator-max-microvolt = <3300000>;
+                                               regulator-always-on; /* FIXME */
                                        };
 
                                        ab8500_ldo_aux3 {
                                                regulator-name = "vreg_tsp_1v8";
                                                regulator-min-microvolt = <1800000>;
                                                regulator-max-microvolt = <1800000>;
+                                               regulator-always-on; /* FIXME */
                                        };
 
                                        ab8500_ldo_aux6 {
                };
        };
 
+       tsp {
+               tsp_default: tsp_default {
+                       golden_cfg1 {
+                               pins = "GPIO218_AH11";  /* TSP_INT_1V8 */
+                               ste,config = <&gpio_in_nopull>;
+                       };
+               };
+       };
+
        vibrator {
                vibrator_default: vibrator_default {
                        golden_cfg1 {