diff mbox

[1/2] arm64: dts: marvell: fix USB3 regulator definition on MacchiatoBin

Message ID 20170623154014.20573-1-thomas.petazzoni@free-electrons.com (mailing list archive)
State New, archived
Headers show

Commit Message

Thomas Petazzoni June 23, 2017, 3:40 p.m. UTC
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.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
---
 arch/arm64/boot/dts/marvell/armada-8040-mcbin.dts | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

Comments

Russell King (Oracle) June 23, 2017, 4:08 p.m. UTC | #1
On Fri, Jun 23, 2017 at 05:40:13PM +0200, Thomas Petazzoni wrote:
> 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.
> 
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
> ---
>  arch/arm64/boot/dts/marvell/armada-8040-mcbin.dts | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)

If you weren't soo keen with your NIH patches, then you wouldn't be
making a mistake here...

Now, from what you've said on IRC, I know that you're more than happy
to fetch my git tree and test it on your board, and I've already stated
in a previous thread that I'm happy for people to take the DTS patches
I have in that branch, but still you persist in creating your own (and
in this case broken) patches.

While it _may_ work for you, it is not correct to the binding doc.

Now, you could have taken these three patches from my tree (which I
know you have from what you said on IRC):

  arm64: dts: marvell: mcbin: add GPIO
  arm64: dts: marvell: mcbin: add pinctrl nodes
  arm64: dts: marvell: mcbin: add gpio binding include file

which apply cleanly on top of arm-soc, and tested them with your gpio
and pinmux work.  In fact, these three patches are solving the exact
problem you have here.
diff mbox

Patch

diff --git a/arch/arm64/boot/dts/marvell/armada-8040-mcbin.dts b/arch/arm64/boot/dts/marvell/armada-8040-mcbin.dts
index 015b58b..dfced8c 100644
--- a/arch/arm64/boot/dts/marvell/armada-8040-mcbin.dts
+++ b/arch/arm64/boot/dts/marvell/armada-8040-mcbin.dts
@@ -46,6 +46,8 @@ 
 
 #include "armada-8040.dtsi"
 
+#include <dt-bindings/gpio/gpio.h>
+
 / {
 	model = "Marvell 8040 MACHIATOBin";
 	compatible = "marvell,armada8040-mcbin", "marvell,armada8040",
@@ -80,8 +82,9 @@ 
 		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 */
+		gpio = <&cpm_gpio2 15 GPIO_ACTIVE_HIGH>;
 		regulator-always-on;
+		enable-active-high;
 		status = "okay";
 	};