From: Vladimir Oltean <olteanv@gmail.com>
To: Rob Herring <robh@kernel.org>
Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
Damien Le Moal <damien.lemoal@opensource.wdc.com>,
Herbert Xu <herbert@gondor.apana.org.au>,
"David S. Miller" <davem@davemloft.net>,
Chun-Kuang Hu <chunkuang.hu@kernel.org>,
Philipp Zabel <p.zabel@pengutronix.de>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>,
Vinod Koul <vkoul@kernel.org>, Georgi Djakov <djakov@kernel.org>,
Thomas Gleixner <tglx@linutronix.de>,
Marc Zyngier <maz@kernel.org>, Joerg Roedel <joro@8bytes.org>,
Lee Jones <lee.jones@linaro.org>,
Daniel Thompson <daniel.thompson@linaro.org>,
Jingoo Han <jingoohan1@gmail.com>, Pavel Machek <pavel@ucw.cz>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>,
Jakub Kicinski <kuba@kernel.org>,
Wolfgang Grandegger <wg@grandegger.com>,
Marc Kleine-Budde <mkl@pengutronix.de>,
Andrew Lunn <andrew@lunn.ch>,
Vivien Didelot <vivien.didelot@gmail.com>,
Florian Fainelli <f.fainelli@gmail.com>,
Kalle Valo <kvalo@kernel.org>, Viresh Kumar <vireshk@kernel.org>,
Stephen Boyd <sboyd@kernel.org>,
Kishon Vijay Abraham I <kishon@ti.com>,
Linus Walleij <linus.walleij@linaro.org>,
"Rafael J. Wysocki" <rafael@kernel.org>,
Kevin Hilman <khilman@kernel.org>,
Ulf Hansson <ulf.hansson@linaro.org>,
Sebastian Reichel <sre@kernel.org>,
Mark Brown <broonie@kernel.org>,
Mathieu Poirier <mathieu.poirier@linaro.org>,
Daniel Lezcano <daniel.lezcano@linaro.org>,
Zhang Rui <rui.zhang@intel.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Thierry Reding <thierry.reding@gmail.com>,
Jonathan Hunter <jonathanh@nvidia.com>,
Sudeep Holla <sudeep.holla@arm.com>,
Geert Uytterhoeven <geert+renesas@glider.be>,
linux-ide@vger.kernel.org, linux-crypto@vger.kernel.org,
dri-devel@lists.freedesktop.org, dmaengine@vger.kernel.org,
linux-pm@vger.kernel.org, iommu@lists.linux-foundation.org,
linux-leds@vger.kernel.org, linux-media@vger.kernel.org,
netdev@vger.kernel.org, linux-can@vger.kernel.org,
linux-wireless@vger.kernel.org, linux-phy@lists.infradead.org,
linux-gpio@vger.kernel.org, linux-riscv@lists.infradead.org,
linux-remoteproc@vger.kernel.org, alsa-devel@alsa-project.org,
linux-usb@vger.kernel.org
Subject: Re: [PATCH] dt-bindings: Improve phandle-array schemas
Date: Wed, 19 Jan 2022 12:35:42 +0200 [thread overview]
Message-ID: <20220119103542.el3yuqds6ihpkthn@skbuf> (raw)
In-Reply-To: <20220119015038.2433585-1-robh@kernel.org>
On Tue, Jan 18, 2022 at 07:50:38PM -0600, Rob Herring wrote:
> The 'phandle-array' type is a bit ambiguous. It can be either just an
> array of phandles or an array of phandles plus args. Many schemas for
> phandle-array properties aren't clear in the schema which case applies
> though the description usually describes it.
>
> The array of phandles case boils down to needing:
>
> items:
> maxItems: 1
>
> The phandle plus args cases should typically take this form:
>
> items:
> - items:
> - description: A phandle
> - description: 1st arg cell
> - description: 2nd arg cell
>
> With this change, some examples need updating so that the bracketing of
> property values matches the schema.
> ---
(...)
> diff --git a/Documentation/devicetree/bindings/net/dsa/dsa-port.yaml b/Documentation/devicetree/bindings/net/dsa/dsa-port.yaml
> index 702df848a71d..c504feeec6db 100644
> --- a/Documentation/devicetree/bindings/net/dsa/dsa-port.yaml
> +++ b/Documentation/devicetree/bindings/net/dsa/dsa-port.yaml
> @@ -34,6 +34,8 @@ properties:
> full routing information must be given, not just the one hop
> routes to neighbouring switches
> $ref: /schemas/types.yaml#/definitions/phandle-array
> + items:
> + maxItems: 1
>
> ethernet:
> description:
For better or worse, the mainline cases of this property all take the
form of:
arch/arm64/boot/dts/marvell/armada-3720-turris-mox.dts
link = <&switch1port9 &switch2port9>;
link = <&switch1port10 &switch0port10>;
arch/arm/boot/dts/vf610-zii-dev-rev-b.dts
link = <&switch1port6
&switch2port9>;
link = <&switch1port5
&switch0port5>;
arch/arm/boot/dts/vf610-zii-scu4-aib.dts
link = <&switch1port10
&switch3port10
&switch2port10>;
link = <&switch3port10
&switch2port10>;
link = <&switch1port9
&switch0port10>;
So not really an array of phandles.
next prev parent reply other threads:[~2022-01-19 10:35 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-19 1:50 [PATCH] dt-bindings: Improve phandle-array schemas Rob Herring
2022-01-19 7:40 ` Krzysztof Kozlowski
2022-01-19 7:44 ` Viresh Kumar
2022-01-19 8:24 ` Greg Kroah-Hartman
2022-01-19 9:42 ` Geert Uytterhoeven
2022-01-19 10:31 ` Ulf Hansson
2022-01-19 10:35 ` Vladimir Oltean [this message]
2022-01-19 15:28 ` Rob Herring
2022-01-19 12:09 ` Georgi Djakov
2022-01-19 15:21 ` Arnaud POULIQUEN
2022-01-19 15:30 ` Rob Herring
2022-01-19 15:45 ` Mark Brown
2022-01-20 4:38 ` Vinod Koul
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220119103542.el3yuqds6ihpkthn@skbuf \
--to=olteanv@gmail.com \
--cc=alsa-devel@alsa-project.org \
--cc=andrew@lunn.ch \
--cc=broonie@kernel.org \
--cc=chunkuang.hu@kernel.org \
--cc=damien.lemoal@opensource.wdc.com \
--cc=daniel.lezcano@linaro.org \
--cc=daniel.thompson@linaro.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=djakov@kernel.org \
--cc=dmaengine@vger.kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=f.fainelli@gmail.com \
--cc=geert+renesas@glider.be \
--cc=gregkh@linuxfoundation.org \
--cc=herbert@gondor.apana.org.au \
--cc=iommu@lists.linux-foundation.org \
--cc=jingoohan1@gmail.com \
--cc=jonathanh@nvidia.com \
--cc=joro@8bytes.org \
--cc=khilman@kernel.org \
--cc=kieran.bingham+renesas@ideasonboard.com \
--cc=kishon@ti.com \
--cc=krzysztof.kozlowski@canonical.com \
--cc=kuba@kernel.org \
--cc=kvalo@kernel.org \
--cc=laurent.pinchart@ideasonboard.com \
--cc=lee.jones@linaro.org \
--cc=linus.walleij@linaro.org \
--cc=linux-can@vger.kernel.org \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-ide@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-leds@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-phy@lists.infradead.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux-remoteproc@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=linux-usb@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=mathieu.poirier@linaro.org \
--cc=maz@kernel.org \
--cc=mchehab@kernel.org \
--cc=mkl@pengutronix.de \
--cc=netdev@vger.kernel.org \
--cc=p.zabel@pengutronix.de \
--cc=pavel@ucw.cz \
--cc=rafael@kernel.org \
--cc=robh@kernel.org \
--cc=rui.zhang@intel.com \
--cc=sboyd@kernel.org \
--cc=sre@kernel.org \
--cc=sudeep.holla@arm.com \
--cc=tglx@linutronix.de \
--cc=thierry.reding@gmail.com \
--cc=ulf.hansson@linaro.org \
--cc=vireshk@kernel.org \
--cc=vivien.didelot@gmail.com \
--cc=vkoul@kernel.org \
--cc=wg@grandegger.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).