]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
ARM: dts: sun4i: Sync from Linux v5.18-rc1
authorSamuel Holland <samuel@sholland.org>
Thu, 26 May 2022 03:26:02 +0000 (22:26 -0500)
committerAndre Przywara <andre.przywara@arm.com>
Sun, 26 Jun 2022 10:22:53 +0000 (11:22 +0100)
Copy the devicetree source for the A10 SoC and all existing boards
verbatim from the Linux v5.18-rc1 tag.

The previous version of this change was only partially applied.

Fixes: 4746694cba74 ("ARM: dts: sun4i: Sync from Linux v5.18-rc1")
Signed-off-by: Samuel Holland <samuel@sholland.org>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
19 files changed:
arch/arm/dts/Makefile
arch/arm/dts/axp209.dtsi
arch/arm/dts/sun4i-a10-a1000.dts
arch/arm/dts/sun4i-a10-ba10-tvbox.dts
arch/arm/dts/sun4i-a10-chuwi-v7-cw0825.dts
arch/arm/dts/sun4i-a10-cubieboard.dts
arch/arm/dts/sun4i-a10-dserve-dsrv9703c.dts
arch/arm/dts/sun4i-a10-hackberry.dts
arch/arm/dts/sun4i-a10-hyundai-a7hd.dts
arch/arm/dts/sun4i-a10-inet1.dts
arch/arm/dts/sun4i-a10-inet9f-rev03.dts
arch/arm/dts/sun4i-a10-itead-iteaduino-plus.dts
arch/arm/dts/sun4i-a10-jesurun-q5.dts
arch/arm/dts/sun4i-a10-marsboard.dts
arch/arm/dts/sun4i-a10-olinuxino-lime.dts
arch/arm/dts/sun4i-a10-pcduino.dts
arch/arm/dts/sun4i-a10-pov-protab2-ips9.dts
arch/arm/dts/sun4i-a10-topwise-a721.dts [new file with mode: 0644]
arch/arm/dts/sun4i-a10.dtsi

index 8a314210da6c7f18cc4830a0c57d6cdb7ee88c6e..5caedf7bd3e3cd7489dace14f9b35f6e1b8d2a25 100644 (file)
@@ -539,7 +539,8 @@ dtb-$(CONFIG_MACH_SUN4I) += \
        sun4i-a10-olinuxino-lime.dtb \
        sun4i-a10-pcduino.dtb \
        sun4i-a10-pcduino2.dtb \
-       sun4i-a10-pov-protab2-ips9.dtb
+       sun4i-a10-pov-protab2-ips9.dtb \
+       sun4i-a10-topwise-a721.dtb
 dtb-$(CONFIG_MACH_SUN5I) += \
        sun5i-a10s-auxtek-t003.dtb \
        sun5i-a10s-auxtek-t004.dtb \
index 0d9ff12bdf28c2df0083a0e7099521ad84313602..ca240cd6f6c3583317eb94c05368cbae8c25ffca 100644 (file)
@@ -53,7 +53,7 @@
        interrupt-controller;
        #interrupt-cells = <1>;
 
-       ac_power_supply: ac-power-supply {
+       ac_power_supply: ac-power {
                compatible = "x-powers,axp202-ac-power-supply";
                status = "disabled";
        };
@@ -69,7 +69,7 @@
                #gpio-cells = <2>;
        };
 
-       battery_power_supply: battery-power-supply {
+       battery_power_supply: battery-power {
                compatible = "x-powers,axp209-battery-power-supply";
                status = "disabled";
        };
                };
        };
 
-       usb_power_supply: usb-power-supply {
+       usb_power_supply: usb-power {
                compatible = "x-powers,axp202-usb-power-supply";
                status = "disabled";
        };
index 6c254ec4c85b71faaff83da262ab59d4d3794211..20f9ed244851f07ffca2c4361dff1600ddb00f6f 100644 (file)
                stdout-path = "serial0:115200n8";
        };
 
