Skip to content

Commit d921320

Browse files
committed
zephyr: devicetree: Allow non-snake-case names in DT nodes
DT nodes that have addresses with hex letters in them will generate names with capital letters inside the name, which will trigger the `non_snake_case` lint in the compiler. Pre-emptively allow these names in the devicetree, as this will show up as new targets are added. Signed-off-by: David Brown <[email protected]>
1 parent 14618bd commit d921320

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

zephyr/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,9 @@ pub mod devicetree {
131131
132132
// Don't enforce doc comments on the generated device tree.
133133
#![allow(missing_docs)]
134+
// Allow nodes to have non-snake-case names. This comes from addresses in the node names, which
135+
// usually use uppercase.
136+
#![allow(non_snake_case)]
134137

135138
include!(concat!(env!("OUT_DIR"), "/devicetree.rs"));
136139
}

0 commit comments

Comments
 (0)