All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/4] Enable Broadcom SDIO WLAN for the Exynos boards
       [not found] <CGME20200326094634eucas1p23ee479ba6c38c6baca839375a6751f0e@eucas1p2.samsung.com>
@ 2020-03-26  9:46 ` Marek Szyprowski
       [not found]   ` <CGME20200326094634eucas1p1d02b6124a500b7bac6a9702d93915c42@eucas1p1.samsung.com>
                     ` (3 more replies)
  0 siblings, 4 replies; 10+ messages in thread
From: Marek Szyprowski @ 2020-03-26  9:46 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: Marek Szyprowski, Krzysztof Kozlowski, Chanwoo Choi,
	Bartlomiej Zolnierkiewicz

Hi

The recently posted patchset "ARM: DTS: Add devicetree file for the
Galaxy S2" inspired me to enable the SDIO WLAN also for the other
Exynos-based boards, which use Broadcom SDIO chips. Here are the results.

Best regards
Marek Szyprowski
Samsung R&D Institute Poland


Patch summary:

Marek Szyprowski (4):
  ARM: dts: exynos: Enable WLAN support for the UniversalC210 board
  ARM: dts: exynos: Enable WLAN support for the Trats board
  ARM: dts: exynos: Enable WLAN support for the Rinato board
  ARM: exynos_defconfig: Compile MAC80211/CFG80211 as modules

 arch/arm/boot/dts/exynos3250-rinato.dts       | 36 +++++++++++++++++++
 arch/arm/boot/dts/exynos4210-trats.dts        | 29 +++++++++++++++
 .../boot/dts/exynos4210-universal_c210.dts    | 28 +++++++++++++++
 arch/arm/configs/exynos_defconfig             |  6 ++--
 4 files changed, 96 insertions(+), 3 deletions(-)

-- 
2.17.1


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH 1/4] ARM: dts: exynos: Enable WLAN support for the UniversalC210 board
       [not found]   ` <CGME20200326094634eucas1p1d02b6124a500b7bac6a9702d93915c42@eucas1p1.samsung.com>
@ 2020-03-26  9:46     ` Marek Szyprowski
  2020-03-27 12:21       ` Krzysztof Kozlowski
  2020-03-27 12:51       ` Krzysztof Kozlowski
  0 siblings, 2 replies; 10+ messages in thread
From: Marek Szyprowski @ 2020-03-26  9:46 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: Marek Szyprowski, Krzysztof Kozlowski, Chanwoo Choi,
	Bartlomiej Zolnierkiewicz

Add a node for BCM4330/2 SDIO chip on SDHCI bus #3 and the required MMC
power sequence node for the Exynos4210-based UniversalC210 board.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
---
 .../boot/dts/exynos4210-universal_c210.dts    | 28 +++++++++++++++++++
 1 file changed, 28 insertions(+)

diff --git a/arch/arm/boot/dts/exynos4210-universal_c210.dts b/arch/arm/boot/dts/exynos4210-universal_c210.dts
index 9dda6bdb9253..c78423a2d10f 100644
--- a/arch/arm/boot/dts/exynos4210-universal_c210.dts
+++ b/arch/arm/boot/dts/exynos4210-universal_c210.dts
@@ -50,6 +50,11 @@
 		enable-active-high;
 	};
 
+	wlan_pwrseq: sdhci3-pwrseq {
+		compatible = "mmc-pwrseq-simple";
+		reset-gpios = <&gpe3 1 GPIO_ACTIVE_LOW>;
+	};
+
 	gpio-keys {
 		compatible = "gpio-keys";
 
@@ -563,6 +568,29 @@
 	status = "okay";
 };
 
+&sdhci_3 {
+        status = "okay";
+
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        non-removable;
+        bus-width = <4>;
+        mmc-pwrseq = <&wlan_pwrseq>;
+        vmmc-supply = <&ldo5_reg>;
+
+        pinctrl-names = "default";
+        pinctrl-0 = <&sd3_clk>, <&sd3_cmd>, <&sd3_bus4>;
+
+        brcmf: wifi@1 {
+                compatible = "brcm,bcm4330-fmac";
+                reg = <1>;
+                interrupt-parent = <&gpx2>;
+                interrupts = <5 IRQ_TYPE_LEVEL_HIGH>;
+                interrupt-names = "host-wake";
+        };
+};
+
 &serial_0 {
 	status = "okay";
 	/delete-property/dmas;
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 2/4] ARM: dts: exynos: Enable WLAN support for the Trats board
       [not found]   ` <CGME20200326094635eucas1p2220473a93430f9319130dfc2449033b7@eucas1p2.samsung.com>
