Skip to contentSkip to conversation

arm64: dts: allwinner: Add Transpeed WiFi nodes

PATCH In review Andre Przywara 2 participants 7 messages Feb 9, 2024 – Feb 11, 2024

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

v2 cover arm64: dts: allwinner: Add Transpeed WiFi nodes

Hi,

a tiny update, see below for the changelog.
======================================

This adds the WiFi DT nodes for the Transpeed 8K618T TV box. It uses a Murata module with a Broadcom 4335 chip, which works fine with the mainline Linux driver, given you provide the proper firmware files. We found some in some LibreELEC repository.

Patch 1 adds the pinctrl node for the 32KHz clock fanout pin, patch 2 adds the actual SDIO WiFi node.

Please have a look!

Cheers,
Andre

Changelog v1 .. v2:
- add /omit-if-no-ref/ tag for clock fanout pin node
- update commit message to avoid mentioning Linux or driver

Andre Przywara (2):
arm64: dts: allwinner: h616: Add 32K fanout pin
arm64: dts: allwinner: Transpeed 8K618-T: add WiFi nodes

 .../arm64/boot/dts/allwinner/sun50i-h616.dtsi |  6 +++++
 .../sun50i-h618-transpeed-8k618-t.dts         | 23 +++++++++++++++++++
 2 files changed, 29 insertions(+)
Signature · 1 line
2.25.1
#1 lore raw

PATCH v2 1/2 arm64: dts: allwinner: h616: Add 32K fanout pin

On some boards the designers saved on a 32KHz crystal for some external chips, so the SoC has to help out, with providing a 32 KHz clock signal.

Add a pinctrl group node to allow DT nodes to reference this fanout signal.

---
 arch/arm64/boot/dts/allwinner/sun50i-h616.dtsi | 6 ++++++
 1 file changed, 6 insertions(+)
arch/arm64/boot/dts/allwinner/sun50i-h616.dtsi +6 -0
index d549d277d9729..12ffabc79bcde 100644
@@ -256,6 +256,12 @@ uart1_rts_cts_pins: uart1-rts-cts-pins {
 				pins = "PG8", "PG9";
 				function = "uart1";
 			};
