Enable ath10k wcn3990 wifi driver support on sdm845
Subsystems (5)
v2 cover Enable ath10k wcn3990 wifi driver support on sdm845
This series enables ath10k wifi driver support for WCN3990 target on sdm845 SOC. This series also updates the missing dt binding documentation and adds optional iommu property.
sdm845 dtsi changes in this series are based on top of
https://patchwork.kernel.org/cover/10573121/ change.
Changes since v1:
Listed no of interrupts/clocks for each set of compatible. Added missing 'wifi' label to sdm845.dtsi.
Govind Singh (4):
dt: bindings: add missing dt properties for WCN3990 wifi node
dts: arm64/sdm845: Add WCN3990 WLAN module device node
dt: bindings: add bindings for wifi iommu node
dts: arm64/sdm845: Enable iommu for WCN3990 wifi module device node
.../bindings/net/wireless/qcom,ath10k.txt | 34 +++++++++++++++---- arch/arm64/boot/dts/qcom/sdm845-mtp.dts | 7 ++++ arch/arm64/boot/dts/qcom/sdm845.dtsi | 27 +++++++++++++++ 3 files changed, 61 insertions(+), 7 deletions(-)
Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
PATCH v2 1/4 dt: bindings: add missing dt properties for WCN3990 wifi node
Add missing optional properties in WCN3990 wifi node.
--- .../bindings/net/wireless/qcom,ath10k.txt | 28 ++++++++++++++----- 1 file changed, 21 insertions(+), 7 deletions(-)
Documentation/devicetree/bindings/net/wireless/qcom,ath10k.txt +21 -7
@@ -37,12 +37,20 @@ Optional properties: - clocks: List of clock specifiers, must contain an entry for each required entry in clock-names. - clock-names: Should contain the clock names "wifi_wcss_cmd", "wifi_wcss_ref", - "wifi_wcss_rtc". -- interrupts: List of interrupt lines. Must contain an entry - for each entry in the interrupt-names property. + "wifi_wcss_rtc" for "qcom,ipq4019-wifi" compatible target and + "cxo_ref_clk_pin", "smmu_aggre2_noc_clk" for "qcom,wcn3990-wifi" + compatible target. +- interrupts: reference to the list of 17 interrupt no's for "qcom,ipq4019-wifi" + compatible target. + reference to the list of 12 interrupt no's for "qcom,wcn3990-wifi" + compatible target. + Must contain interrupt-names property per entry for + "qcom,ath10k", "qcom,ipq4019-wifi" compatible targets. + - interrupt-names: Must include the entries for MSI interrupt names ("msi0" to "msi15") and legacy interrupt - name ("legacy"), + name ("legacy") for "qcom,ath10k", "qcom,ipq4019-wifi" + compatible targets. - qcom,msi_addr: MSI interrupt address. - qcom,msi_base: Base value to add before writing MSI data into MSI address register.
@@ -55,7 +63,8 @@ Optional properties: - qcom,ath10k-pre-calibration-data : pre calibration data as an array, the length can vary between hw versions. - <supply-name>-supply: handle to the regulator device tree node - optional "supply-name" is "vdd-0.8-cx-mx". + optional "supply-name" are "vdd-0.8-cx-mx", + "vdd-1.8-xo", "vdd-1.3-rfa" and "vdd-3.3-ch0". Example (to supply the calibration data alone):
@@ -133,8 +142,10 @@ wifi@18000000 { compatible = "qcom,wcn3990-wifi"; reg = <0x18800000 0x800000>; reg-names = "membase"; - clocks = <&clock_gcc clk_aggre2_noc_clk>; - clock-names = "smmu_aggre2_noc_clk" + clocks = <&clock_gcc clk_aggre2_noc_clk>, + <&clock_gcc clk_rf_clk2_pin>; + clock-names = "smmu_aggre2_noc_clk", + "cxo_ref_clk_pin"; interrupts = <0 130 0 /* CE0 */ >, <0 131 0 /* CE1 */ >,
@@ -149,4 +160,7 @@ wifi@18000000 { <0 140 0 /* CE10 */ >, <0 141 0 /* CE11 */ >; vdd-0.8-cx-mx-supply = <&pm8998_l5>; + vdd-1.8-xo-supply = <&vreg_l7a_1p8>; + vdd-1.3-rfa-supply = <&vreg_l17a_1p3>; + vdd-3.3-ch0-supply = <&vreg_l25a_3p3>; };
Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
PATCH v2 2/4 dts: arm64/sdm845: Add WCN3990 WLAN module device node
In reply to Govind SinghAdd device node for the ath10k SNOC platform driver probe and add resources required for WCN3990 on SDM845 soc.
--- arch/arm64/boot/dts/qcom/sdm845-mtp.dts | 7 +++++++ arch/arm64/boot/dts/qcom/sdm845.dtsi | 26 +++++++++++++++++++++++++ 2 files changed, 33 insertions(+)
arch/arm64/boot/dts/qcom/sdm845-mtp.dts +7 -0
@@ -440,3 +440,10 @@ bias-pull-up; }; }; + +&wifi { + vdd-0.8-cx-mx-supply = <&vreg_l5a_0p8>; + vdd-1.8-xo-supply = <&vreg_l7a_1p8>; + vdd-1.3-rfa-supply = <&vreg_l17a_1p3>; + vdd-3.3-ch0-supply = <&vreg_l25a_3p3>; +};
arch/arm64/boot/dts/qcom/sdm845.dtsi +26 -0
@@ -86,6 +86,11 @@ reg = <0 0x86200000 0 0x2d00000>; no-map; }; + + wlan_msa_mem: reserved-memory@96700000 { + no-map; + reg = <0 0x96700000 0 0x100000>; + }; }; cpus {
@@ -1200,5 +1205,26 @@ status = "disabled"; }; }; + + wifi: wifi@18800000 { + compatible = "qcom,wcn3990-wifi"; + status = "disabled"; + reg = <0x18800000 0x800000>; + reg-names = "membase"; + memory-region = <&wlan_msa_mem>; + interrupts = + <0 413 0 /* CE0 */ >, + <0 414 0 /* CE1 */ >, + <0 415 0 /* CE2 */ >, + <0 416 0 /* CE3 */ >, + <0 417 0 /* CE4 */ >, + <0 418 0 /* CE5 */ >, + <0 420 0 /* CE6 */ >, + <0 421 0 /* CE7 */ >, + <0 422 0 /* CE8 */ >, + <0 423 0 /* CE9 */ >, + <0 424 0 /* CE10 */ >, + <0 425 0 /* CE11 */ >; + }; }; };
Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
Re: [PATCH v2 2/4] dts: arm64/sdm845: Add WCN3990 WLAN module device node
+ linux-msm, linux-soc
Hi Govind,
Quoted 14 lines · Govind Singh
Add device node for the ath10k SNOC platform driver probe and add resources required for WCN3990 on SDM845 soc.
Signed-off-by Govind Singh <[email protected]>--- arch/arm64/boot/dts/qcom/sdm845-mtp.dts | 7 +++++++ arch/arm64/boot/dts/qcom/sdm845.dtsi | 26 +++++++++++++++++++++++++ 2 files changed, 33 insertions(+)arch/arm64/boot/dts/qcom/sdm845-mtp.dts +0
-0
arch/arm64/boot/dts/qcom/sdm845-mtp.dts line 444
Quoted 5 lines
arch/arm64/boot/dts/qcom/sdm845-mtp.dts +2
-0@@ -440,3 +440,10 @@ bias-pull-up; }; }; + +&wifi {
You missed overriding 'status':
status = "okay";
Also, I think pinctrl overrides are purposely kept separate from other node modifications here (see the /* PINCTRL - ... */ comment header). So &wifi should probably be just after the &usb_2_qmpphy override I currently see in linux-next.
Brian
Quoted 52 lines
arch/arm64/boot/dts/qcom/sdm845-mtp.dts +5
-0+ vdd-0.8-cx-mx-supply = <&vreg_l5a_0p8>; + vdd-1.8-xo-supply = <&vreg_l7a_1p8>; + vdd-1.3-rfa-supply = <&vreg_l17a_1p3>; + vdd-3.3-ch0-supply = <&vreg_l25a_3p3>; +};arch/arm64/boot/dts/qcom/sdm845.dtsi +26
-0@@ -86,6 +86,11 @@ reg = <0 0x86200000 0 0x2d00000>; no-map; }; + + wlan_msa_mem: reserved-memory@96700000 { + no-map; + reg = <0 0x96700000 0 0x100000>; + }; }; cpus {@@ -1200,5 +1205,26 @@ status = "disabled"; }; }; + + wifi: wifi@18800000 { + compatible = "qcom,wcn3990-wifi"; + status = "disabled"; + reg = <0x18800000 0x800000>; + reg-names = "membase"; + memory-region = <&wlan_msa_mem>; + interrupts = + <0 413 0 /* CE0 */ >, + <0 414 0 /* CE1 */ >, + <0 415 0 /* CE2 */ >, + <0 416 0 /* CE3 */ >, + <0 417 0 /* CE4 */ >, + <0 418 0 /* CE5 */ >, + <0 420 0 /* CE6 */ >, + <0 421 0 /* CE7 */ >, + <0 422 0 /* CE8 */ >, + <0 423 0 /* CE9 */ >, + <0 424 0 /* CE10 */ >, + <0 425 0 /* CE11 */ >; + }; }; };Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
PATCH v2 3/4 dt: bindings: add bindings for wifi iommu node
In reply to Govind SinghWCN3990 wifi module can optionally make use of the IOMMU. Add binding documentation for phandle to the IOMMU and the stream id of wifi iommu block.
--- .../devicetree/bindings/net/wireless/qcom,ath10k.txt | 6 ++++++ 1 file changed, 6 insertions(+)
Documentation/devicetree/bindings/net/wireless/qcom,ath10k.txt +6 -0
@@ -65,6 +65,11 @@ Optional properties: - <supply-name>-supply: handle to the regulator device tree node optional "supply-name" are "vdd-0.8-cx-mx", "vdd-1.8-xo", "vdd-1.3-rfa" and "vdd-3.3-ch0". +- iommus: + Usage: optional + Value type: <prop-encoded-array> + Definition: A list of phandle and IOMMU specifier pairs + for "qcom,wcn3990-wifi" compatible target. Example (to supply the calibration data alone):
@@ -163,4 +168,5 @@ wifi@18000000 { vdd-1.8-xo-supply = <&vreg_l7a_1p8>; vdd-1.3-rfa-supply = <&vreg_l17a_1p3>; vdd-3.3-ch0-supply = <&vreg_l25a_3p3>; + iommus = <&apps_smmu 0x0040 0x1>; };
Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
PATCH v2 4/4 dts: arm64/sdm845: Enable iommu for WCN3990 wifi module device node
In reply to Govind SinghWCN3990 wifi module can optionally make use of the IOMMU. Add phandle to the iommu and stream id of wifi iommu block.
--- arch/arm64/boot/dts/qcom/sdm845.dtsi | 1 + 1 file changed, 1 insertion(+)
arch/arm64/boot/dts/qcom/sdm845.dtsi +1 -0
@@ -1225,6 +1225,7 @@ <0 423 0 /* CE9 */ >, <0 424 0 /* CE10 */ >, <0 425 0 /* CE11 */ >; + iommus = <&apps_smmu 0x0040 0x1>; }; }; };
Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
Re: [PATCH v2 4/4] dts: arm64/sdm845: Enable iommu for WCN3990 wifi module device node
+ linux-msm, linux-soc
Quoted 13 lines · Govind Singh
WCN3990 wifi module can optionally make use of the IOMMU. Add phandle to the iommu and stream id of wifi iommu block.
Signed-off-by Govind Singh <[email protected]>--- arch/arm64/boot/dts/qcom/sdm845.dtsi | 1 + 1 file changed, 1 insertion(+)arch/arm64/boot/dts/qcom/sdm845.dtsi +0
-0
arch/arm64/boot/dts/qcom/sdm845.dtsi line 1228
Quoted 4 lines
arch/arm64/boot/dts/qcom/sdm845.dtsi +1
-0@@ -1225,6 +1225,7 @@ <0 423 0 /* CE9 */ >, <0 424 0 /* CE10 */ >, <0 425 0 /* CE11 */ >; + iommus = <&apps_smmu 0x0040 0x1>;
I don't see an apps_smmu label in any of the sdm845 files yet. I don't think this piece has landed in any -next tree yet. So your patch won't work.
I think maybe you should just defer sending this particular patch upstream until the dependency is worked out.
Brian
Quoted 7 lines
arch/arm64/boot/dts/qcom/sdm845.dtsi +0
-0}; }; };Signature · 2 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project
+ linux-arm-msm, linux-soc
The MSM list should definitely be included for updates to Qualcomm DTS files. Probably linux-soc too, if I'm reading MAINTAINERS correctly.
Brian
Quoted 27 lines · Govind Singh
This series enables ath10k wifi driver support for WCN3990 target on sdm845 SOC. This series also updates the missing dt binding documentation and adds optional iommu property.
sdm845 dtsi changes in this series are based on top of
https://patchwork.kernel.org/cover/10573121/ change.Changes since v1:
Listed no of interrupts/clocks for each set of compatible. Added missing 'wifi' label tosdm845.dtsi.Govind Singh (4):
dt: bindings: add missing dt properties for WCN3990 wifi node
dts: arm64/sdm845: Add WCN3990 WLAN module device node
dt: bindings: add bindings for wifi iommu node
dts: arm64/sdm845: Enable iommu for WCN3990 wifi module device node.../bindings/net/wireless/qcom,ath10k.txt | 34 +++++++++++++++---- arch/arm64/boot/dts/qcom/sdm845-mtp.dts | 7 ++++ arch/arm64/boot/dts/qcom/sdm845.dtsi | 27 +++++++++++++++ 3 files changed, 61 insertions(+), 7 deletions(-)--
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project