From 88004b2f76d8ac13182639832a96dc6fda99a490 Mon Sep 17 00:00:00 2001 From: David Brown Date: Tue, 1 Jul 2025 12:17:23 -0600 Subject: [PATCH] dt-rust: Fix "Root" node detection The labels node should occur only at the root node in the Rust-converted devicetree. However, when translating the format of the yaml file to use explicit types, the rule for this node didn't end up in an array. It isn't clear why this doesn't generate an error, but making it an explicit array does fix the issue. Without this fix, the devicetree.rs that is generated has a duplicate copy of the labels module under every node. This fixes it to only occur at the top level. Fixes: #113 Signed-off-by: David Brown --- dt-rust.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dt-rust.yaml b/dt-rust.yaml index c1390c7..41bc6ac 100644 --- a/dt-rust.yaml +++ b/dt-rust.yaml @@ -66,6 +66,7 @@ # Generate a pseudo node that matches all of the labels across the tree with their nodes. - name: labels - rules: !Root + rules: + - !Root actions: - !Labels