+
+			/omit-if-no-ref/
+			x32clk_fanout_pin: x32clk-fanout-pin {
+				pins = "PG10";
+				function = "clock";
+			};
 		};
 
 		gic: interrupt-controller@3021000 {
Signature · 1 line
2.25.1
maintainer Reviewed-by on v2 1/2
#2 lore raw

Re: [PATCH v2 1/2] arm64: dts: allwinner: h616: Add 32K fanout pin

Dne petek, 09. februar 2024 ob 12:57:58 CET je Andre Przywara napisal(a):

Quoted 6 lines

On some boards the designers saved on a 32KHz crystal for some external chips, so the SoC has to help out, with providing a 32 KHz clock signal.

Add a pinctrl group node to allow DT nodes to reference this fanout signal.

Best regards,
Jernej

#3 lore raw

PATCH v2 2/2 arm64: dts: allwinner: Transpeed 8K618-T: add WiFi nodes

In reply to Andre Przywara

In contrast to other devices using Allwinner SoCs, the Transpeed 8K618-T TV box uses a mainline supported WiFi chip: it's Broadcom 4335 compatible, packaged by Murata.

Add the required DT nodes to let DT users know about the SDIO device. There is an otherwise empty MMC device node, to receive the MAC address, that firmware might want to write in there.

---
 .../sun50i-h618-transpeed-8k618-t.dts         | 23 +++++++++++++++++++
 1 file changed, 23 insertions(+)
arch/arm64/boot/dts/allwinner/sun50i-h618-transpeed-8k618-t.dts +23 -0
index 8ea1fd41aebaa..7ec4098e707bf 100644
@@ -16,6 +16,7 @@ / {
 
 	aliases {
 		serial0 = &uart0;
+		ethernet1 = &sdio_wifi;
 	};
 
 	chosen {
@@ -39,6 +40,15 @@ reg_vcc3v3: vcc3v3 {
 		regulator-max-microvolt = <3300000>;
 		regulator-always-on;
 	};
+
+	wifi_pwrseq: wifi_pwrseq {
+		compatible = "mmc-pwrseq-simple";
+		clocks = <&rtc CLK_OSC32K_FANOUT>;
+		clock-names = "ext_clock";
+		pinctrl-0 = <&x32clk_fanout_pin>;
+		pinctrl-names = "default";
+		reset-gpios = <&pio 6 18 GPIO_ACTIVE_LOW>; /* PG18 */
+	};
 };
 
 &ehci0 {
@@ -60,6 +70,19 @@ &mmc0 {
 	status = "okay";
 };
 
+&mmc1 {
+	vmmc-supply = <&reg_dldo1>;
+	vqmmc-supply = <&reg_aldo1>;
+	mmc-pwrseq = <&wifi_pwrseq>;
+	bus-width = <4>;
+	non-removable;
+	status = "okay";
+
+	sdio_wifi: wifi@1 {
+		reg = <1>;
+	};
+};
+
 &mmc2 {
 	vmmc-supply = <&reg_dldo1>;
 	vqmmc-supply = <&reg_aldo1>;
Signature · 1 line
2.25.1
maintainer Reviewed-by on v2 2/2
#4 lore raw

Re: [PATCH v2 2/2] arm64: dts: allwinner: Transpeed 8K618-T: add WiFi nodes

Dne petek, 09. februar 2024 ob 12:57:59 CET je Andre Przywara napisal(a):

Quoted 9 lines

In contrast to other devices using Allwinner SoCs, the Transpeed 8K618-T TV box uses a mainline supported WiFi chip: it's Broadcom 4335 compatible, packaged by Murata.

Add the required DT nodes to let DT users know about the SDIO device. There is an otherwise empty MMC device node, to receive the MAC address, that firmware might want to write in there.

Best regards,
Jernej

maintainer
#5 lore raw

Re: [PATCH v2 2/2] arm64: dts: allwinner: Transpeed 8K618-T: add WiFi nodes

In reply to Andre Przywara

Dne petek, 09. februar 2024 ob 12:57:59 CET je Andre Przywara napisal(a):

Quoted 18 lines

In contrast to other devices using Allwinner SoCs, the Transpeed 8K618-T TV box uses a mainline supported WiFi chip: it's Broadcom 4335 compatible, packaged by Murata.

Add the required DT nodes to let DT users know about the SDIO device. There is an otherwise empty MMC device node, to receive the MAC address, that firmware might want to write in there.

---
 .../sun50i-h618-transpeed-8k618-t.dts         | 23 +++++++++++++++++++
 1 file changed, 23 insertions(+)
arch/arm64/boot/dts/allwinner/sun50i-h618-transpeed-8k618-t.dts +0 -0
index 8ea1fd41aebaa..7ec4098e707bf 100644

arch/arm64/boot/dts/allwinner/sun50i-h618-transpeed-8k618-t.dts / { · line 19

Quoted 4 lines
arch/arm64/boot/dts/allwinner/sun50i-h618-transpeed-8k618-t.dts +1 -0
@@ -16,6 +16,7 @@ / {
 
 	aliases {
 		serial0 = &uart0;
+		ethernet1 = &sdio_wifi;

Ah, this is not sorted alphabetically. I can fix this while applying.

Best regards,
Jernej

Quoted 40 lines
arch/arm64/boot/dts/allwinner/sun50i-h618-transpeed-8k618-t.dts +22 -0
 	};
 
 	chosen {
@@ -39,6 +40,15 @@ reg_vcc3v3: vcc3v3 {
 		regulator-max-microvolt = <3300000>;
 		regulator-always-on;
 	};
+
+	wifi_pwrseq: wifi_pwrseq {
+		compatible = "mmc-pwrseq-simple";
+		clocks = <&rtc CLK_OSC32K_FANOUT>;
+		clock-names = "ext_clock";
+		pinctrl-0 = <&x32clk_fanout_pin>;
+		pinctrl-names = "default";
+		reset-gpios = <&pio 6 18 GPIO_ACTIVE_LOW>; /* PG18 */
+	};
 };
 
 &ehci0 {
@@ -60,6 +70,19 @@ &mmc0 {
 	status = "okay";
 };
 
+&mmc1 {
+	vmmc-supply = <&reg_dldo1>;
+	vqmmc-supply = <&reg_aldo1>;
+	mmc-pwrseq = <&wifi_pwrseq>;
+	bus-width = <4>;
+	non-removable;
+	status = "okay";
+
+	sdio_wifi: wifi@1 {
+		reg = <1>;
+	};
+};
+
 &mmc2 {
 	vmmc-supply = <&reg_dldo1>;
 	vqmmc-supply = <&reg_aldo1>;
maintainer
#6 lore raw
In reply to Andre Przywara

Dne petek, 09. februar 2024 ob 12:57:57 CET je Andre Przywara napisal(a):

Quoted 10 lines

Hi,

a tiny update, see below for the changelog.
======================================

This adds the WiFi DT nodes for the Transpeed 8K618T TV box. It uses a Murata module with a Broadcom 4335 chip, which works fine with the mainline Linux driver, given you provide the proper firmware files. We found some in some LibreELEC repository.

Quoted 4 lines

Patch 1 adds the pinctrl node for the 32KHz clock fanout pin, patch 2 adds the actual SDIO WiFi node.

Please have a look!

Fixed order in patch 2 and applied, thanks!

Best regards,
Jernej

Quoted 17 lines

Cheers,
Andre

Changelog v1 .. v2:
- add /omit-if-no-ref/ tag for clock fanout pin node
- update commit message to avoid mentioning Linux or driver

Andre Przywara (2):
arm64: dts: allwinner: h616: Add 32K fanout pin
arm64: dts: allwinner: Transpeed 8K618-T: add WiFi nodes

 .../arm64/boot/dts/allwinner/sun50i-h616.dtsi |  6 +++++
 .../sun50i-h618-transpeed-8k618-t.dts         | 23 +++++++++++++++++++
 2 files changed, 29 insertions(+)