From: Marek Vasut <marex@denx.de>
To: Benjamin MUGNIER <benjamin.mugnier@foss.st.com>,
linux-arm-kernel@lists.infradead.org
Cc: Alexandre Torgue <alexandre.torgue@foss.st.com>,
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Maxime Coquelin <mcoquelin.stm32@gmail.com>,
Rob Herring <robh+dt@kernel.org>,
Sylvain Petinot <sylvain.petinot@foss.st.com>,
devicetree@vger.kernel.org, linux-media@vger.kernel.org,
linux-stm32@st-md-mailman.stormreply.com
Subject: Re: [PATCH] dt-bindings: media: st,stmipid02: Convert the text bindings to YAML
Date: Tue, 27 Sep 2022 20:45:01 +0200 [thread overview]
Message-ID: <162ea4dd-ded9-2905-0e4b-71809c95fd78@denx.de> (raw)
In-Reply-To: <7420b97c-1421-03a5-dd47-044b5e1739f1@foss.st.com>
On 9/27/22 13:06, Benjamin MUGNIER wrote:
> Hi Marek,
Hi,
> Thank you for your patch.
Thank you for the review.
[...]
>> +++ b/Documentation/devicetree/bindings/media/i2c/st,st-mipid02.yaml
>> @@ -0,0 +1,175 @@
>> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
>> +%YAML 1.2
>> +---
>> +$id: http://devicetree.org/schemas/media/i2c/st,st-mipid02.yaml#
>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>> +
>> +title: STMicroelectronics MIPID02 CSI-2 to PARALLEL bridge
>> +
>> +maintainers:
>> + - Mickael Guene <mickael.guene@foss.st.com>
>
> As Mickael is not the maintainer of the driver anymore, there should be both current maintainers instead, as listed in the MAINTAINER file:
> - Benjamin Mugnier <benjamin.mugnier@foss.st.com>
> - Sylvain Petinot <sylvain.petinot@foss.st.com>
> Can you change it while at it ? Thank you.
Done and done, I also dropped myself from the list, which I hope is OK.
> By the way you will also need to update the MAINTAINERS file to change the st,st-mipid02.txt file to st,st-mipid02.yaml here:
> F: Documentation/devicetree/bindings/media/i2c/st,st-mipid02.txt
[...]
>> + port@2:
>> + $ref: /schemas/graph.yaml#/$defs/port-base
>> + unevaluatedProperties: false
>> + description: Output port
>> + properties:
>> + endpoint:
>> + $ref: /schemas/media/video-interfaces.yaml#
>> + unevaluatedProperties: false
>> +
>> + properties:
>> + bus-width:
>> + enum: [8, 10, 12, 14]
>
> Shouldn't this be [6, 8, 10, 12] as in the original file ?
They are both wrong, per:
https://www.st.com/resource/en/datasheet/stmipid02.pdf
page 5
Table 1. Image format vs. number of bits on output interface
row 2
RAW7 RAW7 7 bits
So this should be
[6, 7, 8, 10, 12]
>> + default: 8
>
> As far as I understand there is no 'default' as this property is required anyway.
Dropped.
>> + hsync-active: true
>> + vsync-active: true
>> +
>> + required:
>> + - bus-width
>> +
>> + required:
>> + - port@0
>
> Actually it could either be port0 or port1, but not both at the same time, see the 'description' part.
> I'm not sure how to describe it in device tree binding though.
I think the requirement here is to have at least one of port@0 or port@1
described in DT. Both port@0 and port@1 can also be described, i.e. you
can have FRONT and BACK sensor like on a contemporary smartphone, you
just cannot start streaming from both sensors at the same time, which is
a software policy and should be handled by the driver.
See:
https://www.st.com/resource/en/datasheet/stmipid02.pdf
page 3
2 Application diagrams
Figure 2. MIPI CSI-2 application diagram
Per suggestion from Rob, I think this should be
allOf:
- require:
- port@0
- require:
- port@1
require:
- port@2
>> + - port@2
>> +
>> +additionalProperties: false
>> +
>> +required:
>> + - compatible
>> + - reg
>
> I noticed this was missing in the original txt file. Thanks for taking care of it.
Sure. I'm glad to see dtbs_check passing on the stm32mp15xx boards,
largely thanks to ST doing good job keeping the upstream support in good
shape.
next prev parent reply other threads:[~2022-09-27 18:45 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-27 0:55 [PATCH] dt-bindings: media: st,stmipid02: Convert the text bindings to YAML Marek Vasut
2022-09-27 11:06 ` Benjamin MUGNIER
2022-09-27 18:45 ` Marek Vasut [this message]
2022-09-28 8:08 ` Benjamin MUGNIER
2022-09-28 13:32 ` Marek Vasut
2022-09-27 18:00 ` kernel test robot
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=162ea4dd-ded9-2905-0e4b-71809c95fd78@denx.de \
--to=marex@denx.de \
--cc=alexandre.torgue@foss.st.com \
--cc=benjamin.mugnier@foss.st.com \
--cc=devicetree@vger.kernel.org \
--cc=krzysztof.kozlowski@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-stm32@st-md-mailman.stormreply.com \
--cc=mchehab@kernel.org \
--cc=mcoquelin.stm32@gmail.com \
--cc=robh+dt@kernel.org \
--cc=sylvain.petinot@foss.st.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).