* [PATCH] dt-bindings: pwm: Fix cros-ec-pwm example dtc 'reg' warning
@ 2020-04-15 18:26 Rob Herring
2020-04-15 19:29 ` Uwe Kleine-König
0 siblings, 1 reply; 3+ messages in thread
From: Rob Herring @ 2020-04-15 18:26 UTC (permalink / raw)
To: devicetree
Cc: Thierry Reding, Uwe Kleine-König, Benson Leung,
Enric Balletbo i Serra, Guenter Roeck, linux-pwm
The example for the CrOS EC PWM is incomplete and now generates a dtc
warning:
Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.example.dts:17.11-23.11:
Warning (unit_address_vs_reg): /example-0/cros-ec@0: node has a unit name, but no reg or ranges property
Fixing this results in more warnings as a parent spi node is needed as
well.
Cc: Thierry Reding <thierry.reding@gmail.com>
Cc: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
Cc: Benson Leung <bleung@chromium.org>
Cc: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Cc: Guenter Roeck <groeck@chromium.org>
Cc: linux-pwm@vger.kernel.org
Signed-off-by: Rob Herring <robh@kernel.org>
---
.../bindings/pwm/google,cros-ec-pwm.yaml | 17 ++++++++++++-----
1 file changed, 12 insertions(+), 5 deletions(-)
diff --git a/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml b/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml
index 24c217b76580..41ece1d85315 100644
--- a/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml
+++ b/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml
@@ -31,10 +31,17 @@ additionalProperties: false
examples:
- |
- cros-ec@0 {
- compatible = "google,cros-ec-spi";
- cros_ec_pwm: ec-pwm {
- compatible = "google,cros-ec-pwm";
- #pwm-cells = <1>;
+ spi {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ cros-ec@0 {
+ compatible = "google,cros-ec-spi";
+ reg = <0>;
+
+ cros_ec_pwm: ec-pwm {
+ compatible = "google,cros-ec-pwm";
+ #pwm-cells = <1>;
+ };
};
};
--
2.20.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] dt-bindings: pwm: Fix cros-ec-pwm example dtc 'reg' warning
2020-04-15 18:26 [PATCH] dt-bindings: pwm: Fix cros-ec-pwm example dtc 'reg' warning Rob Herring
@ 2020-04-15 19:29 ` Uwe Kleine-König
2020-04-15 20:35 ` Rob Herring
0 siblings, 1 reply; 3+ messages in thread
From: Uwe Kleine-König @ 2020-04-15 19:29 UTC (permalink / raw)
To: Rob Herring
Cc: devicetree, Thierry Reding, Benson Leung, Enric Balletbo i Serra,
Guenter Roeck, linux-pwm
Hello Rob,
On Wed, Apr 15, 2020 at 01:26:39PM -0500, Rob Herring wrote:
> The example for the CrOS EC PWM is incomplete and now generates a dtc
> warning:
>
> Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.example.dts:17.11-23.11:
> Warning (unit_address_vs_reg): /example-0/cros-ec@0: node has a unit name, but no reg or ranges property
>
> Fixing this results in more warnings as a parent spi node is needed as
> well.
>
> Cc: Thierry Reding <thierry.reding@gmail.com>
> Cc: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
> Cc: Benson Leung <bleung@chromium.org>
> Cc: Enric Balletbo i Serra <enric.balletbo@collabora.com>
> Cc: Guenter Roeck <groeck@chromium.org>
> Cc: linux-pwm@vger.kernel.org
> Signed-off-by: Rob Herring <robh@kernel.org>
> ---
> .../bindings/pwm/google,cros-ec-pwm.yaml | 17 ++++++++++++-----
> 1 file changed, 12 insertions(+), 5 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml b/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml
> index 24c217b76580..41ece1d85315 100644
> --- a/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml
> +++ b/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml
> @@ -31,10 +31,17 @@ additionalProperties: false
>
> examples:
> - |
> - cros-ec@0 {
> - compatible = "google,cros-ec-spi";
> - cros_ec_pwm: ec-pwm {
> - compatible = "google,cros-ec-pwm";
> - #pwm-cells = <1>;
> + spi {
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + cros-ec@0 {
> + compatible = "google,cros-ec-spi";
> + reg = <0>;
> +
> + cros_ec_pwm: ec-pwm {
> + compatible = "google,cros-ec-pwm";
> + #pwm-cells = <1>;
> + };
Looks reasonable
Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Is this supposed to go via the pwm tree, or do you apply yourself via a
device-tree tree?
Best regards
Uwe
--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] dt-bindings: pwm: Fix cros-ec-pwm example dtc 'reg' warning
2020-04-15 19:29 ` Uwe Kleine-König
@ 2020-04-15 20:35 ` Rob Herring
0 siblings, 0 replies; 3+ messages in thread
From: Rob Herring @ 2020-04-15 20:35 UTC (permalink / raw)
To: Uwe Kleine-König
Cc: devicetree, Thierry Reding, Benson Leung, Enric Balletbo i Serra,
Guenter Roeck, Linux PWM List
On Wed, Apr 15, 2020 at 2:29 PM Uwe Kleine-König
<u.kleine-koenig@pengutronix.de> wrote:
>
> Hello Rob,
>
> On Wed, Apr 15, 2020 at 01:26:39PM -0500, Rob Herring wrote:
> > The example for the CrOS EC PWM is incomplete and now generates a dtc
> > warning:
> >
> > Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.example.dts:17.11-23.11:
> > Warning (unit_address_vs_reg): /example-0/cros-ec@0: node has a unit name, but no reg or ranges property
> >
> > Fixing this results in more warnings as a parent spi node is needed as
> > well.
> >
> > Cc: Thierry Reding <thierry.reding@gmail.com>
> > Cc: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
> > Cc: Benson Leung <bleung@chromium.org>
> > Cc: Enric Balletbo i Serra <enric.balletbo@collabora.com>
> > Cc: Guenter Roeck <groeck@chromium.org>
> > Cc: linux-pwm@vger.kernel.org
> > Signed-off-by: Rob Herring <robh@kernel.org>
> > ---
> > .../bindings/pwm/google,cros-ec-pwm.yaml | 17 ++++++++++++-----
> > 1 file changed, 12 insertions(+), 5 deletions(-)
> >
> > diff --git a/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml b/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml
> > index 24c217b76580..41ece1d85315 100644
> > --- a/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml
> > +++ b/Documentation/devicetree/bindings/pwm/google,cros-ec-pwm.yaml
> > @@ -31,10 +31,17 @@ additionalProperties: false
> >
> > examples:
> > - |
> > - cros-ec@0 {
> > - compatible = "google,cros-ec-spi";
> > - cros_ec_pwm: ec-pwm {
> > - compatible = "google,cros-ec-pwm";
> > - #pwm-cells = <1>;
> > + spi {
> > + #address-cells = <1>;
> > + #size-cells = <0>;
> > +
> > + cros-ec@0 {
> > + compatible = "google,cros-ec-spi";
> > + reg = <0>;
> > +
> > + cros_ec_pwm: ec-pwm {
> > + compatible = "google,cros-ec-pwm";
> > + #pwm-cells = <1>;
> > + };
>
> Looks reasonable
>
> Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Thanks.
> Is this supposed to go via the pwm tree, or do you apply yourself via a
> device-tree tree?
I'll take it for rc2.
Rob
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-04-15 20:36 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-04-15 18:26 [PATCH] dt-bindings: pwm: Fix cros-ec-pwm example dtc 'reg' warning Rob Herring
2020-04-15 19:29 ` Uwe Kleine-König
2020-04-15 20:35 ` Rob Herring
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).