Skip to content

lopper/assists: Move non-address-mapped subnodes from '/amba_pl' to root #572

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

NavaKishoreManne
Copy link

In the Linux device tree, subnodes within the '/amba_pl' node that lack both 'reg' and 'ranges' properties are considered non-address-mapped.

To prevent device link failures, such subnodes are now relocated to the root node. This applies only to direct children of '/amba_pl' and excludes nodes with '@' in their name or those acting as bus/container nodes (e.g., having multiple subnodes).

This change improves clarity and maintainability by organizing non-address-mapped components at the top level, aligning with device tree best practices.

This logic is applied only when generating Linux device trees (linux_dt=True).

Nava kishore Manne added 2 commits July 16, 2025 17:03
In the Linux device tree, subnodes within the '/amba_pl' node that lack
both 'reg' and 'ranges' properties are considered non-address-mapped.

To prevent device link failures, such subnodes are now relocated to the root
node. This applies only to direct children of '/amba_pl' and excludes nodes
with '@' in their name or those acting as bus/container nodes
(e.g., having multiple subnodes).

This change improves clarity and maintainability by organizing
non-address-mapped components at the top level, aligning with device tree
best practices.

This logic is applied only when generating Linux device trees (linux_dt=True).

Signed-off-by: Nava kishore Manne <nava.kishore.manne@amd.com>
Updates the overlay output file to use the `.dtso` extension (`pl.dtso`)
instead of `.dtsi`. Conceptually, `.dtso` is the appropriate format for
standalone Device Tree overlay sources, which are intended to be compiled
into `.dtbo` binaries. In contrast, `.dtsi` files are meant to be included
in `.dts` files and should not be compiled directly.

This renaming aligns with upstream best practices and avoids confusion
caused by the overloaded use of `pl.dtsi`. It also matches conventions
already adopted in communities such as U-Boot and the Linux kernel.

To ensure backward compatibility with existing workflows, the `pl.dtsi`
file will also continue to be generated for a transitional period.
It will be removed in a future release once downstream consumers have
migrated to using `pl.dtso`.

References:
- U-Boot overlay documentation: https://docs.u-boot.org/en/latest/usage/fdt_overlays.html
- Linux kernel overlay documentation: https://docs.kernel.org/devicetree/overlay-notes.html
- Patch history and rationale: https://lore.kernel.org/all/20221024173434.32518-1-afd@ti.com/

Signed-off-by: Nava kishore Manne <nava.kishore.manne@amd.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant