Skip to content

Commit

Permalink
dtb: Fix type collision with "mode-gpios"
Browse files Browse the repository at this point in the history
"mode-gpios" matches on 2 regex's: "^mode-" and "-gpios$". Handle it as
another special case.

Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
  • Loading branch information
robherring committed Nov 15, 2024
1 parent 4f1b8c1 commit cabb5b9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions dtschema/dtb.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,9 @@ def prop_value(validator, nodename, p):
fmt = 'uint32'
else:
fmt = 'phandle-array'
elif p.name == "mode-gpios":
# "mode-gpios" also matches "^mode-" pattern, but it is always a GPIO
fmt = 'phandle-array'
else:
fmt = None
elif len(prop_types) == 1:
Expand Down

0 comments on commit cabb5b9

Please sign in to comment.