+       hdmi-connector {
+               compatible = "hdmi-connector";
+               type = "a";
+
+               port {
+                       hdmi_con_in: endpoint {
+                               remote-endpoint = <&hdmi_out_con>;
+                       };
+               };
+       };
+
        leds {
                compatible = "gpio-leds";
 
-               red {
+               led-0 {
                        label = "a1000:red:usr";
                        gpios = <&pio 7 10 GPIO_ACTIVE_HIGH>;
                };
 
-               blue {
+               led-1 {
                        label = "a1000:blue:pwr";
                        gpios = <&pio 7 20 GPIO_ACTIVE_HIGH>;
                        default-state = "on";
 };
 
 &emac {
-       phy = <&phy1>;
+       phy-handle = <&phy1>;
        status = "okay";
 };
 
        status = "okay";
 };
 
+&de {
+       status = "okay";
+};
+
+&hdmi {
+       status = "okay";
+};
+
+&hdmi_out {
+       hdmi_out_con: endpoint {
+               remote-endpoint = <&hdmi_con_in>;
+       };
+};
+
 &i2c0 {
        status = "okay";
 
index 38a2c413495248024fc8f4e96348dd1e64260d14..816d534ac093985bcb8faf4544115dd0f7015871 100644 (file)
@@ -68,7 +68,7 @@
 };
 
 &emac {
-       phy = <&phy1>;
+       phy-handle = <&phy1>;
        status = "okay";
 };
 
index cf7b392dff31477324e816f27e85365a98484c1c..74262988881c6aa0fff5a0564e86d9da231c3d99 100644 (file)
        status = "okay";
 };
 
-&pio {
-       usb0_id_detect_pin: usb0-id-detect-pin {
-               pins = "PH4";
-               function = "gpio_in";
-               bias-pull-up;
-       };
-
-       usb0_vbus_detect_pin: usb0-vbus-detect-pin {
-               pins = "PH5";
-               function = "gpio_in";
-               bias-pull-down;
-       };
-};
-
 &reg_usb0_vbus {
        status = "okay";
 };
 };
 
 &usbphy {
-       pinctrl-names = "default";
-       pinctrl-0 = <&usb0_id_detect_pin>, <&usb0_vbus_detect_pin>;
-       usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
-       usb0_vbus_det-gpio = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
+       usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
+       usb0_vbus_det-gpios = <&pio 7 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>; /* PH5 */
        usb0_vbus-supply = <&reg_usb0_vbus>;
        usb2_vbus-supply = <&reg_usb2_vbus>;
        status = "okay";
index 197a1f2b75ff722bb7aa460eeaf5bf6f0c6d9d85..0645d606423557b39cf31b9a2a3a6d8befb3c096 100644 (file)
                pinctrl-names = "default";
                pinctrl-0 = <&led_pins_cubieboard>;
 
-               blue {
+               led-0 {
                        label = "cubieboard:blue:usr";
                        gpios = <&pio 7 21 GPIO_ACTIVE_HIGH>; /* LED1 */
                };
 
-               green {
+               led-1 {
                        label = "cubieboard:green:usr";
                        gpios = <&pio 7 20 GPIO_ACTIVE_HIGH>; /* LED2 */
                        linux,default-trigger = "heartbeat";
 };
 
 &emac {
-       phy = <&phy1>;
+       phy-handle = <&phy1>;
        status = "okay";
 };
 
                function = "gpio_out";
                drive-strength = <20>;
        };
-
-       usb0_id_detect_pin: usb0-id-detect-pin {
-               pins = "PH4";
-               function = "gpio_in";
-               bias-pull-up;
-       };
 };
 
 &reg_ahci_5v {
 };
 
 &usbphy {
-       pinctrl-names = "default";
-       pinctrl-0 = <&usb0_id_detect_pin>;
-       usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
+       usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
        usb1_vbus-supply = <&reg_usb1_vbus>;
        usb2_vbus-supply = <&reg_usb2_vbus>;
        status = "okay";
index 896e27a08727827aad3b73f12ccc0c18993f7404..63e77c05bfdaaab1d42d40f342f926d51d81b144 100644 (file)
@@ -62,6 +62,7 @@
                brightness-levels = <0 10 20 30 40 50 60 70 80 90 100>;
                default-brightness-level = <8>;
                enable-gpios = <&pio 7 7 GPIO_ACTIVE_HIGH>; /* PH7 */
+               power-supply = <&reg_vcc3v3>;
        };
 
        chosen {
        status = "okay";
 };
 
-&pio {
-       usb0_id_detect_pin: usb0-id-detect-pin {
-               pins = "PH4";
-               function = "gpio_in";
-               bias-pull-up;
-       };
-
-       usb0_vbus_detect_pin: usb0-vbus-detect-pin {
-               pins = "PH5";
-               function = "gpio_in";
-               bias-pull-down;
-       };
-};
-
 &pwm {
        pinctrl-names = "default";
        pinctrl-0 = <&pwm0_pin>;
 };
 
 &usbphy {
-       pinctrl-names = "default";
-       pinctrl-0 = <&usb0_id_detect_pin>, <&usb0_vbus_detect_pin>;
-       usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
-       usb0_vbus_det-gpio = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
+       usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
+       usb0_vbus_det-gpios = <&pio 7 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>; /* PH5 */
        usb0_vbus-supply = <&reg_usb0_vbus>;
        usb2_vbus-supply = <&reg_usb2_vbus>;
        status = "okay";
index cc988ccd5ca753157887f70a141b55679bbb24f8..47dea0922501baef6e169305c038c04d3c382122 100644 (file)
@@ -80,7 +80,7 @@
 };
 
 &emac {
-       phy = <&phy0>;
+       phy-handle = <&phy0>;
        status = "okay";
 };
 
index f63767cddd8e4447117c4d6b2d151736bafd1a72..bf2044bac42fb9870c0603a89de88ee08e795677 100644 (file)
        status = "okay";
 };
 
