[PATCH 3/6] dtc: dt-check-style: Process property names with a question mark

From: Krzysztof Kozlowski

Date: Sat Aug 29 2026 - 15:54:04 EST


Devicetree spec allows question mark '?' in property names and such code
is also accepted by DTC, thus catch such properties as a valid code,
even if discouraged. Otherwise certain rules checking for property
names would ignore that line.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@xxxxxxxxxxxxxxxx>
---
scripts/dtc/dt-check-style | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/dtc/dt-check-style b/scripts/dtc/dt-check-style
index 5385a03f377e..7c3ee1432dc6 100755
--- a/scripts/dtc/dt-check-style
+++ b/scripts/dtc/dt-check-style
@@ -280,7 +280,7 @@ def parse_node_header(dl):


def parse_property_name(dl):
- m = re.match(r'^([a-zA-Z0-9#][a-zA-Z0-9,._+#-]*)\s*[=;]', dl.stripped)
+ m = re.match(r'^([a-zA-Z0-9#][a-zA-Z0-9,._+?#-]*)\s*[=;]', dl.stripped)
if m:
dl.prop_name = m.group(1)


--
2.53.0