arm: dts: ls1088a: add external MDIO nodes
[oweals/u-boot.git] / arch / arm / dts / sun8i-h3-orangepi-plus.dts
index 900ec4fc8c818a660435a048e699007eb9529068..97f497854e05d26819a692139f0a1e336c8de9a1 100644 (file)
  *     OTHER DEALINGS IN THE SOFTWARE.
  */
 
-/dts-v1/;
-#include "sun8i-h3.dtsi"
-#include "sunxi-common-regulators.dtsi"
-
-#include <dt-bindings/gpio/gpio.h>
-#include <dt-bindings/input/input.h>
-#include <dt-bindings/pinctrl/sun4i-a10.h>
+/* The Orange Pi Plus is an extended version of the Orange Pi 2 */
+#include "sun8i-h3-orangepi-2.dts"
 
 / {
-       model = "Xunlong Orange Pi Plus";
+       model = "Xunlong Orange Pi Plus / Plus 2";
        compatible = "xunlong,orangepi-plus", "allwinner,sun8i-h3";
 
        aliases {
-               serial0 = &uart0;
+               ethernet0 = &emac;
        };
 
-       chosen {
-               stdout-path = "serial0:115200n8";
+       reg_gmac_3v3: gmac-3v3 {
+               compatible = "regulator-fixed";
+               regulator-name = "gmac-3v3";
+               regulator-min-microvolt = <3300000>;
+               regulator-max-microvolt = <3300000>;
+               startup-delay-us = <100000>;
+               enable-active-high;
+               gpio = <&pio 3 6 GPIO_ACTIVE_HIGH>;
        };
 
        reg_usb3_vbus: usb3-vbus {
                compatible = "regulator-fixed";
-               pinctrl-names = "default";
-               pinctrl-0 = <&usb3_vbus_pin_a>;
                regulator-name = "usb3-vbus";
                regulator-min-microvolt = <5000000>;
                regulator-max-microvolt = <5000000>;
                enable-active-high;
                gpio = <&pio 6 11 GPIO_ACTIVE_HIGH>;
        };
-
-       leds {
-               compatible = "gpio-leds";
-               pinctrl-names = "default";
-               pinctrl-0 = <&leds_opc>;
-
-               status_led {
-                       label = "status:red:user";
-                       gpios = <&pio 0 15 GPIO_ACTIVE_HIGH>;
-               };
-       };
-
-       r_leds {
-               compatible = "gpio-leds";
-               pinctrl-names = "default";
-               pinctrl-0 = <&leds_r_opc>;
-
-               tx {
-                       label = "pwr:green:user";
-                       gpios = <&r_pio 0 10 GPIO_ACTIVE_HIGH>;
-                       default-state = "on";
-               };
-       };
-
-       r_gpio_keys {
-               compatible = "gpio-keys";
-               input-name = "sw4";
-
-               pinctrl-names = "default";
-               pinctrl-0 = <&sw_r_opc>;
-
-               sw4@0 {
-                       label = "sw4";
-                       linux,code = <BTN_0>;
-                       gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
-               };
-       };
 };
 
-&pio {
-       leds_opc: led_pins@0 {
-               allwinner,pins = "PA15";
-               allwinner,function = "gpio_out";
-               allwinner,drive = <SUN4I_PINCTRL_10_MA>;
-               allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
-       };
+&cpu0 {
+       cpu-supply = <&reg_vdd_cpux>;
 };
 
-&r_pio {
-       leds_r_opc: led_pins@0 {
-               allwinner,pins = "PL10";
-               allwinner,function = "gpio_out";
-               allwinner,drive = <SUN4I_PINCTRL_10_MA>;
-               allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
-       };
-
-       sw_r_opc: key_pins@0 {
-               allwinner,pins = "PL03";
-               allwinner,function = "gpio_in";
-               allwinner,drive = <SUN4I_PINCTRL_10_MA>;
-               allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
-       };
-};
-
-&ehci1 {
+&ehci3 {
        status = "okay";
 };
 
-&ehci3 {
+&emac {
+       pinctrl-names = "default";
+       pinctrl-0 = <&emac_rgmii_pins>;
+       phy-supply = <&reg_gmac_3v3>;
+       phy-handle = <&ext_rgmii_phy>;
+       phy-mode = "rgmii";
+
        status = "okay";
 };
 
-&pio {
-       usb3_vbus_pin_a: usb3_vbus_pin@0 {
-               allwinner,pins = "PG11";
-               allwinner,function = "gpio_out";
-               allwinner,drive = <SUN4I_PINCTRL_10_MA>;
-               allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
+&external_mdio {
+       ext_rgmii_phy: ethernet-phy@1 {
+               compatible = "ethernet-phy-ieee802.3-c22";
+               reg = <0>;
        };
 };
 
-&mmc0 {
+&mmc2 {
        pinctrl-names = "default";
-       pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin>;
+       pinctrl-0 = <&mmc2_8bit_pins>;
        vmmc-supply = <&reg_vcc3v3>;
-       bus-width = <4>;
-       cd-gpios = <&pio 5 6 GPIO_ACTIVE_HIGH>; /* PF6 */
-       cd-inverted;
+       bus-width = <8>;
+       non-removable;
+       cap-mmc-hw-reset;
        status = "okay";
 };
 
-&reg_usb1_vbus {
-       gpio = <&pio 6 13 GPIO_ACTIVE_HIGH>;
-       status = "okay";
+&mmc2_8bit_pins {
+       /* Increase drive strength for DDR modes */
+       drive-strength = <40>;
+       /* eMMC is missing pull-ups */
+       bias-pull-up;
 };
 
-&uart0 {
-       pinctrl-names = "default";
-       pinctrl-0 = <&uart0_pins_a>;
+&r_i2c {
        status = "okay";
-};
 
-&usb1_vbus_pin_a {
-       allwinner,pins = "PG13";
+       reg_vdd_cpux: regulator@65 {
+               compatible = "silergy,sy8106a";
+               reg = <0x65>;
+               regulator-name = "vdd-cpux";
+               silergy,fixed-microvolt = <1200000>;
+               regulator-min-microvolt = <1000000>;
+               regulator-max-microvolt = <1400000>;
+               regulator-ramp-delay = <200>;
+               regulator-boot-on;
+               regulator-always-on;
+       };
 };
 
 &usbphy {
-       usb1_vbus-supply = <&reg_usb1_vbus>;
        usb3_vbus-supply = <&reg_usb3_vbus>;
-       status = "okay";
 };