-&pio {
-       usb0_id_detect_pin: usb0-id-detect-pin {
-               pins = "PH4";
-               function = "gpio_in";
-               bias-pull-up;
-       };
-
-       usb0_vbus_detect_pin: usb0-vbus-detect-pin {
-               pins = "PH5";
-               function = "gpio_in";
-               bias-pull-down;
-       };
-};
-
 &reg_usb0_vbus {
        status = "okay";
 };
 };
 
 &usbphy {
-       pinctrl-names = "default";
-       pinctrl-0 = <&usb0_id_detect_pin>, <&usb0_vbus_detect_pin>;
-       usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
-       usb0_vbus_det-gpio = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
+       usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
+       usb0_vbus_det-gpios = <&pio 7 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>; /* PH5 */
        usb0_vbus-supply = <&reg_usb0_vbus>;
        usb2_vbus-supply = <&reg_usb2_vbus>;
        status = "okay";
index 26d0c1d6a02b4454ff34b214562732a86e59b8d7..60e432a0ef1c596a9ebf1f55c7dc802656082f6e 100644 (file)
@@ -62,6 +62,7 @@
                brightness-levels = <0 10 20 30 40 50 60 70 80 90 100>;
                default-brightness-level = <8>;
                enable-gpios = <&pio 7 7 GPIO_ACTIVE_HIGH>; /* PH7 */
+               power-supply = <&reg_vcc3v3>;
        };
 
        chosen {
        status = "okay";
 };
 
-&pio {
-       usb0_id_detect_pin: usb0-id-detect-pin {
-               pins = "PH4";
-               function = "gpio_in";
-               bias-pull-up;
-       };
-
-       usb0_vbus_detect_pin: usb0-vbus-detect-pin {
-               pins = "PH5";
-               function = "gpio_in";
-               bias-pull-down;
-       };
-};
-
 &pwm {
        pinctrl-names = "default";
        pinctrl-0 = <&pwm0_pin>;
 };
 
 &usbphy {
-       pinctrl-names = "default";
-       pinctrl-0 = <&usb0_id_detect_pin>, <&usb0_vbus_detect_pin>;
-       usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
-       usb0_vbus_det-gpio = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
+       usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
+       usb0_vbus_det-gpios = <&pio 7 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>; /* PH5 */
        usb0_vbus-supply = <&reg_usb0_vbus>;
        usb1_vbus-supply = <&reg_usb1_vbus>;
        usb2_vbus-supply = <&reg_usb2_vbus>;
index 221acd10f6c8418ccacbdd996e9aa579de4ccf7f..0a562b2cc5bc6771c65ed77c2c72d2f76c87bd55 100644 (file)
 
        gpio-keys {
                compatible = "gpio-keys-polled";
-               pinctrl-names = "default";
-               pinctrl-0 = <&key_pins_inet9f>;
-               #address-cells = <1>;
-               #size-cells = <0>;
                poll-interval = <20>;
 
                left-joystick-left {
@@ -72,7 +68,7 @@
                        linux,code = <ABS_X>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <0xffffffff>; /* -1 */
-                       gpios = <&pio 0 6 GPIO_ACTIVE_LOW>; /* PA6 */
+                       gpios = <&pio 0 6 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA6 */
                };
 
                left-joystick-right {
@@ -80,7 +76,7 @@
                        linux,code = <ABS_X>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <1>;
-                       gpios = <&pio 0 5 GPIO_ACTIVE_LOW>; /* PA5 */
+                       gpios = <&pio 0 5 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA5 */
                };
 
                left-joystick-up {
@@ -88,7 +84,7 @@
                        linux,code = <ABS_Y>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <0xffffffff>; /* -1 */
-                       gpios = <&pio 0 8 GPIO_ACTIVE_LOW>; /* PA8 */
+                       gpios = <&pio 0 8 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA8 */
                };
 
                left-joystick-down {
@@ -96,7 +92,7 @@
                        linux,code = <ABS_Y>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <1>;
-                       gpios = <&pio 0 9 GPIO_ACTIVE_LOW>; /* PA9 */
+                       gpios = <&pio 0 9 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA9 */
                };
 
                right-joystick-left {
                        linux,code = <ABS_Z>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <0xffffffff>; /* -1 */
-                       gpios = <&pio 0 1 GPIO_ACTIVE_LOW>; /* PA1 */
+                       gpios = <&pio 0 1 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA1 */
                };
 
                right-joystick-right {
                        linux,code = <ABS_Z>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <1>;
-                       gpios = <&pio 0 0 GPIO_ACTIVE_LOW>; /* PA0 */
+                       gpios = <&pio 0 0 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA0 */
                };
 
                right-joystick-up {
                        linux,code = <ABS_RZ>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <0xffffffff>; /* -1 */
-                       gpios = <&pio 0 3 GPIO_ACTIVE_LOW>; /* PA3 */
+                       gpios = <&pio 0 3 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA3 */
                };
 
                right-joystick-down {
                        linux,code = <ABS_RZ>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <1>;
-                       gpios = <&pio 0 4 GPIO_ACTIVE_LOW>; /* PA4 */
+                       gpios = <&pio 0 4 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA4 */
                };
 
                dpad-left {
                        linux,code = <ABS_HAT0X>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <0xffffffff>; /* -1 */
-                       gpios = <&pio 7 23 GPIO_ACTIVE_LOW>; /* PH23 */
+                       gpios = <&pio 7 23 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PH23 */
                };
 
                dpad-right {
                        linux,code = <ABS_HAT0X>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <1>;
-                       gpios = <&pio 7 24 GPIO_ACTIVE_LOW>; /* PH24 */
+                       gpios = <&pio 7 24 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PH24 */
                };
 
                dpad-up {
                        linux,code = <ABS_HAT0Y>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <0xffffffff>; /* -1 */
-                       gpios = <&pio 7 25 GPIO_ACTIVE_LOW>; /* PH25 */
+                       gpios = <&pio 7 25 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PH25 */
                };
 
                dpad-down {
                        linux,code = <ABS_HAT0Y>;
                        linux,input-type = <EV_ABS>;
                        linux,input-value = <1>;
-                       gpios = <&pio 7 26 GPIO_ACTIVE_LOW>; /* PH26 */
+                       gpios = <&pio 7 26 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PH26 */
                };
 
                x {
                        label = "Button X";
                        linux,code = <BTN_X>;
-                       gpios = <&pio 0 16 GPIO_ACTIVE_LOW>; /* PA16 */
+                       gpios = <&pio 0 16 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA16 */
                };
 
                y {
                        label = "Button Y";
                        linux,code = <BTN_Y>;
-                       gpios = <&pio 0 14 GPIO_ACTIVE_LOW>; /* PA14 */
+                       gpios = <&pio 0 14 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA14 */
                };
 
                a {
                        label = "Button A";
                        linux,code = <BTN_A>;
-                       gpios = <&pio 0 17 GPIO_ACTIVE_LOW>; /* PA17 */
+                       gpios = <&pio 0 17 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA17 */
                };
 
                b {
                        label = "Button B";
                        linux,code = <BTN_B>;
-                       gpios = <&pio 0 15 GPIO_ACTIVE_LOW>; /* PA15 */
+                       gpios = <&pio 0 15 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA15 */
                };
 
                select {
                        label = "Select Button";
                        linux,code = <BTN_SELECT>;
-                       gpios = <&pio 0 11 GPIO_ACTIVE_LOW>; /* PA11 */
+                       gpios = <&pio 0 11 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA11 */
                };
 
                start {
                        label = "Start Button";
                        linux,code = <BTN_START>;
-                       gpios = <&pio 0 12 GPIO_ACTIVE_LOW>; /* PA12 */
+                       gpios = <&pio 0 12 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA12 */
                };
 
                top-left {
                        label = "Top Left Button";
                        linux,code = <BTN_TL>;
-                       gpios = <&pio 7 22 GPIO_ACTIVE_LOW>; /* PH22 */
+                       gpios = <&pio 7 22 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PH22 */
                };
 
                top-right {
                        label = "Top Right Button";
                        linux,code = <BTN_TR>;
-                       gpios = <&pio 0 13 GPIO_ACTIVE_LOW>; /* PA13 */
+                       gpios = <&pio 0 13 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>; /* PA13 */
                };
        };
 };
        status = "okay";
 };
 
