On Sun, Nov 03, 2024 at 12:13:04AM +0200, Ivaylo Ivanov wrote: > Convert the Actions Semi Owl timer bindings to DT schema. > > Changes during conversion: > - Rename file to match compatible I do not see any rename happening, anyway, this is not a change to the binding, skip mentioning in changelog. > - Add a description > - Make "clocks" a required property, since the driver searches for it Clocks were not in original binding, so you add clocks in the first place. > - Correct the given example according to owl-s500.dtsi > > Signed-off-by: Ivaylo Ivanov <ivo.ivanov.ivanov1@xxxxxxxxx> > --- > .../bindings/timer/actions,owl-timer.txt | 21 ------ > .../bindings/timer/actions,owl-timer.yaml | 71 +++++++++++++++++++ > MAINTAINERS | 2 +- > 3 files changed, 72 insertions(+), 22 deletions(-) > delete mode 100644 Documentation/devicetree/bindings/timer/actions,owl-timer.txt > create mode 100644 Documentation/devicetree/bindings/timer/actions,owl-timer.yaml > > diff --git a/Documentation/devicetree/bindings/timer/actions,owl-timer.txt b/Documentation/devicetree/bindings/timer/actions,owl-timer.txt > deleted file mode 100644 > index 977054f87..000000000 > --- a/Documentation/devicetree/bindings/timer/actions,owl-timer.txt > +++ /dev/null > @@ -1,21 +0,0 @@ > -Actions Semi Owl Timer > - > -Required properties: > -- compatible : "actions,s500-timer" for S500 > - "actions,s700-timer" for S700 > - "actions,s900-timer" for S900 > -- reg : Offset and length of the register set for the device. > -- interrupts : Should contain the interrupts. > -- interrupt-names : Valid names are: "2hz0", "2hz1", > - "timer0", "timer1", "timer2", "timer3" > - See ../resource-names.txt > - > -Example: > - > - timer@b0168000 { > - compatible = "actions,s500-timer"; > - reg = <0xb0168000 0x100>; > - interrupts = <GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>, > - <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>; > - interrupt-names = "timer0", "timer1"; > - }; > diff --git a/Documentation/devicetree/bindings/timer/actions,owl-timer.yaml b/Documentation/devicetree/bindings/timer/actions,owl-timer.yaml > new file mode 100644 > index 000000000..ed50b4753 > --- /dev/null > +++ b/Documentation/devicetree/bindings/timer/actions,owl-timer.yaml > @@ -0,0 +1,71 @@ > +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/timer/actions,owl-timer.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Actions Semi Owl timer > + > +maintainers: > + - Andreas Färber <afaerber@xxxxxxx> > + > +description: | Do not need '|' unless you need to preserve formatting. > + Actions Semi Owl SoCs provide 32bit and 2Hz timers. > + The 32bit timers support dynamic irq, as well as one-shot mode. > + > +properties: > + compatible: > + enum: > + - actions,s500-timer > + - actions,s700-timer > + - actions,s900-timer > + > + clocks: > + maxItems: 1 > + > + interrupts: > + minItems: 1 > + maxItems: 6 > + > + interrupt-names: > + minItems: 1 > + maxItems: 6 > + items: > + enum: > + - 2hz0 > + - 2hz1 > + - timer0 > + - timer1 > + - timer2 > + - timer3 timer1 is a required property. Above is fine but you need allOf:if:then: block customizing/constraining it per variant. > + > + reg: > + maxItems: 1 > + > +required: > + - compatible > + - clocks > + - interrupts > + - interrupt-names > + - reg > + > +additionalProperties: false Blank line Best regards, Krzysztof