From: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
To: Marcin Wojtas <mw@semihalf.com>
Cc: "Michał Grzelak" <mig@semihalf.com>,
devicetree@vger.kernel.org, linux@armlinux.org.uk,
davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, robh+dt@kernel.org,
krzysztof.kozlowski+dt@linaro.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org, upstream@semihalf.com
Subject: Re: [PATCH v3 1/3] dt-bindings: net: marvell,pp2: convert to json-schema
Date: Wed, 12 Oct 2022 10:34:40 -0400 [thread overview]
Message-ID: <881e19a9-2e16-7661-0efd-cae7ef1067e7@linaro.org> (raw)
In-Reply-To: <CAPv3WKdon28ntGQ=xbmL+CEFQ7=xzOQOcV9qN_8MOt-uiLHoXg@mail.gmail.com>
On 11/10/2022 19:01, Marcin Wojtas wrote:
,
>>
>> ethernet@
>> {
>> ethernet-port@0
>> {
>> }
>> ethernet-port@1
>> {
>> }
>> }
>>
>> What do you recommend?
>>
>
> I moved the ethernet-controller.yaml reference to under the subnode
> (this allowed me to remove phy and phy-mode description)) and it
> doesn't complain about the node naming. Please let me know if below
> would be acceptable.
>
> --- a/Documentation/devicetree/bindings/net/marvell,pp2.yaml
> +++ b/Documentation/devicetree/bindings/net/marvell,pp2.yaml
> @@ -61,7 +61,11 @@ patternProperties:
> type: object
> description: subnode for each ethernet port.
>
> + allOf:
Skip the allOf, just $ref is enough.
> + - $ref: ethernet-controller.yaml#
> +
> properties:
> interrupts:
> minItems: 1
> maxItems: 10
> @@ -95,19 +99,11 @@ patternProperties:
>
> port-id:
> $ref: /schemas/types.yaml#/definitions/uint32
> + deprecated: true
> description: >
> ID of the port from the MAC point of view.
> Legacy binding for backward compatibility.
>
> - phy:
> - $ref: /schemas/types.yaml#/definitions/phandle
> - description: >
> - a phandle to a phy node defining the PHY address
> - (as the reg property, a single integer).
> -
> - phy-mode:
> - $ref: ethernet-controller.yaml#/properties/phy-mode
> -
> marvell,loopback:
> $ref: /schemas/types.yaml#/definitions/flag
> description: port is loopback mode.
> @@ -132,7 +128,6 @@ required:
> - clock-names
>
> allOf:
> - - $ref: ethernet-controller.yaml#
> - if:
>
Yes, except:
1. top-level (so with no indentation) unevaluatedProperties: false
should be now additionalProperties: false.
2. You need unevaluatedProperties here:
+ type: object
+ description: subnode for each ethernet port.
+ $ref: ethernet-controller.yaml#
+ unevaluatedProperties: false
Best regards,
Krzysztof
next prev parent reply other threads:[~2022-10-12 14:34 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-11 19:06 [PATCH v3 0/3] marvell,pp2.yaml and .dtsi improvements Michał Grzelak
2022-10-11 19:06 ` [PATCH v3 1/3] dt-bindings: net: marvell,pp2: convert to json-schema Michał Grzelak
2022-10-11 19:47 ` Krzysztof Kozlowski
2022-10-11 20:34 ` Marcin Wojtas
2022-10-11 23:01 ` Marcin Wojtas
2022-10-12 14:34 ` Krzysztof Kozlowski [this message]
2022-10-12 14:32 ` Krzysztof Kozlowski
2022-10-11 19:06 ` [PATCH v3 2/3] arm64: dts: marvell: Update network description to match schema Michał Grzelak
2022-10-11 19:06 ` [PATCH v3 3/3] ARM: dts: armada-375: " Michał Grzelak
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=881e19a9-2e16-7661-0efd-cae7ef1067e7@linaro.org \
--to=krzysztof.kozlowski@linaro.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=edumazet@google.com \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=mig@semihalf.com \
--cc=mw@semihalf.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=robh+dt@kernel.org \
--cc=upstream@semihalf.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
all inboxes | Powered by JetHome®