ipq5018: enable NSS on Xiaomi AX6000 - #124
Open
AugustoAmaral wants to merge 2 commits into
Open
Conversation
added 2 commits
August 26, 2026 20:00
The three radio-priority blocks at the end of ipq5018-nss.dtsi reference
&wifi0, &wifi1 and &wifi2, and none of the three resolves on ipq5018:
- the internal radio label is &wifi (ipq5018.dtsi), so &wifi0 exists on
no board at all;
- &wifi1/&wifi2 are defined in ipq5018-qcn6122.dtsi, which every board
includes *after* ipq5018-nss.dtsi, and dtc requires a label to be
defined before it is referenced.
So the DTB build fails on every board that includes ipq5018-nss.dtsi:
gl-b3000, wrc-x3000gs2 and, through ipq5018-mx-base.dtsi, mr5500,
mx2000, mx5500, mx6200 and spnmx56.
Error: ipq5018-nss.dtsi:118.1-7 Label or path wifi0 not found
Error: ipq5018-nss.dtsi:123.1-7 Label or path wifi1 not found
Error: ipq5018-nss.dtsi:128.1-7 Label or path wifi2 not found
FATAL ERROR: Syntax error parsing input tree
Move the annotations to where the labels are defined rather than
dropping them: nss-radio-priority is what allocates the wifili thread
scheme in ath11k_nss_pdev_init(), so boards with an offloaded radio do
want it.
- the internal 2.4GHz radio keeps priority 0, now via &wifi in
ipq5018-nss.dtsi, which is the correct label on every ipq5018 board;
- the two QCN6122 instances keep priority 1, set directly in their
nodes in ipq5018-qcn6122.dtsi, so they resolve wherever that dtsi is
included and regardless of include order.
Boards whose 5GHz radio sits on PCIe (QCN9074/QCN9024) have no global
label for it and set nss-radio-priority in their own wifi@0,0 node
instead.
Note that boards including ipq5018-qcn6122.dtsi without enabling NSS now
carry nss-radio-priority on those nodes as well; the property is only
read on the NSS path, so it is inert there.
Build tested with dtc on 6.12: all seven affected boards now produce a
DTB, and gl-b3000 keeps the same three radios at the same priorities as
before.
Signed-off-by: Augusto Amaral <contact@augustoamaral.com>
Include ipq5018-nss.dtsi (nss-common + nss0 nodes and the 16 MB NSS reserved-memory carveout) so the NSS co-processor is wired on the board. The 5 GHz QCN9074 sits on PCIe and therefore has no global label, so it carries nss-radio-priority in its own wifi@0,0 node; the internal 2.4 GHz radio gets priority 0 from ipq5018-nss.dtsi. Also append clk_ignore_unused pd_ignore_unused to bootargs: on ipq5018 the late clk_disable_unused/power-domain gating kills the NSS core (firmware stops responding, offload dead). Workaround until the offending clock is isolated. Known caveat: with the MP NSS firmware requesting GMAC1 descriptors in UTCM_SHARED, the WAN port needs qca-nss-drv loaded with meminfo_user_config="<0, gmac_tx_desc_1, SDRAM>, <0, gmac_rx_desc_1, SDRAM>" or it stays dead bidirectionally. Not included here since the right long-term fix (firmware vs DTS vs module default) deserves its own discussion. Tested on hardware: routed PPPoE offload at ~950 Mbps with 84-95% CPU idle (accelerated_count 11-21, 1.2 GB through the NSS pppoe node, zero drops), 5 GHz QCN9074 and 2.4 GHz radios working. Signed-off-by: Augusto Amaral <contact@augustoamaral.com>
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Includes
ipq5018-nss.dtsion the AX6000 (needs the label fix from #121, which is the first commit here — happy to rebase once that lands) and appendsclk_ignore_unused pd_ignore_unusedto bootargs: late clock/power-domain gating kills the NSS core on ipq5018, a workaround until the offending clock is isolated.The 5 GHz QCN9074 sits on PCIe and therefore has no global label, so it carries
nss-radio-priorityin its ownwifi@0,0node; the internal 2.4 GHz radio gets priority 0 fromipq5018-nss.dtsi.One known caveat, left out of this PR on purpose: the MP NSS firmware requests GMAC1 descriptors in UTCM_SHARED, so the WAN port needs
qca-nss-drvloaded withmeminfo_user_config="<0, gmac_tx_desc_1, SDRAM>, <0, gmac_rx_desc_1, SDRAM>"or it stays dead. I'd rather discuss the right home for that (firmware vs DTS vs module default) than bake it in here.Tested on hardware: routed PPPoE offload at ~950 Mbps with the CPU ~90% idle, both radios up. Details and evidence in #84.
Re-opened as a new PR: the original was closed automatically by GitHub when my fork got detached. Same content, new fork.