devicetree-org / dt-schema

Devicetree schema tools
http://www.devicetree.org
BSD 2-Clause "Simplified" License
67 stars 67 forks source link

Non-MMIO interrupt-controller nodes are illegal #104

Closed konradybcio closed 1 year ago

konradybcio commented 1 year ago

Currently, /schemas/interrupt-controller.yaml allows the node names to match:

"^interrupt-controller(@[0-9a-f,]+)*$"

Which means that for non-MMIO-mapped nodes we can only use interrupt-controller.

But then, a property with an identical name (interrupt-controller;) is required.

Trying to create such a node emits a warning in dtc:

Warning (node_name_vs_property_name): /example-0/interrupt-controller: node name and property name conflict

krzk commented 1 year ago

You mix now two things. The warning is about parent node having interrupt-controller property and a node. It's not about having a interrupt-controller property needed in your device node (although it is needed, but warning is not about it).

robherring commented 1 year ago

Our choices are relax the naming (with "interrupt-controller-[0-9]+") or rework the example template causing this. I don't think the pattern (having both interrupt-controller as node and property) is likely in a real DT, so I'm going with the latter. I have a fix I'm testing now.

robherring commented 1 year ago

Fixed in v2023.04