@ 2020-03-26  9:46     ` Marek Szyprowski
  2020-03-27 12:22       ` Krzysztof Kozlowski
  0 siblings, 1 reply; 10+ messages in thread
From: Marek Szyprowski @ 2020-03-26  9:46 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: Marek Szyprowski, Krzysztof Kozlowski, Chanwoo Choi,
	Bartlomiej Zolnierkiewicz

Add a node for BCM4330/3 SDIO chip on SDHCI bus #3 and the required MMC
power sequence node for the Exynos4210-based Trats board.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
---
 arch/arm/boot/dts/exynos4210-trats.dts | 29 ++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)

diff --git a/arch/arm/boot/dts/exynos4210-trats.dts b/arch/arm/boot/dts/exynos4210-trats.dts
index 7c39dd1c4d3a..df901f113df5 100644
--- a/arch/arm/boot/dts/exynos4210-trats.dts
+++ b/arch/arm/boot/dts/exynos4210-trats.dts
@@ -121,6 +121,11 @@
 		};
 	};
 
+	wlan_pwrseq: sdhci3-pwrseq {
+		compatible = "mmc-pwrseq-simple";
+		reset-gpios = <&gpl1 2 GPIO_ACTIVE_LOW>;
+	};
+
 	fixed-rate-clocks {
 		xxti {
 			compatible = "samsung,clock-xxti";
@@ -471,6 +476,30 @@
 	status = "okay";
 };
 
+&sdhci_3 {
+	status = "okay";
+
+	#address-cells = <1>;
+	#size-cells = <0>;
+
+	non-removable;
+	bus-width = <4>;
+	mmc-pwrseq = <&wlan_pwrseq>;
+	vmmc-supply = <&tflash_reg>;
+
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd3_clk>, <&sd3_cmd>, <&sd3_bus4>;
+
+	brcmf: wifi@1 {
+		compatible = "brcm,bcm4330-fmac";
+		reg = <1>;
+
+		interrupt-parent = <&gpx2>;
+		interrupts = <5 IRQ_TYPE_LEVEL_HIGH>;
+		interrupt-names = "host-wake";
+	};
+};
+
 &serial_0 {
 	status = "okay";
 };
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 3/4] ARM: dts: exynos: Enable WLAN support for the Rinato board
       [not found]   ` <CGME20200326094635eucas1p17fbc47aecd9be9df10daacf091bc52be@eucas1p1.samsung.com>
@ 2020-03-26  9:46     ` Marek Szyprowski
  2020-03-27 12:24       ` Krzysztof Kozlowski
  0 siblings, 1 reply; 10+ messages in thread
From: Marek Szyprowski @ 2020-03-26  9:46 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: Marek Szyprowski, Krzysztof Kozlowski, Chanwoo Choi,
	Bartlomiej Zolnierkiewicz

Add a node for BCM43342A SDIO chip on MSHC bus #1 and the required MMC
power sequence node for the Exynos3250-based Rinato board.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
---
 arch/arm/boot/dts/exynos3250-rinato.dts | 36 +++++++++++++++++++++++++
 1 file changed, 36 insertions(+)

diff --git a/arch/arm/boot/dts/exynos3250-rinato.dts b/arch/arm/boot/dts/exynos3250-rinato.dts
index 03f214089fd4..86fedccf277c 100644
--- a/arch/arm/boot/dts/exynos3250-rinato.dts
+++ b/arch/arm/boot/dts/exynos3250-rinato.dts
@@ -50,6 +50,11 @@
 		};
 	};
 
+	wlan_pwrseq: mshc1-pwrseq {
+		compatible = "mmc-pwrseq-simple";
+		reset-gpios = <&gpe0 4 GPIO_ACTIVE_LOW>;
+	};
+
 	i2c_max77836: i2c-gpio-0 {
 		compatible = "i2c-gpio";
 		gpios = <&gpd0 2 GPIO_ACTIVE_HIGH>, <&gpd0 3 GPIO_ACTIVE_HIGH>;
@@ -625,6 +630,37 @@
 	status = "okay";
 };
 
+&mshc_1 {
+	status = "okay";
+
+	#address-cells = <1>;
+	#size-cells = <0>;
+
+	broken-cd;
+	non-removable;
+	cap-sd-highspeed;
+	cap-sdio-irq;
+	keep-power-in-suspend;
+	card-detect-delay = <200>;
+	samsung,dw-mshc-ciu-div = <1>;
+	samsung,dw-mshc-sdr-timing = <0 1>;
+	samsung,dw-mshc-ddr-timing = <1 2>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_bus1 &sd1_bus4>;
+	bus-width = <4>;
+
+	mmc-pwrseq = <&wlan_pwrseq>;
+
+	brcmf: wifi@1 {
+		compatible = "brcm,bcm4334-fmac";
+		reg = <1>;
+
+		interrupt-parent = <&gpx1>;
+		interrupts = <1 IRQ_TYPE_LEVEL_HIGH>;
+		interrupt-names = "host-wake";
+	};
+};
+
 &serial_0 {
 	assigned-clocks = <&cmu CLK_SCLK_UART0>;
 	assigned-clock-rates = <100000000>;
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 4/4] ARM: exynos_defconfig: Compile MAC80211/CFG80211 as modules
       [not found]   ` <CGME20200326094635eucas1p2fab15692c98fc148388a6922dc0d121f@eucas1p2.samsung.com>
