Message ID | 20250324100008.346009-1-daniel.lezcano@linaro.org (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | [1/2] dt-bindings: NXP System Timer Module | expand |
On Mon, 24 Mar 2025 11:00:05 +0100, Daniel Lezcano wrote: > Add the System Timer Module description found on the NXP s32 platform > and the compatible for the s32g2 variant. > > Cc: Ghennadi Procopciuc <ghennadi.procopciuc@oss.nxp.com> > Cc: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Cc: Thomas Fossati <thomas.fossati@linaro.org> > Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> > --- > .../bindings/timer/nxp,stm-timer.yaml | 59 +++++++++++++++++++ > 1 file changed, 59 insertions(+) > create mode 100644 Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml > My bot found errors running 'make dt_binding_check' on your patch: yamllint warnings/errors: dtschema/dtc warnings/errors: /builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/timer/nxp,stm-timer.example.dtb: stm@4011c000: compatible: ['nxp,s32g2-stm'] is valid under each of {'items': [{'const': 'nxp,s32g2-stm'}], 'type': 'array', 'minItems': 1, 'maxItems': 1}, {'items': [{'const': 'nxp,s32g2-stm'}], 'type': 'array', 'minItems': 1, 'maxItems': 1} from schema $id: http://devicetree.org/schemas/timer/nxp,stm-timer.yaml# doc reference errors (make refcheckdocs): See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20250324100008.346009-1-daniel.lezcano@linaro.org The base for the series is generally the latest rc1. A different dependency should be noted in *this* patch. If you already ran 'make dt_binding_check' and didn't see the above error(s), then make sure 'yamllint' is installed and dt-schema is up to date: pip3 install dtschema --upgrade Please check and re-submit after running the above command yourself. Note that DT_SCHEMA_FILES can be set to your schema file to speed up checking your schema. However, it must be unset to test all examples with your schema.
On 24/03/2025 11:00, Daniel Lezcano wrote: > Add the System Timer Module description found on the NXP s32 platform > and the compatible for the s32g2 variant. subject: dt-bindings: timer: Add NXP ....... > > Cc: Ghennadi Procopciuc <ghennadi.procopciuc@oss.nxp.com> > Cc: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Cc: Thomas Fossati <thomas.fossati@linaro.org> > Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> > --- > .../bindings/timer/nxp,stm-timer.yaml | 59 +++++++++++++++++++ > 1 file changed, 59 insertions(+) > create mode 100644 Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml > > diff --git a/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml b/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml > new file mode 100644 > index 000000000000..41093892c617 > --- /dev/null > +++ b/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml > @@ -0,0 +1,59 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/timer/nxp,stm-timer.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: NXP System Timer Module (STM) > + > +maintainers: > + - Daniel Lezcano <daniel.lezcano@kernel.org> > + > +description: | Do not need '|' unless you need to preserve formatting. > + The System Timer Module supports commonly required system and > + application software timing functions. STM includes a 32-bit > + count-up timer and four 32-bit compare channels with a separate > + interrupt source for each channel. The timer is driven by the STM > + module clock divided by an 8-bit prescale value. > + > +properties: > + compatible: > + oneOf: That's pointless - you have only one. > + - const: nxp,s32g2-stm Keep this > + - items: > + - const: nxp,s32g2-stm Drop this and oneOf. Unless you wanted more devices, but then it is incomplete. Best regards, Krzysztof
On Mon, Mar 24, 2025 at 11:00:05AM +0100, Daniel Lezcano wrote: > Add the System Timer Module description found on the NXP s32 platform > and the compatible for the s32g2 variant. > > Cc: Ghennadi Procopciuc <ghennadi.procopciuc@oss.nxp.com> > Cc: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Cc: Thomas Fossati <thomas.fossati@linaro.org> > Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> > --- > .../bindings/timer/nxp,stm-timer.yaml | 59 +++++++++++++++++++ > 1 file changed, 59 insertions(+) > create mode 100644 Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml > > diff --git a/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml b/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml > new file mode 100644 > index 000000000000..41093892c617 > --- /dev/null > +++ b/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml > @@ -0,0 +1,59 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/timer/nxp,stm-timer.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: NXP System Timer Module (STM) > + > +maintainers: > + - Daniel Lezcano <daniel.lezcano@kernel.org> > + > +description: | Don't need '|' and wrap at 80 char. > + The System Timer Module supports commonly required system and > + application software timing functions. STM includes a 32-bit > + count-up timer and four 32-bit compare channels with a separate > + interrupt source for each channel. The timer is driven by the STM > + module clock divided by an 8-bit prescale value. > + > +properties: > + compatible: > + oneOf: > + - const: nxp,s32g2-stm > + - items: > + - const: nxp,s32g2-stm > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 1 > + > + clocks: > + items: > + - description: System Timer Module clock Just 'maxItems: 1'. The description is rather obvious. > + > + clock-names: > + items: > + - const: stm No need for *-names when there is only 1 entry. > + > +required: > + - compatible > + - reg > + - interrupts > + - clocks > + - clock-names > + > +additionalProperties: false > + > +examples: > + - | > + #include <dt-bindings/interrupt-controller/arm-gic.h> > + > + stm@4011c000 { timer@... > + compatible = "nxp,s32g2-stm"; > + reg = <0x4011c000 0x3000>; > + interrupts = <GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH>; > + clocks = <&clks 0x3b>; > + clock-names = "stm"; > + }; > -- > 2.43.0 >
On 3/24/2025 12:00 PM, Daniel Lezcano wrote: > Add the System Timer Module description found on the NXP s32 platform > and the compatible for the s32g2 variant. > > Cc: Ghennadi Procopciuc <ghennadi.procopciuc@oss.nxp.com> > Cc: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > Cc: Thomas Fossati <thomas.fossati@linaro.org> > Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> > --- > .../bindings/timer/nxp,stm-timer.yaml | 59 +++++++++++++++++++ > 1 file changed, 59 insertions(+) > create mode 100644 Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml > > diff --git a/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml b/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml > new file mode 100644 > index 000000000000..41093892c617 > --- /dev/null > +++ b/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml > @@ -0,0 +1,59 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/timer/nxp,stm-timer.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: NXP System Timer Module (STM) > + > +maintainers: > + - Daniel Lezcano <daniel.lezcano@kernel.org> > + > +description: | > + The System Timer Module supports commonly required system and > + application software timing functions. STM includes a 32-bit > + count-up timer and four 32-bit compare channels with a separate > + interrupt source for each channel. The timer is driven by the STM > + module clock divided by an 8-bit prescale value. > + Please update the description, as this one refers to STM instead of SWT.
On 3/31/2025 1:49 PM, Ghennadi Procopciuc wrote: > On 3/24/2025 12:00 PM, Daniel Lezcano wrote: >> Add the System Timer Module description found on the NXP s32 platform >> and the compatible for the s32g2 variant. >> >> Cc: Ghennadi Procopciuc <ghennadi.procopciuc@oss.nxp.com> >> Cc: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> >> Cc: Thomas Fossati <thomas.fossati@linaro.org> >> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> >> --- >> .../bindings/timer/nxp,stm-timer.yaml | 59 +++++++++++++++++++ >> 1 file changed, 59 insertions(+) >> create mode 100644 Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml >> >> diff --git a/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml b/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml >> new file mode 100644 >> index 000000000000..41093892c617 >> --- /dev/null >> +++ b/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml >> @@ -0,0 +1,59 @@ >> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) >> +%YAML 1.2 >> +--- >> +$id: http://devicetree.org/schemas/timer/nxp,stm-timer.yaml# >> +$schema: http://devicetree.org/meta-schemas/core.yaml# >> + >> +title: NXP System Timer Module (STM) >> + >> +maintainers: >> + - Daniel Lezcano <daniel.lezcano@kernel.org> >> + >> +description: | >> + The System Timer Module supports commonly required system and >> + application software timing functions. STM includes a 32-bit >> + count-up timer and four 32-bit compare channels with a separate >> + interrupt source for each channel. The timer is driven by the STM >> + module clock divided by an 8-bit prescale value. >> + > > Please update the description, as this one refers to STM instead of SWT. > Please disregard this message; it's in the wrong thread.
diff --git a/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml b/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml new file mode 100644 index 000000000000..41093892c617 --- /dev/null +++ b/Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml @@ -0,0 +1,59 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/timer/nxp,stm-timer.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: NXP System Timer Module (STM) + +maintainers: + - Daniel Lezcano <daniel.lezcano@kernel.org> + +description: | + The System Timer Module supports commonly required system and + application software timing functions. STM includes a 32-bit + count-up timer and four 32-bit compare channels with a separate + interrupt source for each channel. The timer is driven by the STM + module clock divided by an 8-bit prescale value. + +properties: + compatible: + oneOf: + - const: nxp,s32g2-stm + - items: + - const: nxp,s32g2-stm + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + clocks: + items: + - description: System Timer Module clock + + clock-names: + items: + - const: stm + +required: + - compatible + - reg + - interrupts + - clocks + - clock-names + +additionalProperties: false + +examples: + - | + #include <dt-bindings/interrupt-controller/arm-gic.h> + + stm@4011c000 { + compatible = "nxp,s32g2-stm"; + reg = <0x4011c000 0x3000>; + interrupts = <GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&clks 0x3b>; + clock-names = "stm"; + };
Add the System Timer Module description found on the NXP s32 platform and the compatible for the s32g2 variant. Cc: Ghennadi Procopciuc <ghennadi.procopciuc@oss.nxp.com> Cc: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Cc: Thomas Fossati <thomas.fossati@linaro.org> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> --- .../bindings/timer/nxp,stm-timer.yaml | 59 +++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 Documentation/devicetree/bindings/timer/nxp,stm-timer.yaml