ARM64: dts: rockchip: add i2c2, i2c4 gpio func support for rk3366
authorDavid Wu <david.wu@rock-chips.com>
Mon, 7 Mar 2016 18:49:44 +0000 (02:49 +0800)
committerDavid Wu <david.wu@rock-chips.com>
Mon, 7 Mar 2016 20:13:56 +0000 (04:13 +0800)
Change-Id: I8a3c5dac5c23d90706c21ffb48f4ac15e4f1cffb
Signed-off-by: David Wu <david.wu@rock-chips.com>
arch/arm64/boot/dts/rockchip/rk3366-tb.dts
arch/arm64/boot/dts/rockchip/rk3366.dtsi

index 2221722e947a77769cc8075dfeeaf93957eade99..e11a951142f0e43e3eb2917cbbe3cb33e2febe6d 100644 (file)
                        rk_usb,dcpattach  = <0x498 29 1>;
                };
        };
+
+       i2c@2 {
+               compatible = "i2c-gpio";
+               gpios = <&gpio5 15 GPIO_ACTIVE_HIGH>, /* sda */
+                       <&gpio5 16 GPIO_ACTIVE_HIGH>; /* scl */
+               i2c-gpio,delay-us = <2>;        /* ~100 kHz */
+               #address-cells = <1>;
+               #size-cells = <0>;
+               pinctrl-names = "default";
+               pinctrl-0 = <&i2c2_gpio>;
+               status = "disabled";
+       };
+
+       i2c@4 {
+               compatible = "i2c-gpio";
+               gpios = <&gpio5 9 GPIO_ACTIVE_HIGH>, /* sda */
+                       <&gpio5 8 GPIO_ACTIVE_HIGH>; /* scl */
+               i2c-gpio,delay-us = <2>;        /* ~100 kHz */
+               #address-cells = <1>;
+               #size-cells = <0>;
+               pinctrl-names = "default";
+               pinctrl-0 = <&i2c4_gpio>;
+               status = "okay";
+
+               gt9xx: gt9xx@14 {
+                       compatible = "goodix,gt9xx";
+                       reg = <0x14>;
+                       touch-gpio = <&gpio5 11 IRQ_TYPE_LEVEL_LOW>;
+                       reset-gpio = <&gpio5 10 GPIO_ACTIVE_HIGH>;
+                       max-x = <1200>;
+                       max-y = <1900>;
+                       tp-size = <911>;
+                       tp-supply = <&vcc_tp>;
+                       status = "okay";
+               };
+       };
 };
 
 &emmc {
        };
 };
 
-&i2c4 {
-       status = "okay";
-
-       gt9xx: gt9xx@14 {
-               compatible = "goodix,gt9xx";
-               reg = <0x14>;
-               touch-gpio = <&gpio5 11 IRQ_TYPE_LEVEL_LOW>;
-               reset-gpio = <&gpio5 10 GPIO_ACTIVE_HIGH>;
-               max-x = <1200>;
-               max-y = <1900>;
-               tp-size = <911>;
-               tp-supply = <&vcc_tp>;
-               status = "okay";
-       };
-};
-
 &i2s_8ch {
        status = "okay";
        rockchip,i2s-broken-burst-len;
index 4ceaa4d917c2171e13d755f579b7b0e055736792..a8cfeed37d804a7b9841ee5afcd270b518ff4012 100644 (file)
                                        <5 15 RK_FUNC_2 &pcfg_pull_none>,
                                        <5 16 RK_FUNC_2 &pcfg_pull_none>;
                        };
+
+                       i2c2_gpio: i2c2-gpio {
+                               rockchip,pins =
+                                       <5 15 RK_FUNC_GPIO &pcfg_pull_none>,
+                                       <5 16 RK_FUNC_GPIO &pcfg_pull_none>;
+                       };
                };
 
                i2c3 {
                                        <5 8 RK_FUNC_1 &pcfg_pull_none>,
                                        <5 9 RK_FUNC_1 &pcfg_pull_none>;
                        };
+
+                       i2c4_gpio: i2c4-gpio {
+                               rockchip,pins =
+                                       <5 8 RK_FUNC_GPIO &pcfg_pull_none>,
+                                       <5 9 RK_FUNC_GPIO &pcfg_pull_none>;
+                       };
                };
 
                i2c5 {