Skip to content

ipq5018-nss: fix wifi node labels so ipq5018 DTBs build - #121

Open
AugustoAmaral wants to merge 1 commit into
qosmio:main-nssfrom
AugustoAmaral:pr/ipq5018-nss-dtsi-labels
Open

ipq5018-nss: fix wifi node labels so ipq5018 DTBs build#121
AugustoAmaral wants to merge 1 commit into
qosmio:main-nssfrom
AugustoAmaral:pr/ipq5018-nss-dtsi-labels

Conversation

@AugustoAmaral

Copy link
Copy Markdown

The dtsi's three radio-priority blocks reference &wifi0, &wifi1 and &wifi2 (ipq807x radio naming), 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 currently fails on every board that includes the 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

Rather than dropping the annotations, this moves them to where the labels are defined. 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.4 GHz radio keeps priority 0, now via &wifi in ipq5018-nss.dtsi — 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 5 GHz 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 — done for the AX6000 in the follow-up PR.

Note: boards that include ipq5018-qcn6122.dtsi without enabling NSS now carry the property on those nodes as well; it is only read on the NSS path, so it is inert there.

Build tested with dtc on 6.12: all seven affected boards produce a DTB, and gl-b3000 keeps the same three radios at the same priorities as before. Thanks to @LS3434 for pushing back on the earlier version of this patch, which simply removed the blocks.


Re-opened as a new PR: the original was closed automatically by GitHub when my fork got detached. Same content, new fork.

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>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant