Skip to contentSkip to conversation

arm64: dts: imx8mp-venice-gw74xx: fix CAN STBY polarity

PATCH Superseded Tim Harvey 3 participants 12 messages Aug 12, 2022 – Sep 12, 2022

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Tim Harvey

author
#0 lore raw

PATCH 1/6 arm64: dts: imx8mp-venice-gw74xx: fix CAN STBY polarity

The CAN STBY poarlity is active-low. Specify it as such.

Fixes 7899eb6cb15d ("arm64: dts: imx: Add i.MX8M Plus Gateworks gw7400 dts support")
---
 arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +2 -2
index 521215520a0f..de17021df53f 100644
@@ -123,8 +123,8 @@ reg_can2_stby: regulator-can2-stby {
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_reg_can>;
 		regulator-name = "can2_stby";
-		gpio = <&gpio3 19 GPIO_ACTIVE_HIGH>;
-		enable-active-high;
+		gpio = <&gpio3 19 GPIO_ACTIVE_LOW>;
+		enable-active-low;
 		regulator-min-microvolt = <3300000>;
 		regulator-max-microvolt = <3300000>;
 	};
Signature · 1 line
2.25.1
author
#1 lore raw

PATCH 2/6 arm64: dts: imx8mp-venice-gw74xx: remove invalid and unused pinctrl_sai2

pinctrl_sai2 is not yet used and not properly defined - remove it to avoid:
imx8mp-pinctrl 30330000.pinctrl: Invalid fsl,pins or pins propert y in node /soc@0/bus@30000000/pinctrl@30330000/sai2grp

Fixes 7899eb6cb15d ("arm64: dts: imx: Add i.MX8M Plus Gateworks gw7400 dts

support")

---
 arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts | 9 ---------
 1 file changed, 9 deletions(-)
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +0 -9
index de17021df53f..80f0f1aafdbf 100644
@@ -768,15 +768,6 @@ MX8MP_IOMUXC_NAND_DATA03__GPIO3_IO09	0x110
 		>;
 	};
 
