[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230607073652.hoyrernfcuoryrqs@pengutronix.de>
Date: Wed, 7 Jun 2023 09:36:52 +0200
From: Uwe Kleine-König <u.kleine-koenig@...gutronix.de>
To: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
Cc: Vinod Koul <vkoul@...nel.org>,
Kishon Vijay Abraham I <kishon@...nel.org>,
Rob Herring <robh+dt@...nel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
Conor Dooley <conor+dt@...nel.org>,
Thierry Reding <thierry.reding@...il.com>,
Alessandro Zummo <a.zummo@...ertech.it>,
Alexandre Belloni <alexandre.belloni@...tlin.com>,
Srinivas Kandagatla <srinivas.kandagatla@...aro.org>,
Mark Brown <broonie@...nel.org>,
Dipen Patel <dipenp@...dia.com>,
Wim Van Sebroeck <wim@...ux-watchdog.org>,
Guenter Roeck <linux@...ck-us.net>,
Dilip Kota <eswara.kota@...ux.intel.com>,
linux-phy@...ts.infradead.org, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-pwm@...r.kernel.org,
linux-rtc@...r.kernel.org, alsa-devel@...a-project.org,
linux-spi@...r.kernel.org, timestamp@...ts.linux.dev,
linux-watchdog@...r.kernel.org, Rob Herring <robh@...nel.org>,
Tony Lindgren <tony@...mide.com>,
Oleksij Rempel <o.rempel@...gutronix.de>
Subject: Re: [PATCH 2/7] dt-bindings: pwm: restrict node name suffixes
On Tue, May 30, 2023 at 04:48:46PM +0200, Krzysztof Kozlowski wrote:
> Make the pattern matching node names a bit stricter to improve DTS
> consistency. The pattern is restricted to:
> 1. Only one unit address or one -N suffix,
> 2. -N suffixes to decimal numbers.
>
> Suggested-by: Rob Herring <robh@...nel.org>
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
>
> ---
>
> Cc: Tony Lindgren <tony@...mide.com>
> Cc: Oleksij Rempel <o.rempel@...gutronix.de>
> ---
> Documentation/devicetree/bindings/pwm/pwm.yaml | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/bindings/pwm/pwm.yaml b/Documentation/devicetree/bindings/pwm/pwm.yaml
> index 3c01f85029e5..abd9fa873354 100644
> --- a/Documentation/devicetree/bindings/pwm/pwm.yaml
> +++ b/Documentation/devicetree/bindings/pwm/pwm.yaml
> @@ -13,7 +13,7 @@ select: false
>
> properties:
> $nodename:
> - pattern: "^pwm(@.*|-[0-9a-f])*$"
> + pattern: "^pwm(@.*|-([0-9]|[1-9][0-9]+))?$"
With this patch we forbid now the following patterns:
pwm-[0-9a-f][@-].*
pwm-0[0-9a-f]+
pwm-[a-f]([@-].*)?
Checking for such names:
$ git grep -oP '\bpwm-([0-9a-f][@-].*|0[0-9a-f]+|[0-9]*[a-f][0-9a-f]*)(*pla:\s*\{)' arch/*/boot/dts
arch/arm/boot/dts/meson8.dtsi:pwm-f-ao
arch/arm/boot/dts/meson8.dtsi:pwm-e
arch/arm/boot/dts/meson8b.dtsi:pwm-d
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-a
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-b-x7
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-b-x19
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-c-c
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-c-x5
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-c-x8
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-d-x3
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-d-x6
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-e
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-f-z
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-f-a
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-f-x
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-f-h
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi:pwm-a-e
These are all pinmux-settings and no pwm nodes, so the change is fine.
(But arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi isn't properly
sorted alphabetically.)
Reviewed-by: Uwe Kleine-König <u.kleine-koenig@...gutronix.de>
Best regards and Thanks
Uwe
--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)
Powered by blists - more mailing lists