@ 2020-03-26  9:46     ` Marek Szyprowski
  2020-04-13 10:22       ` Krzysztof Kozlowski
  0 siblings, 1 reply; 10+ messages in thread
From: Marek Szyprowski @ 2020-03-26  9:46 UTC (permalink / raw)
  To: linux-samsung-soc
  Cc: Marek Szyprowski, Krzysztof Kozlowski, Chanwoo Choi,
	Bartlomiej Zolnierkiewicz

MAC80211/CFG80211 framework requires loading regulatory.db from
/lib/firmware directory, so it makes very little sense to have it
built-in. Change it to be built as modules to let it properly load the
needed firmware/db files. As a side effect of this change, the size of
the compressed modules on SquashFS increased significantly from 27MiB
to 38MiB, so increase the size of BLK_DEV_RAM to allow the modules to
fit into it.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
---
 arch/arm/configs/exynos_defconfig | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/arch/arm/configs/exynos_defconfig b/arch/arm/configs/exynos_defconfig
index 1ea2f87533ef..1bbbc677f0e3 100644
--- a/arch/arm/configs/exynos_defconfig
+++ b/arch/arm/configs/exynos_defconfig
@@ -79,8 +79,8 @@ CONFIG_BT_HCIVHCI=m
 CONFIG_BT_MRVL=m
 CONFIG_BT_MRVL_SDIO=m
 CONFIG_BT_ATH3K=m
-CONFIG_CFG80211=y
-CONFIG_MAC80211=y
+CONFIG_CFG80211=m
+CONFIG_MAC80211=m
 CONFIG_MAC80211_LEDS=y
 CONFIG_NFC=y
 CONFIG_NFC_DIGITAL=m
@@ -95,7 +95,7 @@ CONFIG_DEVTMPFS_MOUNT=y
 CONFIG_BLK_DEV_LOOP=y
 CONFIG_BLK_DEV_CRYPTOLOOP=y
 CONFIG_BLK_DEV_RAM=y
-CONFIG_BLK_DEV_RAM_SIZE=32768
+CONFIG_BLK_DEV_RAM_SIZE=65536
 CONFIG_SCSI=y
 CONFIG_BLK_DEV_SD=y
 CONFIG_CHR_DEV_SG=y
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* Re: [PATCH 1/4] ARM: dts: exynos: Enable WLAN support for the UniversalC210 board
  2020-03-26  9:46     ` [PATCH 1/4] ARM: dts: exynos: Enable WLAN support for the UniversalC210 board Marek Szyprowski
@ 2020-03-27 12:21       ` Krzysztof Kozlowski
  2020-03-27 12:51       ` Krzysztof Kozlowski
  1 sibling, 0 replies; 10+ messages in thread
From: Krzysztof Kozlowski @ 2020-03-27 12:21 UTC (permalink / raw)
  To: Marek Szyprowski
  Cc: linux-samsung-soc, Chanwoo Choi, Bartlomiej Zolnierkiewicz

On Thu, Mar 26, 2020 at 10:46:23AM +0100, Marek Szyprowski wrote:
> Add a node for BCM4330/2 SDIO chip on SDHCI bus #3 and the required MMC
> power sequence node for the Exynos4210-based UniversalC210 board.
> 
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
>  .../boot/dts/exynos4210-universal_c210.dts    | 28 +++++++++++++++++++

Thanks, applied (for late pull).

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH 2/4] ARM: dts: exynos: Enable WLAN support for the Trats board
  2020-03-26  9:46     ` [PATCH 2/4] ARM: dts: exynos: Enable WLAN support for the Trats board Marek Szyprowski
