From: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
To: Alexandre Mergnat <amergnat@baylibre.com>, chunkuang.hu@kernel.org
Cc: robh@kernel.org, krzysztof.kozlowski+dt@linaro.org,
conor+dt@kernel.org, p.zabel@pengutronix.de, airlied@gmail.com,
daniel@ffwll.ch, maarten.lankhorst@linux.intel.com,
mripard@kernel.org, tzimmermann@suse.de, matthias.bgg@gmail.com,
shawn.sung@mediatek.com, yu-chang.lee@mediatek.com,
ck.hu@mediatek.com, jitao.shi@mediatek.com,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
dri-devel@lists.freedesktop.org,
linux-mediatek@lists.infradead.org,
linux-arm-kernel@lists.infradead.org, wenst@chromium.org,
kernel@collabora.com
Subject: Re: [PATCH v4 2/3] dt-bindings: arm: mediatek: mmsys: Add OF graph support for board path
Date: Mon, 20 May 2024 12:53:27 +0200 [thread overview]
Message-ID: <7dbe08cf-47a1-4da6-9035-6b0932cf8426@collabora.com> (raw)
In-Reply-To: <ce1de395-3f60-4f7f-9424-bf036134de94@baylibre.com>
Il 19/05/24 19:18, Alexandre Mergnat ha scritto:
> Hi Angelo,
>
> On 16/05/2024 10:11, AngeloGioacchino Del Regno wrote:
>> + oneOf:
>> + - required:
>> + - endpoint@0
>> + - required:
>> + - endpoint@1
>> + - required:
>> + - endpoint@2
>
> I'm not sure this is what you expect because I must remove this part to pass the
> dt-validate.
>
> I have 2 possible display at the same time (DSI and DPI), then I add this in my DTSI:
>
> mmsys: syscon@14000000 {
> compatible = "mediatek,mt8365-mmsys", "syscon";
> reg = <0 0x14000000 0 0x1000>;
> #clock-cells = <1>;
> port {
> #address-cells = <1>;
> #size-cells = <0>;
>
> mmsys_main: endpoint@0 {
> reg = <0>;
> remote-endpoint = <&ovl0_in>;
> };
> mmsys_ext: endpoint@1 {
> reg = <1>;
> remote-endpoint = <&rdma1_in>;
> };
> };
> };
>
> But the DTS check returns me an error:
>
> dt-validate -s Documentation/devicetree/bindings
> arch/arm64/boot/dts/mediatek/mt8365-evk.dtb
> /home/*******/linux-upstream/arch/arm64/boot/dts/mediatek/mt8365-evk.dtb:
> syscon@14000000: port: More than one condition true in oneOf schema:
> {'$ref': '/schemas/graph.yaml#/properties/port',
> 'oneOf': [{'required': ['endpoint@0']},
> {'required': ['endpoint@1']},
> {'required': ['endpoint@2']}],
> 'properties': {'endpoint@0': {'$ref':
> '/schemas/graph.yaml#/properties/endpoint'},
> 'endpoint@1': {'$ref':
> '/schemas/graph.yaml#/properties/endpoint'},
> 'endpoint@2': {'$ref':
> '/schemas/graph.yaml#/properties/endpoint'}}}
> from schema $id:
> http://devicetree.org/schemas/arm/mediatek/mediatek,mmsys.yaml#
>
>
> In other hand, if I use "ports" to keep only one endpoint for each port:
>
> mmsys: syscon@14000000 {
> compatible = "mediatek,mt8365-mmsys", "syscon";
> reg = <0 0x14000000 0 0x1000>;
> #clock-cells = <1>;
> ports {
> #address-cells = <1>;
> #size-cells = <0>;
>
> port@0 {
> #address-cells = <1>;
> #size-cells = <0>;
> reg = <0>;
> mmsys_main: endpoint@0 {
> reg = <0>;
> remote-endpoint = <&ovl0_in>;
> };
> };
>
> port@1 {
> #address-cells = <1>;
> #size-cells = <0>;
> reg = <1>;
> mmsys_ext: endpoint@1 {
> reg = <1>;
> remote-endpoint = <&rdma1_in>;
> };
> };
> };
> };
>
> The DTS check returns another error:
>
> dt-validate -s Documentation/devicetree/bindings
> arch/arm64/boot/dts/mediatek/mt8365-evk.dtb
> /home/*******/linux-upstream/arch/arm64/boot/dts/mediatek/mt8365-evk.dtb:
> syscon@14000000: 'ports' does not match any of the regexes: 'pinctrl-[0-9]+'
> from schema $id:
> http://devicetree.org/schemas/arm/mediatek/mediatek,mmsys.yaml#
>
> Additionally, with the last DTS example, displays aren't working, probably because
> "ports" isn't well parsed.
>
> So, I don't know how you want to manage multiple display, but IMHO there are 2 ways:
> - removing the current "oneOf".
...eh I think this should be anyOf instead :-)
I'll check later and send a v5.
Cheers,
Angelo
> - adding the "ports" support in the documentation and driver (to be parsed).
>
> Still possible I missed something and I doing shit :)
>
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2024-05-20 10:53 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-16 8:11 [PATCH v4 0/3] drm/mediatek: Add support for OF graphs AngeloGioacchino Del Regno
2024-05-16 8:11 ` [PATCH v4 1/3] dt-bindings: display: mediatek: Add OF graph support for board path AngeloGioacchino Del Regno
2024-05-20 15:34 ` Alexandre Mergnat
2024-05-16 8:11 ` [PATCH v4 2/3] dt-bindings: arm: mediatek: mmsys: " AngeloGioacchino Del Regno
2024-05-16 9:23 ` CK Hu (胡俊光)
2024-05-16 9:42 ` AngeloGioacchino Del Regno
2024-05-19 17:18 ` Alexandre Mergnat
2024-05-20 10:53 ` AngeloGioacchino Del Regno [this message]
2024-05-20 11:49 ` Alexandre Mergnat
2024-05-20 11:55 ` AngeloGioacchino Del Regno
2024-05-20 15:33 ` Alexandre Mergnat
2024-05-16 8:11 ` [PATCH v4 3/3] drm/mediatek: Implement OF graphs support for display paths AngeloGioacchino Del Regno
2024-05-17 9:49 ` Michael Walle
2024-05-20 9:45 ` AngeloGioacchino Del Regno
2024-06-03 7:42 ` Michael Walle
2024-05-20 15:34 ` Alexandre Mergnat
2024-06-06 23:25 ` [PATCH v4 0/3] drm/mediatek: Add support for OF graphs Nícolas F. R. A. Prado
2024-06-10 8:39 ` AngeloGioacchino Del Regno
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=7dbe08cf-47a1-4da6-9035-6b0932cf8426@collabora.com \
--to=angelogioacchino.delregno@collabora.com \
--cc=airlied@gmail.com \
--cc=amergnat@baylibre.com \
--cc=chunkuang.hu@kernel.org \
--cc=ck.hu@mediatek.com \
--cc=conor+dt@kernel.org \
--cc=daniel@ffwll.ch \
--cc=devicetree@vger.kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=jitao.shi@mediatek.com \
--cc=kernel@collabora.com \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=matthias.bgg@gmail.com \
--cc=mripard@kernel.org \
--cc=p.zabel@pengutronix.de \
--cc=robh@kernel.org \
--cc=shawn.sung@mediatek.com \
--cc=tzimmermann@suse.de \
--cc=wenst@chromium.org \
--cc=yu-chang.lee@mediatek.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