-&pio {
-       key_pins_inet9f: key-pins {
-               pins = "PA0", "PA1", "PA3", "PA4",
-                      "PA5", "PA6", "PA8", "PA9",
-                      "PA11", "PA12", "PA13",
-                      "PA14", "PA15", "PA16", "PA17",
-                      "PH22", "PH23", "PH24", "PH25", "PH26";
-               function = "gpio_in";
-               bias-pull-up;
-       };
-
-       usb0_id_detect_pin: usb0-id-detect-pin {
-               pins = "PH4";
-               function = "gpio_in";
-               bias-pull-up;
-       };
-
-       usb0_vbus_detect_pin: usb0-vbus-detect-pin {
-               pins = "PH5";
-               function = "gpio_in";
-               bias-pull-down;
-       };
-};
-
 &reg_dcdc2 {
        regulator-always-on;
        regulator-min-microvolt = <1000000>;
 };
 
 &usbphy {
-       pinctrl-names = "default";
-       pinctrl-0 = <&usb0_id_detect_pin>, <&usb0_vbus_detect_pin>;
-       usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
-       usb0_vbus_det-gpio = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
+       usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
+       usb0_vbus_det-gpios = <&pio 7 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>; /* PH5 */
        usb0_vbus-supply = <&reg_usb0_vbus>;
        usb2_vbus-supply = <&reg_usb2_vbus>;
        status = "okay";
index 80ecd78247ac4466a1ad4135c85fa70275c3a98e..d4e319d16aae74ca793b2aa665228c5174d2f435 100644 (file)
@@ -58,7 +58,7 @@
 &emac {
        pinctrl-names = "default";
        pinctrl-0 = <&emac_pins>;
-       phy = <&phy1>;
+       phy-handle = <&phy1>;
        status = "okay";
 };
 
index 247fa27ef7178aa9390ca70c4df27524be91e60b..1aeb0bd5519e1640936521ab3db6783c9a3712e5 100644 (file)
@@ -63,7 +63,7 @@
        leds {
                compatible = "gpio-leds";
 
-               green {
+               led {
                        label = "q5:green:usr";
                        gpios = <&pio 7 20 GPIO_ACTIVE_HIGH>;  /* PH20 */
                };
@@ -94,7 +94,7 @@
 };
 
 &emac {
-       phy = <&phy1>;
+       phy-handle = <&phy1>;
        status = "okay";
 };
 
index 0dbf69576512ba8bbc7720ec838eaba8cb23ba3d..81fdb217d339b43c513c38eb9a669b603abedbcf 100644 (file)
        leds {
                compatible = "gpio-leds";
 
-               red1 {
+               led-0 {
                        label = "marsboard:red1:usr";
                        gpios = <&pio 1 5 GPIO_ACTIVE_HIGH>;
                };
 
-               red2 {
+               led-1 {
                        label = "marsboard:red2:usr";
                        gpios = <&pio 1 6 GPIO_ACTIVE_HIGH>;
                };
 
-               red3 {
+               led-2 {
                        label = "marsboard:red3:usr";
                        gpios = <&pio 1 7 GPIO_ACTIVE_HIGH>;
                };
 
-               red4 {
+               led-3 {
                        label = "marsboard:red4:usr";
                        gpios = <&pio 1 8 GPIO_ACTIVE_HIGH>;
                };
 };
 
 &emac {
-       phy = <&phy1>;
+       phy-handle = <&phy1>;
        status = "okay";
 };
 
        status = "okay";
 };
 
-&pio {
-       usb0_id_detect_pin: usb0-id-detect-pin {
-               pins = "PH4";
-               function = "gpio_in";
-               bias-pull-up;
-       };
-};
-
 &reg_usb1_vbus {
        status = "okay";
 };
 };
 
 &usbphy {
-       pinctrl-names = "default";
-       pinctrl-0 = <&usb0_id_detect_pin>;
-       usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
+       usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
        usb1_vbus-supply = <&reg_usb1_vbus>;
        usb2_vbus-supply = <&reg_usb2_vbus>;
        status = "okay";
index b74a614965377f49e074567137e490dc7e352087..83d283cf66334f11b8b6190b485538301b7df068 100644 (file)
@@ -74,7 +74,7 @@
                pinctrl-names = "default";
                pinctrl-0 = <&led_pins_olinuxinolime>;
 
-               green {
+               led {
                        label = "a10-olinuxino-lime:green:usr";
                        gpios = <&pio 7 2 GPIO_ACTIVE_HIGH>;
                        default-state = "on";
        /*
         * The A10-Lime is known to be unstable when running at 1008 MHz
         */
-       operating-points = <
-               /* kHz    uV */
-               912000  1350000
-               864000  1300000
-               624000  1250000
-               >;
+       operating-points =
+               /* kHz    uV */
+               <912000 1350000>,
+               <864000 1300000>,
+               <624000 1250000>;
 };
 
 &de {
 };
 
 &emac {
-       phy = <&phy1>;
+       phy-handle = <&phy1>;
        status = "okay";
 };
 
                function = "gpio_out";
                drive-strength = <20>;
        };
-
-       usb0_id_detect_pin: usb0-id-detect-pin {
-               pins = "PH4";
-               function = "gpio_in";
-               bias-pull-up;
-       };
-
-       usb0_vbus_detect_pin: usb0-vbus-detect-pin {
-               pins = "PH5";
-               function = "gpio_in";
-               bias-pull-down;
-       };
 };
 
 &reg_ahci_5v {
 };
 
 &usbphy {
-       pinctrl-names = "default";
-       pinctrl-0 = <&usb0_id_detect_pin>, <&usb0_vbus_detect_pin>;
-       usb0_id_det-gpio   = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
-       usb0_vbus_det-gpio = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
+       usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
+       usb0_vbus_det-gpios = <&pio 7 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH5 */
        usb0_vbus-supply   = <&reg_usb0_vbus>;
        usb1_vbus-supply = <&reg_usb1_vbus>;
        usb2_vbus-supply = <&reg_usb2_vbus>;
index b97a0f2f20b97634b239bf01f3878b5b7d7665a8..1ac82376baef159e3b10d58cf444c2df1f5a5314 100644 (file)
        leds {
                compatible = "gpio-leds";
 
-               tx {
+               led-0 {
                        label = "pcduino:green:tx";
                        gpios = <&pio 7 15 GPIO_ACTIVE_LOW>;
                };
 
-               rx {
+               led-1 {
                        label = "pcduino:green:rx";
                        gpios = <&pio 7 16 GPIO_ACTIVE_LOW>;
                };
@@ -76,8 +76,6 @@
 
        gpio-keys {
                compatible = "gpio-keys";
-               #address-cells = <1>;
-               #size-cells = <0>;
 
                back {
                        label = "Key Back";
 };
 
 &emac {
-       phy = <&phy1>;
+       phy-handle = <&phy1>;
        status = "okay";
 };
 
        status = "okay";
 };
 
-&pio {
-       usb0_id_detect_pin: usb0-id-detect-pin {
-               pins = "PH4";
-               function = "gpio_in";
-               bias-pull-up;
-       };
-};
-
 #include "axp209.dtsi"
 
 &reg_dcdc2 {
 };
 
 &usbphy {
-       pinctrl-names = "default";
-       pinctrl-0 = <&usb0_id_detect_pin>;
-       usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
+       usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
        usb1_vbus-supply = <&reg_vcc5v0>; /* USB1 VBUS is always on */
        usb2_vbus-supply = <&reg_vcc5v0>; /* USB2 VBUS is always on */
        status = "okay";
index 84b25be1ac94328ad7cd56f806c4476b8d35cbd9..c3259694764753d28b02bbfa449cb5a998c8b3f1 100644 (file)
@@ -62,6 +62,7 @@
                brightness-levels = <0 10 20 30 40 50 60 70 80 90 100>;
                default-brightness-level = <8>;
                enable-gpios = <&pio 7 7 GPIO_ACTIVE_HIGH>; /* PH7 */
+               power-supply = <&reg_vcc3v3>;
        };
 
        chosen {
        status = "okay";
 };
 
-&pio {
-       usb0_id_detect_pin: usb0-id-detect-pin {
-               pins = "PH4";
-               function = "gpio_in";
-               bias-pull-up;
-       };
-
-       usb0_vbus_detect_pin: usb0-vbus-detect-pin {
-               pins = "PH5";
-               function = "gpio_in";
-               bias-pull-down;
-       };
-};
-
 &pwm {
        pinctrl-names = "default";
        pinctrl-0 = <&pwm0_pin>;
 };
 
 &usbphy {
-       pinctrl-names = "default";
-       pinctrl-0 = <&usb0_id_detect_pin>, <&usb0_vbus_detect_pin>;
-       usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
-       usb0_vbus_det-gpio = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
+       usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
+       usb0_vbus_det-gpios = <&pio 7 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>; /* PH5 */
        usb0_vbus-supply = <&reg_usb0_vbus>;
        usb1_vbus-supply = <&reg_usb1_vbus>;
        status = "okay";
diff --git a/arch/arm/dts/sun4i-a10-topwise-a721.dts b/arch/arm/dts/sun4i-a10-topwise-a721.dts
new file mode 100644 (file)
index 0000000..3628f12
--- /dev/null
@@ -0,0 +1,242 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright 2020 Pascal Roeleven <dev@pascalroeleven.nl>
+ */
+
+/dts-v1/;
+#include "sun4i-a10.dtsi"
+#include "sunxi-common-regulators.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/interrupt-controller/irq.h>
+#include <dt-bindings/pwm/pwm.h>
+
+/ {
+       model = "Topwise A721";
+       compatible = "topwise,a721", "allwinner,sun4i-a10";
+
+       aliases {
+               serial0 = &uart0;
+       };
+
+       backlight: backlight {
+               compatible = "pwm-backlight";
+               pwms = <&pwm 0 100000 PWM_POLARITY_INVERTED>;
+               power-supply = <&reg_vbat>;
+               enable-gpios = <&pio 7 7 GPIO_ACTIVE_HIGH>; /* PH7 */
+               brightness-levels = <0 30 40 50 60 70 80 90 100>;
+               default-brightness-level = <8>;
+       };
+
+       chosen {
+               stdout-path = "serial0:115200n8";
+       };
+
+       panel {
+               compatible = "starry,kr070pe2t";
+               backlight = <&backlight>;
+               power-supply = <&reg_lcd_power>;
+
+               port {
+                       panel_input: endpoint {
+                               remote-endpoint = <&tcon0_out_panel>;
+                       };
+               };
+       };
+
+       reg_lcd_power: reg-lcd-power {
+               compatible = "regulator-fixed";
+               regulator-name = "reg-lcd-power";
+               gpio = <&pio 7 8 GPIO_ACTIVE_HIGH>; /* PH8 */
+               enable-active-high;
+       };
+
+       reg_vbat: reg-vbat {
+               compatible = "regulator-fixed";
+               regulator-name = "vbat";
+               regulator-min-microvolt = <3700000>;
+               regulator-max-microvolt = <3700000>;
+       };
+
+};
+
+&codec {
+       status = "okay";
+};
+
+&cpu0 {
+       cpu-supply = <&reg_dcdc2>;
+};
+
+&de {
+       status = "okay";
+};
+
+&ehci0 {
+       status = "okay";
+};
+
+&ehci1 {
+       status = "okay";
+};
+
+&i2c0 {
+       status = "okay";
+
+       axp209: pmic@34 {
+               reg = <0x34>;
+               interrupts = <0>;
+       };
+};
+
+#include "axp209.dtsi"
+
+&ac_power_supply {
+       status = "okay";
+};
+
+&battery_power_supply {
+       status = "okay";
+};
+
+&i2c1 {
+       status = "okay";
+
+       accelerometer@4c {
+               compatible = "fsl,mma7660";
+               reg = <0x4c>;
+       };
+};
+
+&i2c2 {
+       status = "okay";
+
+       touchscreen@38 {
+               compatible = "edt,edt-ft5406";
+               reg = <0x38>;
+               interrupt-parent = <&pio>;
+               interrupts = <7 21 IRQ_TYPE_EDGE_FALLING>;
+               touchscreen-size-x = <800>;
+               touchscreen-size-y = <480>;
+               vcc-supply = <&reg_vcc3v3>;
+       };
+};
+
+&lradc {
+       vref-supply = <&reg_ldo2>;
+       status = "okay";
+
+       button-571 {
+               label = "Volume Up";
+               linux,code = <KEY_VOLUMEUP>;
+               channel = <0>;
+               voltage = <571428>;
+       };
+
+       button-761 {
+               label = "Volume Down";
+               linux,code = <KEY_VOLUMEDOWN>;
+               channel = <0>;
+               voltage = <761904>;
+       };
+};
+
+&mmc0 {
+       vmmc-supply = <&reg_vcc3v3>;
+       bus-width = <4>;
+       cd-gpios = <&pio 7 1 GPIO_ACTIVE_LOW>; /* PH01 */
+       status = "okay";
+};
+
+&ohci0 {
+       status = "okay";
+};
+
+&ohci1 {
+       status = "okay";
+};
+
+&otg_sram {
+       status = "okay";
+};
+
+&pio {
+       vcc-pb-supply = <&reg_vcc3v3>;
+       vcc-pf-supply = <&reg_vcc3v3>;
+       vcc-ph-supply = <&reg_vcc3v3>;
+};
+
+&pwm {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pwm0_pin>;
+       status = "okay";
+};
+
+&reg_dcdc2 {
+       regulator-always-on;
+       regulator-min-microvolt = <1000000>;
+       regulator-max-microvolt = <1400000>;
+       regulator-name = "vdd-cpu";
+};
+
+&reg_dcdc3 {
+       regulator-always-on;
+       regulator-min-microvolt = <1250000>;
+       regulator-max-microvolt = <1250000>;
+       regulator-name = "vdd-int-dll";
+};
+
+&reg_ldo1 {
+       regulator-name = "vdd-rtc";
+};
+
+&reg_ldo2 {
+       regulator-always-on;
+       regulator-min-microvolt = <3000000>;
+       regulator-max-microvolt = <3000000>;
+       regulator-name = "avcc";
+};
+
+&reg_usb0_vbus {
+       status = "okay";
+};
+
+&reg_usb1_vbus {
+       status = "okay";
+};
+
+&reg_usb2_vbus {
+       status = "okay";
+};
+
+&tcon0_out {
+       tcon0_out_panel: endpoint@0 {
+               reg = <0>;
+               remote-endpoint = <&panel_input>;
+       };
+};
+
+&uart0 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&uart0_pb_pins>;
+       status = "okay";
+};
+
+&usb_otg {
+       dr_mode = "otg";
+       status = "okay";
+};
+
+&usb_power_supply {
+       status = "okay";
+};
+
+&usbphy {
+       usb0_id_det-gpios = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
+       usb0_vbus_det-gpios = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */
+       usb0_vbus-supply = <&reg_usb0_vbus>;
+       usb1_vbus-supply = <&reg_usb1_vbus>;
+       usb2_vbus-supply = <&reg_usb2_vbus>;
+       status = "okay";
+};
index 3a1c6b45c9a1cd3e6ef699d9c3b45fdb2712fcfd..51a6464aab9a3b55c557b1e9c84fb40023897c60 100644 (file)
                        reg = <0x0>;
                        clocks = <&ccu CLK_CPU>;
                        clock-latency = <244144>; /* 8 32k periods */
-                       operating-points = <
+                       operating-points =
                                /* kHz    uV */
-                               1008000 1400000
-                               912000  1350000
-                               864000  1300000
-                               624000  1250000
-                               >;
+                               <1008000 1400000>,
+                               <912000 1350000>,
+                               <864000 1300000>,
+                               <624000 1250000>;
                        #cooling-cells = <2>;
                };
        };
                        trips {
                                cpu_alert0: cpu-alert0 {
                                        /* milliCelsius */
-                                       temperature = <850000>;
+                                       temperature = <85000>;
                                        hysteresis = <2000>;
                                        type = "passive";
                                };
                status = "disabled";
        };
 
+       pmu {
+               compatible = "arm,cortex-a8-pmu";
+               interrupts = <3>;
+       };
+
+       reserved-memory {
+               #address-cells = <1>;
+               #size-cells = <1>;
+               ranges;
+
+               /* Address must be kept in the lower 256 MiBs of DRAM for VE. */
+               default-pool {
+                       compatible = "shared-dma-pool";
+                       size = <0x6000000>;
+                       alloc-ranges = <0x40000000 0x10000000>;
+                       reusable;
+                       linux,cma-default;
+               };
+       };
+
        soc {
                compatible = "simple-bus";
                #address-cells = <1>;
                #size-cells = <1>;
                ranges;
 
-               sram-controller@1c00000 {
-                       compatible = "allwinner,sun4i-a10-sram-controller";
+               system-control@1c00000 {
+                       compatible = "allwinner,sun4i-a10-system-control";
                        reg = <0x01c00000 0x30>;
                        #address-cells = <1>;
                        #size-cells = <1>;
                                        status = "disabled";
                                };
                        };
+
+                       sram_c: sram@1d00000 {
+                               compatible = "mmio-sram";
+                               reg = <0x01d00000 0xd0000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
+                               ranges = <0 0x01d00000 0xd0000>;
+
+                               ve_sram: sram-section@0 {
+                                       compatible = "allwinner,sun4i-a10-sram-c1";
+                                       reg = <0x000000 0x80000>;
+                               };
+                       };
                };
 
                dma: dma-controller@1c02000 {
                        #dma-cells = <2>;
                };
 
-               nfc: nand@1c03000 {
+               nfc: nand-controller@1c03000 {
                        compatible = "allwinner,sun4i-a10-nand";
                        reg = <0x01c03000 0x1000>;
                        interrupts = <37>;
                                      "tcon-ch0",
                                      "tcon-ch1";
                        clock-output-names = "tcon0-pixel-clock";
+                       #clock-cells = <0>;
                        dmas = <&dma SUN4I_DMA_DEDICATED 14>;
 
                        ports {
                                      "tcon-ch0",
                                      "tcon-ch1";
                        clock-output-names = "tcon1-pixel-clock";
+                       #clock-cells = <0>;
                        dmas = <&dma SUN4I_DMA_DEDICATED 15>;
 
                        ports {
                        };
                };
 
+               video-codec@1c0e000 {
+                       compatible = "allwinner,sun4i-a10-video-engine";
+                       reg = <0x01c0e000 0x1000>;
+                       clocks = <&ccu CLK_AHB_VE>, <&ccu CLK_VE>,
+                                <&ccu CLK_DRAM_VE>;
+                       clock-names = "ahb", "mod", "ram";
+                       resets = <&ccu RST_VE>;
+                       interrupts = <53>;
+                       allwinner,sram = <&ve_sram 1>;
+               };
+
                mmc0: mmc@1c0f000 {
                        compatible = "allwinner,sun4i-a10-mmc";
                        reg = <0x01c0f000 0x1000>;
                        phy-names = "usb";
                        extcon = <&usbphy 0>;
                        allwinner,sram = <&otg_sram 1>;
+                       dr_mode = "otg";
                        status = "disabled";
                };
 
                usbphy: phy@1c13400 {
                        #phy-cells = <1>;
                        compatible = "allwinner,sun4i-a10-usb-phy";
-                       reg = <0x01c13400 0x10 0x01c14800 0x4 0x01c1c800 0x4>;
+                       reg = <0x01c13400 0x10>, <0x01c14800 0x4>, <0x01c1c800 0x4>;
                        reg-names = "phy_ctrl", "pmu1", "pmu2";
                        clocks = <&ccu CLK_USB_PHY>;
                        clock-names = "usb_phy";
                                };
 
                                hdmi_out: port@1 {
-                                       #address-cells = <1>;
-                                       #size-cells = <0>;
                                        reg = <1>;
                                };
                        };
                        status = "disabled";
                };
 
+               csi1: csi@1c1d000 {
+                       compatible = "allwinner,sun4i-a10-csi1";
+                       reg = <0x01c1d000 0x1000>;
+                       interrupts = <43>;
+                       clocks = <&ccu CLK_AHB_CSI1>, <&ccu CLK_DRAM_CSI1>;
+                       clock-names = "bus", "ram";
+                       resets = <&ccu RST_CSI1>;
+                       status = "disabled";
+               };
+
                spi3: spi@1c1f000 {
                        compatible = "allwinner,sun4i-a10-spi";
                        reg = <0x01c1f000 0x1000>;
                                function = "can";
                        };
 
+                       /omit-if-no-ref/
+                       csi1_8bits_pg_pins: csi1-8bits-pg-pins {
+                               pins = "PG0", "PG2", "PG3", "PG4", "PG5",
+                                      "PG6", "PG7", "PG8", "PG9", "PG10",
+                                      "PG11";
+                               function = "csi1";
+                       };
+
+                       /omit-if-no-ref/
+                       csi1_24bits_ph_pins: csi1-24bits-ph-pins {
+                               pins = "PH0", "PH1", "PH2", "PH3", "PH4",
+                                      "PH5", "PH6", "PH7", "PH8", "PH9",
+                                      "PH10", "PH11", "PH12", "PH13", "PH14",
+                                      "PH15", "PH16", "PH17", "PH18", "PH19",
+                                      "PH20", "PH21", "PH22", "PH23", "PH24",
+                                      "PH25", "PH26", "PH27";
+                               function = "csi1";
+                       };
+
+                       /omit-if-no-ref/
+                       csi1_clk_pg_pin: csi1-clk-pg-pin {
+                               pins = "PG1";
+                               function = "csi1";
+                       };
+
                        emac_pins: emac0-pins {
                                pins = "PA0", "PA1", "PA2",
                                       "PA3", "PA4", "PA5", "PA6",
                timer@1c20c00 {
                        compatible = "allwinner,sun4i-a10-timer";
                        reg = <0x01c20c00 0x90>;
-                       interrupts = <22>;
+                       interrupts = <22>,
+                                    <23>,
+                                    <24>,
+                                    <25>,
+                                    <67>,
+                                    <68>;
                        clocks = <&osc24M>;
                };
 
                wdt: watchdog@1c20c90 {
                        compatible = "allwinner,sun4i-a10-wdt";
                        reg = <0x01c20c90 0x10>;
+                       interrupts = <24>;
+                       clocks = <&osc24M>;
                };
 
                rtc: rtc@1c20d00 {
                        status = "disabled";
                };
 
+               mali: gpu@1c40000 {
+                       compatible = "allwinner,sun4i-a10-mali", "arm,mali-400";
+                       reg = <0x01c40000 0x10000>;
+                       interrupts = <69>,
+                                    <70>,
+                                    <71>,
+                                    <72>,
+                                    <73>;
+                       interrupt-names = "gp",
+                                         "gpmmu",
+                                         "pp0",
+                                         "ppmmu0",
+                                         "pmu";
+                       clocks = <&ccu CLK_AHB_GPU>, <&ccu CLK_GPU>;
+                       clock-names = "bus", "core";
+                       resets = <&ccu RST_GPU>;
+
+                       assigned-clocks = <&ccu CLK_GPU>;
+                       assigned-clock-rates = <384000000>;
+               };
+
                fe0: display-frontend@1e00000 {
                        compatible = "allwinner,sun4i-a10-display-frontend";
                        reg = <0x01e00000 0x20000>;