@ 2020-03-27 12:22       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 10+ messages in thread
From: Krzysztof Kozlowski @ 2020-03-27 12:22 UTC (permalink / raw)
  To: Marek Szyprowski
  Cc: linux-samsung-soc, Chanwoo Choi, Bartlomiej Zolnierkiewicz

On Thu, Mar 26, 2020 at 10:46:24AM +0100, Marek Szyprowski wrote:
> Add a node for BCM4330/3 SDIO chip on SDHCI bus #3 and the required MMC
> power sequence node for the Exynos4210-based Trats board.
> 
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
>  arch/arm/boot/dts/exynos4210-trats.dts | 29 ++++++++++++++++++++++++++

Thanks, applied.

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH 3/4] ARM: dts: exynos: Enable WLAN support for the Rinato board
  2020-03-26  9:46     ` [PATCH 3/4] ARM: dts: exynos: Enable WLAN support for the Rinato board Marek Szyprowski
@ 2020-03-27 12:24       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 10+ messages in thread
From: Krzysztof Kozlowski @ 2020-03-27 12:24 UTC (permalink / raw)
  To: Marek Szyprowski
  Cc: linux-samsung-soc, Chanwoo Choi, Bartlomiej Zolnierkiewicz

On Thu, Mar 26, 2020 at 10:46:25AM +0100, Marek Szyprowski wrote:
> Add a node for BCM43342A SDIO chip on MSHC bus #1 and the required MMC
> power sequence node for the Exynos3250-based Rinato board.
> 
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
>  arch/arm/boot/dts/exynos3250-rinato.dts | 36 +++++++++++++++++++++++++
>  1 file changed, 36 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/exynos3250-rinato.dts b/arch/arm/boot/dts/exynos3250-rinato.dts
> index 03f214089fd4..86fedccf277c 100644
> --- a/arch/arm/boot/dts/exynos3250-rinato.dts
> +++ b/arch/arm/boot/dts/exynos3250-rinato.dts
> @@ -50,6 +50,11 @@
>  		};
>  	};
>  
> +	wlan_pwrseq: mshc1-pwrseq {
> +		compatible = "mmc-pwrseq-simple";
> +		reset-gpios = <&gpe0 4 GPIO_ACTIVE_LOW>;
> +	};
> +
>  	i2c_max77836: i2c-gpio-0 {
>  		compatible = "i2c-gpio";
>  		gpios = <&gpd0 2 GPIO_ACTIVE_HIGH>, <&gpd0 3 GPIO_ACTIVE_HIGH>;
> @@ -625,6 +630,37 @@
>  	status = "okay";
>  };
>  
> +&mshc_1 {
> +	status = "okay";
> +
> +	#address-cells = <1>;
> +	#size-cells = <0>;
> +
> +	broken-cd;
> +	non-removable;

These two exclude each other. I guess it should be non-removable only.

Best regards,
Krzysztof

> +	cap-sd-highspeed;
> +	cap-sdio-irq;
> +	keep-power-in-suspend;
> +	card-detect-delay = <200>;
> +	samsung,dw-mshc-ciu-div = <1>;
> +	samsung,dw-mshc-sdr-timing = <0 1>;
> +	samsung,dw-mshc-ddr-timing = <1 2>;
> +	pinctrl-names = "default";
> +	pinctrl-0 = <&sd1_clk &sd1_cmd &sd1_bus1 &sd1_bus4>;
> +	bus-width = <4>;
> +
> +	mmc-pwrseq = <&wlan_pwrseq>;
> +
> +	brcmf: wifi@1 {
> +		compatible = "brcm,bcm4334-fmac";
> +		reg = <1>;
> +
> +		interrupt-parent = <&gpx1>;
> +		interrupts = <1 IRQ_TYPE_LEVEL_HIGH>;
> +		interrupt-names = "host-wake";
> +	};
> +};
> +
>  &serial_0 {
>  	assigned-clocks = <&cmu CLK_SCLK_UART0>;
>  	assigned-clock-rates = <100000000>;
> -- 
> 2.17.1
> 

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH 1/4] ARM: dts: exynos: Enable WLAN support for the UniversalC210 board
  2020-03-26  9:46     ` [PATCH 1/4] ARM: dts: exynos: Enable WLAN support for the UniversalC210 board Marek Szyprowski
  2020-03-27 12:21       ` Krzysztof Kozlowski
@ 2020-03-27 12:51       ` Krzysztof Kozlowski
  1 sibling, 0 replies; 10+ messages in thread
