From: Rob Herring <robh@kernel.org>
To: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Cc: linux-media@vger.kernel.org, linux-renesas-soc@vger.kernel.org,
"Jacopo Mondi" <jacopo+renesas@jmondi.org>,
"Kieran Bingham" <kieran.bingham+renesas@ideasonboard.com>,
"Niklas Söderlund" <niklas.soderlund+renesas@ragnatech.se>,
"Thomas Nizan" <tnizan@witekio.com>,
"Laurent Pinchart" <laurent.pinchart@ideasonboard.com>,
devicetree@vger.kernel.org
Subject: Re: [PATCH 1/3] dt-bindings: media: i2c: max9286: Add support for per-port supplies
Date: Fri, 17 Dec 2021 08:18:06 -0600 [thread overview]
Message-ID: <YbycHk2r+63PT+kP@robh.at.kernel.org> (raw)
In-Reply-To: <20211216220946.20771-2-laurent.pinchart+renesas@ideasonboard.com>
On Fri, Dec 17, 2021 at 12:09:44AM +0200, Laurent Pinchart wrote:
> From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
>
> Power supplies for the ports can be controlled per port depending on the
> hardware design. Support per-port supplies in the DT bindings, mutually
> exclusive with the global supply.
>
> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> ---
> .../bindings/media/i2c/maxim,max9286.yaml | 25 ++++++++++++++++++-
> 1 file changed, 24 insertions(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/bindings/media/i2c/maxim,max9286.yaml b/Documentation/devicetree/bindings/media/i2c/maxim,max9286.yaml
> index 02f656e78700..33aa307e8ee5 100644
> --- a/Documentation/devicetree/bindings/media/i2c/maxim,max9286.yaml
> +++ b/Documentation/devicetree/bindings/media/i2c/maxim,max9286.yaml
> @@ -39,7 +39,7 @@ properties:
> maxItems: 1
>
> poc-supply:
> - description: Regulator providing Power over Coax to the cameras
> + description: Regulator providing Power over Coax to all the ports
>
> enable-gpios:
> description: GPIO connected to the \#PWDN pin with inverted polarity
> @@ -160,6 +160,10 @@ properties:
>
> additionalProperties: false
>
> +patternProperties:
> + "^port[0-3]-poc-supply$":
> + description: Regulator providing Power over Coax for a particular port
> +
> required:
> - compatible
> - reg
> @@ -167,6 +171,25 @@ required:
> - i2c-mux
> - gpio-controller
>
> +allOf:
> + - if:
> + required:
> + - poc-supply
> + then:
> + allOf:
> + - not:
> + required:
> + - port0-poc-supply
> + - not:
> + required:
> + - port1-poc-supply
> + - not:
> + required:
> + - port2-poc-supply
> + - not:
> + required:
> + - port3-poc-supply
I think you can invert the if and move patternProperties to the 'then'
and...
> +
> additionalProperties: false
then use unevaluatedProperties here.
Rob
next prev parent reply other threads:[~2021-12-17 14:18 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-16 22:09 [PATCH 0/3] media: i2c: max9286: Small new features Laurent Pinchart
2021-12-16 22:09 ` [PATCH 1/3] dt-bindings: media: i2c: max9286: Add support for per-port supplies Laurent Pinchart
2021-12-17 10:47 ` Jacopo Mondi
2021-12-17 15:58 ` Laurent Pinchart
2021-12-17 14:18 ` Rob Herring [this message]
2021-12-17 15:59 ` Laurent Pinchart
2021-12-16 22:09 ` [PATCH 2/3] media: i2c: max9286: Add support for port regulators Laurent Pinchart
2021-12-17 11:08 ` Jacopo Mondi
2021-12-17 16:41 ` Laurent Pinchart
2021-12-17 14:00 ` Jacopo Mondi
2021-12-20 15:06 ` Thomas Nizan
2021-12-20 15:25 ` Laurent Pinchart
2021-12-16 22:09 ` [PATCH 3/3] media: i2c: max9286: Support manual framesync operation Laurent Pinchart
2021-12-17 11:14 ` Jacopo Mondi
2021-12-17 16:05 ` Laurent Pinchart
2021-12-17 17:49 ` Laurent Pinchart
2021-12-20 8:43 ` Jacopo Mondi
2021-12-20 8:45 ` Laurent Pinchart
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=YbycHk2r+63PT+kP@robh.at.kernel.org \
--to=robh@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=jacopo+renesas@jmondi.org \
--cc=kieran.bingham+renesas@ideasonboard.com \
--cc=laurent.pinchart+renesas@ideasonboard.com \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-media@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.org \
--cc=niklas.soderlund+renesas@ragnatech.se \
--cc=tnizan@witekio.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