-	pinctrl_sai2: sai2grp {
-		fsl,pins = <
-			MX8MP_IOMUXC_SAI2_TXFS__AUDIOMIX_SAI2_TX_SYNC
-			MX8MP_IOMUXC_SAI2_TXD0__AUDIOMIX_SAI2_TX_DATA00
-			MX8MP_IOMUXC_SAI2_TXC__AUDIOMIX_SAI2_TX_BCLK
-			MX8MP_IOMUXC_SAI2_MCLK__AUDIOMIX_SAI2_MCLK
-		>;
-	};
-
 	pinctrl_spi2: spi2grp {
 		fsl,pins = <
 			MX8MP_IOMUXC_ECSPI2_SCLK__ECSPI2_SCLK	0x82
Signature · 1 line
2.25.1
author
#2 lore raw

Re: [PATCH 2/6] arm64: dts: imx8mp-venice-gw74xx: remove invalid and unused pinctrl_sai2

Quoted 34 lines · Tim Harvey

pinctrl_sai2 is not yet used and not properly defined - remove it to avoid:
imx8mp-pinctrl 30330000.pinctrl: Invalid fsl,pins or pins propert y in node /soc@0/bus@30000000/pinctrl@30330000/sai2grp

Fixes 7899eb6cb15d ("arm64: dts: imx: Add i.MX8M Plus Gateworks gw7400 dts

support")

---
 arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts | 9 ---------
 1 file changed, 9 deletions(-)
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +0 -10
index de17021df53f..80f0f1aafdbf 100644
@@ -768,15 +768,6 @@ MX8MP_IOMUXC_NAND_DATA03__GPIO3_IO09       0x110
                >;
        };
 
-       pinctrl_sai2: sai2grp {
-               fsl,pins = <
-                       MX8MP_IOMUXC_SAI2_TXFS__AUDIOMIX_SAI2_TX_SYNC
-                       MX8MP_IOMUXC_SAI2_TXD0__AUDIOMIX_SAI2_TX_DATA00
-                       MX8MP_IOMUXC_SAI2_TXC__AUDIOMIX_SAI2_TX_BCLK
-                       MX8MP_IOMUXC_SAI2_MCLK__AUDIOMIX_SAI2_MCLK
-               >;
-       };
-
        pinctrl_spi2: spi2grp {
                fsl,pins = <
                        MX8MP_IOMUXC_ECSPI2_SCLK__ECSPI2_SCLK   0x82
--
Quoted 2 lines

2.25.1

Shawn,

You can drop this. I didn't see Peng's patch commit 706dd9d30d3b ("arm64: dts: imx8mp-venice-gw74xx: fix sai2 pin settings") which takes care of this.

Best Regards,

Tim

author
#3 lore raw

Re: [PATCH 2/6] arm64: dts: imx8mp-venice-gw74xx: remove invalid and unused pinctrl_sai2

Quoted 41 lines · Tim Harvey
Quoted 34 lines · Tim Harvey

pinctrl_sai2 is not yet used and not properly defined - remove it to avoid:
imx8mp-pinctrl 30330000.pinctrl: Invalid fsl,pins or pins propert y in node /soc@0/bus@30000000/pinctrl@30330000/sai2grp

Fixes 7899eb6cb15d ("arm64: dts: imx: Add i.MX8M Plus Gateworks gw7400 dts

support")

---
 arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts | 9 ---------
 1 file changed, 9 deletions(-)
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +0 -10
index de17021df53f..80f0f1aafdbf 100644
@@ -768,15 +768,6 @@ MX8MP_IOMUXC_NAND_DATA03__GPIO3_IO09       0x110
                >;
        };
 
-       pinctrl_sai2: sai2grp {
-               fsl,pins = <
-                       MX8MP_IOMUXC_SAI2_TXFS__AUDIOMIX_SAI2_TX_SYNC
-                       MX8MP_IOMUXC_SAI2_TXD0__AUDIOMIX_SAI2_TX_DATA00
-                       MX8MP_IOMUXC_SAI2_TXC__AUDIOMIX_SAI2_TX_BCLK
-                       MX8MP_IOMUXC_SAI2_MCLK__AUDIOMIX_SAI2_MCLK
-               >;
-       };
-
        pinctrl_spi2: spi2grp {
                fsl,pins = <
                        MX8MP_IOMUXC_ECSPI2_SCLK__ECSPI2_SCLK   0x82
--
Quoted 2 lines

2.25.1

Shawn,

Quoted 7 lines

You can drop this. I didn't see Peng's patch commit 706dd9d30d3b ("arm64: dts: imx8mp-venice-gw74xx: fix sai2 pin settings") which takes care of this.

Best Regards,

Tim

Shawn,

Did you need me to re-submit the series this patch was in without it? I haven't seen any responses to the rest of the patches in this series.

Best Regards,

Tim

#4 lore raw

Re: [PATCH 2/6] arm64: dts: imx8mp-venice-gw74xx: remove invalid and unused pinctrl_sai2

Quoted 48 lines · Tim Harvey
Quoted 47 lines · Tim Harvey
Quoted 34 lines · Tim Harvey

pinctrl_sai2 is not yet used and not properly defined - remove it to avoid:
imx8mp-pinctrl 30330000.pinctrl: Invalid fsl,pins or pins propert y in node /soc@0/bus@30000000/pinctrl@30330000/sai2grp

Fixes 7899eb6cb15d ("arm64: dts: imx: Add i.MX8M Plus Gateworks gw7400 dts

support")

---
 arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts | 9 ---------
 1 file changed, 9 deletions(-)
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +0 -10
index de17021df53f..80f0f1aafdbf 100644
@@ -768,15 +768,6 @@ MX8MP_IOMUXC_NAND_DATA03__GPIO3_IO09       0x110
                >;
        };
 
-       pinctrl_sai2: sai2grp {
-               fsl,pins = <
-                       MX8MP_IOMUXC_SAI2_TXFS__AUDIOMIX_SAI2_TX_SYNC
-                       MX8MP_IOMUXC_SAI2_TXD0__AUDIOMIX_SAI2_TX_DATA00
-                       MX8MP_IOMUXC_SAI2_TXC__AUDIOMIX_SAI2_TX_BCLK
-                       MX8MP_IOMUXC_SAI2_MCLK__AUDIOMIX_SAI2_MCLK
-               >;
-       };
-
        pinctrl_spi2: spi2grp {
                fsl,pins = <
                        MX8MP_IOMUXC_ECSPI2_SCLK__ECSPI2_SCLK   0x82
--
Quoted 2 lines

2.25.1

Shawn,

You can drop this. I didn't see Peng's patch commit 706dd9d30d3b ("arm64: dts: imx8mp-venice-gw74xx: fix sai2 pin settings") which takes care of this.

Best Regards,

Quoted 7 lines
Quoted 1 line

Tim

Shawn,

Did you need me to re-submit the series this patch was in without it? I haven't seen any responses to the rest of the patches in this series.

You said you will send a new version in responding to Fabio's comment on patch 1/6 [1], right?

Shawn

[1] https://lore.kernel.org/linux-arm-kernel/CAJ+vNU3E+5DWR5tQyUurLzGkinjX2fidbVNZ4T70CNmhM6eNTw@mail.gmail.com/

author
#5 lore raw

Re: [PATCH 2/6] arm64: dts: imx8mp-venice-gw74xx: remove invalid and unused pinctrl_sai2

Quoted 58 lines · Shawn Guo
Quoted 48 lines · Tim Harvey
Quoted 47 lines · Tim Harvey
Quoted 34 lines · Tim Harvey

pinctrl_sai2 is not yet used and not properly defined - remove it to avoid:
imx8mp-pinctrl 30330000.pinctrl: Invalid fsl,pins or pins propert y in node /soc@0/bus@30000000/pinctrl@30330000/sai2grp

Fixes 7899eb6cb15d ("arm64: dts: imx: Add i.MX8M Plus Gateworks gw7400 dts

support")

---
 arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts | 9 ---------
 1 file changed, 9 deletions(-)
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +0 -10
index de17021df53f..80f0f1aafdbf 100644
@@ -768,15 +768,6 @@ MX8MP_IOMUXC_NAND_DATA03__GPIO3_IO09       0x110
                >;
        };
 
-       pinctrl_sai2: sai2grp {
-               fsl,pins = <
-                       MX8MP_IOMUXC_SAI2_TXFS__AUDIOMIX_SAI2_TX_SYNC
-                       MX8MP_IOMUXC_SAI2_TXD0__AUDIOMIX_SAI2_TX_DATA00
-                       MX8MP_IOMUXC_SAI2_TXC__AUDIOMIX_SAI2_TX_BCLK
-                       MX8MP_IOMUXC_SAI2_MCLK__AUDIOMIX_SAI2_MCLK
-               >;
-       };
-
        pinctrl_spi2: spi2grp {
                fsl,pins = <
                        MX8MP_IOMUXC_ECSPI2_SCLK__ECSPI2_SCLK   0x82
--
Quoted 2 lines

2.25.1

Shawn,

You can drop this. I didn't see Peng's patch commit 706dd9d30d3b ("arm64: dts: imx8mp-venice-gw74xx: fix sai2 pin settings") which takes care of this.

Best Regards,

Quoted 7 lines
Quoted 1 line

Tim

Shawn,

Did you need me to re-submit the series this patch was in without it? I haven't seen any responses to the rest of the patches in this series.

Quoted 6 lines

You said you will send a new version in responding to Fabio's comment on patch 1/6 [1], right?

Shawn

[1] https://lore.kernel.org/linux-arm-kernel/CAJ+vNU3E+5DWR5tQyUurLzGkinjX2fidbVNZ4T70CNmhM6eNTw@mail.gmail.com/

Shawn,

Yes, I will re-submit that series.

Thanks,

Tim

author
#6 lore raw

PATCH 3/6 arm64: dts: imx8mp-venice-gw74xx: fix ksz9477 cpu port

In reply to Tim Harvey

The CPU uplink port on the KSZ9477 is P5 not P6 - fix this.

Fixes 7899eb6cb15d ("arm64: dts: imx: Add i.MX8M Plus Gateworks gw7400 dts support")
---
 arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +2 -2
index 80f0f1aafdbf..6ab4896f708b 100644
@@ -511,8 +511,8 @@ lan5: port@4 {
 				local-mac-address = [00 00 00 00 00 00];
 			};
 
-			port@6 {
-				reg = <6>;
+			port@5 {
+				reg = <5>;
 				label = "cpu";
 				ethernet = <&fec>;
 				phy-mode = "rgmii-id";
Signature · 1 line
2.25.1
author
#7 lore raw

PATCH 4/6 arm64: dts: imx8mp-venice-gw74xx: fix port/phy validation

In reply to Tim Harvey

Since commit 65ac79e18120 ("net: dsa: microchip: add the phylink get_caps") the phy-mode must be set otherwise the switch driver will assume "NA" mode and invalidate the port.

Fixes 7899eb6cb15d ("arm64: dts: imx: Add i.MX8M Plus Gateworks gw7400

dts support")

---
 arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts | 5 +++++
 1 file changed, 5 insertions(+)
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +5 -0
index 6ab4896f708b..cb4cf293a7b7 100644
@@ -484,30 +484,35 @@ ports {
 			lan1: port@0 {
 				reg = <0>;
 				label = "lan1";
+				phy-mode = "internal";
 				local-mac-address = [00 00 00 00 00 00];
 			};
 
 			lan2: port@1 {
 				reg = <1>;
 				label = "lan2";
+				phy-mode = "internal";
 				local-mac-address = [00 00 00 00 00 00];
 			};
 
 			lan3: port@2 {
 				reg = <2>;
 				label = "lan3";
+				phy-mode = "internal";
 				local-mac-address = [00 00 00 00 00 00];
 			};
 
 			lan4: port@3 {
 				reg = <3>;
 				label = "lan4";
+				phy-mode = "internal";
 				local-mac-address = [00 00 00 00 00 00];
 			};
 
 			lan5: port@4 {
 				reg = <4>;
 				label = "lan5";
+				phy-mode = "internal";
 				local-mac-address = [00 00 00 00 00 00];
 			};
 
Signature · 1 line
2.25.1
author
#8 lore raw

PATCH 5/6 arm64: dts: imx8mp-venice-gw74xx: add cpu-supply node for cpufreq

In reply to Tim Harvey

Add regulator config for cpu-supply in order to support cpufreq.

---
 .../dts/freescale/imx8mp-venice-gw74xx.dts     | 18 +++++++++++++++++-
 1 file changed, 17 insertions(+), 1 deletion(-)
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +17 -1
index cb4cf293a7b7..bfc480aaf54d 100644
@@ -142,6 +142,22 @@ reg_wifi_en: regulator-wifi-en {
 	};
 };
 
+&A53_0 {
+	cpu-supply = <&reg_arm>;
+};
+
+&A53_1 {
+	cpu-supply = <&reg_arm>;
+};
+
+&A53_2 {
+	cpu-supply = <&reg_arm>;
+};
+
+&A53_3 {
+	cpu-supply = <&reg_arm>;
+};
+
 /* off-board header */
 &ecspi2 {
 	pinctrl-names = "default";
@@ -362,7 +378,7 @@ BUCK1 {
 				regulator-ramp-delay = <3125>;
 			};
 
-			BUCK2 {
+			reg_arm: BUCK2 {
 				regulator-name = "BUCK2";
 				regulator-min-microvolt = <720000>;
 				regulator-max-microvolt = <1025000>;
Signature · 1 line
2.25.1
author
#9 lore raw

PATCH 6/6 arm64: dts: imx8mp-venice-gw74xx: add WiFi/BT module support

In reply to Tim Harvey

The GW74xx supports an on-board Laird Connectivity Sterling LWB5+ module which uses a Cypress CYW4373W chip to provide 1x1 802.11 a/b/g/n/ac + Bluetooth 5.2.

Add the proper device-tree nodes for it.

---
 .../dts/freescale/imx8mp-venice-gw74xx.dts    | 38 +++++++++++++++++--
 1 file changed, 35 insertions(+), 3 deletions(-)
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +35 -3
index bfc480aaf54d..47866d4e5444 100644
@@ -135,10 +135,10 @@ reg_wifi_en: regulator-wifi-en {
 		compatible = "regulator-fixed";
 		regulator-name = "wl";
 		gpio = <&gpio3 9 GPIO_ACTIVE_HIGH>;
-		startup-delay-us = <100>;
+		startup-delay-us = <70000>;
 		enable-active-high;
-		regulator-min-microvolt = <1800000>;
-		regulator-max-microvolt = <1800000>;
+		regulator-min-microvolt = <3300000>;
+		regulator-max-microvolt = <3300000>;
 	};
 };
 
@@ -577,6 +577,21 @@ &uart2 {
 	status = "okay";
 };
 
+/* bluetooth HCI */
+&uart3 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_uart3>, <&pinctrl_uart3_gpio>;
+	cts-gpios = <&gpio3 21 GPIO_ACTIVE_LOW>;
+	rts-gpios = <&gpio3 22 GPIO_ACTIVE_LOW>;
+	uart-has-rtscts;
+	status = "okay";
+
+	bluetooth {
+		compatible = "brcm,bcm4330-bt";
+		shutdown-gpios = <&gpio3 8 GPIO_ACTIVE_HIGH>;
+	};
+};
+
 &uart4 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_uart4>;
@@ -617,6 +632,23 @@ &usb_dwc3_1 {
 	status = "okay";
 };
 
+/* SDIO WiFi */
+&usdhc1 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_usdhc1>;
+	bus-width = <4>;
+	non-removable;
+	vmmc-supply = <&reg_wifi_en>;
+	#address-cells = <1>;
+	#size-cells = <0>;
+	status = "okay";
+
+	wifi@0 {
+		compatible = "cypress,cyw4373-fmac";
+		reg = <0>;
+	};
+};
+
 /* eMMC */
 &usdhc3 {
 	assigned-clocks = <&clk IMX8MP_CLK_USDHC3>;
Signature · 1 line
2.25.1
reviewer
#10 lore raw
In reply to Tim Harvey

Hi Tim,

arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts reg_can2_stby: regulator-can2-stby { · line 127

Quoted 12 lines · Tim Harvey
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +2 -2
index 521215520a0f..de17021df53f 100644
@@ -123,8 +123,8 @@ reg_can2_stby: regulator-can2-stby {
                pinctrl-names = "default";
                pinctrl-0 = <&pinctrl_reg_can>;
                regulator-name = "can2_stby";
-               gpio = <&gpio3 19 GPIO_ACTIVE_HIGH>;
-               enable-active-high;
+               gpio = <&gpio3 19 GPIO_ACTIVE_LOW>;
+               enable-active-low;

This 'enable-active-low' property does not exist. Just remove it.

author
#11 lore raw
Quoted 5 lines · Fabio Estevam

Hi Tim,

On Fri, Aug 12, 2022 at 2:35 PM Tim Harvey <[email protected]> wrote:

Quoted 14 lines

arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts reg_can2_stby: regulator-can2-stby { · line 127

Quoted 12 lines
arch/arm64/boot/dts/freescale/imx8mp-venice-gw74xx.dts +2 -2
index 521215520a0f..de17021df53f 100644
@@ -123,8 +123,8 @@ reg_can2_stby: regulator-can2-stby {
                pinctrl-names = "default";
                pinctrl-0 = <&pinctrl_reg_can>;
                regulator-name = "can2_stby";
-               gpio = <&gpio3 19 GPIO_ACTIVE_HIGH>;
-               enable-active-high;
+               gpio = <&gpio3 19 GPIO_ACTIVE_LOW>;
+               enable-active-low;

This 'enable-active-low' property does not exist. Just remove it.

Fabio,

Thanks - I see now that for active-low you just omit the 'enable-active-high' prop. I will send a new version.

Thanks,

Tim