arm64: dts: marvell: fix USB3 regulator definition on MacchiatoBin
authorRussell King <rmk+kernel@armlinux.org.uk>
Wed, 12 Jul 2017 12:56:55 +0000 (14:56 +0200)
committerGregory CLEMENT <gregory.clement@free-electrons.com>
Wed, 2 Aug 2017 14:07:38 +0000 (16:07 +0200)
Due to the lack of GPIO support, the USB3 regulator definition was
left unfinished in the MacchiatoBin DT description. Now that GPIO
support is available, this commit adjusts the Device Tree to properly
describe the USB3 regulator.

[gregory.clement@free-electrons.com: use commit log from Thomas]

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
arch/arm64/boot/dts/marvell/armada-8040-mcbin.dts

index fe91433d6fcd3221455f2115400f485dd1c81c93..da13ab2103aab4b47f24e0575f71bbfb714eb98a 100644 (file)
@@ -46,6 +46,8 @@
 
 #include "armada-8040.dtsi"
 
+#include <dt-bindings/gpio/gpio.h>
+
 / {
        model = "Marvell 8040 MACHIATOBin";
        compatible = "marvell,armada8040-mcbin", "marvell,armada8040",
 
        v_5v0_usb3_hst_vbus: regulator-usb3-vbus0 {
                compatible = "regulator-fixed";
+               enable-active-high;
+               gpio = <&cpm_gpio2 15 GPIO_ACTIVE_HIGH>;
+               pinctrl-names = "default";
+               pinctrl-0 = <&cpm_xhci_vbus_pins>;
                regulator-name = "v_5v0_usb3_hst_vbus";
                regulator-min-microvolt = <5000000>;
                regulator-max-microvolt = <5000000>;
-               /* actually GPIO controlled, but 8k has no GPIO support yet */
-               regulator-always-on;
                status = "okay";
        };
 
                marvell,pins = "mpp37", "mpp38";
                marvell,function = "i2c0";
        };
+       cpm_xhci_vbus_pins: xhci0-vbus-pins {
+               marvell,pins = "mpp47";
+               marvell,function = "gpio";
+       };
        cpm_sdhci_pins: sdhci-pins {
                marvell,pins = "mpp55", "mpp56", "mpp57", "mpp58", "mpp59",
                               "mpp60", "mpp61";