From: Krzysztof Kozlowski @ 2020-03-27 12:51 UTC (permalink / raw)
  To: Marek Szyprowski
  Cc: linux-samsung-soc, Chanwoo Choi, Bartlomiej Zolnierkiewicz

On Thu, Mar 26, 2020 at 10:46:23AM +0100, Marek Szyprowski wrote:
> Add a node for BCM4330/2 SDIO chip on SDHCI bus #3 and the required MMC
> power sequence node for the Exynos4210-based UniversalC210 board.
> 
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
>  .../boot/dts/exynos4210-universal_c210.dts    | 28 +++++++++++++++++++

... and dropped. You have multiple checkpatch errors. Please fix them.

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH 4/4] ARM: exynos_defconfig: Compile MAC80211/CFG80211 as modules
  2020-03-26  9:46     ` [PATCH 4/4] ARM: exynos_defconfig: Compile MAC80211/CFG80211 as modules Marek Szyprowski
@ 2020-04-13 10:22       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 10+ messages in thread
From: Krzysztof Kozlowski @ 2020-04-13 10:22 UTC (permalink / raw)
  To: Marek Szyprowski
  Cc: linux-samsung-soc, Chanwoo Choi, Bartlomiej Zolnierkiewicz

On Thu, Mar 26, 2020 at 10:46:26AM +0100, Marek Szyprowski wrote:
> MAC80211/CFG80211 framework requires loading regulatory.db from
> /lib/firmware directory, so it makes very little sense to have it
> built-in. Change it to be built as modules to let it properly load the
> needed firmware/db files. As a side effect of this change, the size of
> the compressed modules on SquashFS increased significantly from 27MiB
> to 38MiB, so increase the size of BLK_DEV_RAM to allow the modules to
> fit into it.
> 
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
>  arch/arm/configs/exynos_defconfig | 6 +++---

Thanks, applied.

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2020-04-13 10:22 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CGME20200326094634eucas1p23ee479ba6c38c6baca839375a6751f0e@eucas1p2.samsung.com>
2020-03-26  9:46 ` [PATCH 0/4] Enable Broadcom SDIO WLAN for the Exynos boards Marek Szyprowski
     [not found]   ` <CGME20200326094634eucas1p1d02b6124a500b7bac6a9702d93915c42@eucas1p1.samsung.com>
2020-03-26  9:46     ` [PATCH 1/4] ARM: dts: exynos: Enable WLAN support for the UniversalC210 board Marek Szyprowski
2020-03-27 12:21       ` Krzysztof Kozlowski
2020-03-27 12:51       ` Krzysztof Kozlowski
     [not found]   ` <CGME20200326094635eucas1p2220473a93430f9319130dfc2449033b7@eucas1p2.samsung.com>
2020-03-26  9:46     ` [PATCH 2/4] ARM: dts: exynos: Enable WLAN support for the Trats board Marek Szyprowski
2020-03-27 12:22       ` Krzysztof Kozlowski
     [not found]   ` <CGME20200326094635eucas1p17fbc47aecd9be9df10daacf091bc52be@eucas1p1.samsung.com>
2020-03-26  9:46     ` [PATCH 3/4] ARM: dts: exynos: Enable WLAN support for the Rinato board Marek Szyprowski
2020-03-27 12:24       ` Krzysztof Kozlowski
     [not found]   ` <CGME20200326094635eucas1p2fab15692c98fc148388a6922dc0d121f@eucas1p2.samsung.com>
2020-03-26  9:46     ` [PATCH 4/4] ARM: exynos_defconfig: Compile MAC80211/CFG80211 as modules Marek Szyprowski
2020-04-13 10:22       ` Krzysztof Kozlowski

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.