[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1622554330.085169.242372.nullmailer@robh.at.kernel.org>
Date: Tue, 01 Jun 2021 08:32:10 -0500
From: Rob Herring <robh@...nel.org>
To: Vladimir Oltean <olteanv@...il.com>
Cc: Rob Herring <robh+dt@...nel.org>,
Florian Fainelli <f.fainelli@...il.com>,
Andrew Lunn <andrew@...n.ch>,
Vladimir Oltean <vladimir.oltean@....com>,
netdev@...r.kernel.org, "David S. Miller" <davem@...emloft.net>,
devicetree@...r.kernel.org,
Vivien Didelot <vivien.didelot@...il.com>,
Jakub Kicinski <kuba@...nel.org>
Subject: Re: [PATCH net-next] dt-bindings: net: dsa: sja1105: convert to YAML schema
On Tue, 01 Jun 2021 02:47:35 +0300, Vladimir Oltean wrote:
> From: Vladimir Oltean <vladimir.oltean@....com>
>
> The following issues exist with the device-specific sja1105,role-mac and
> sja1105,role-phy:
>
> (a) the "sja1105" is not a valid vendor prefix and should probably have
> been "nxp", but
> (b) as per the discussion with Florian here:
> https://lore.kernel.org/netdev/20210201214515.cx6ivvme2tlquge2@skbuf/
> more phy-mode values similar to "revmii" can be added which denote
> that the port is in the role of a PHY (such as "revrmii"), making
> the sja1105,role-phy redundant. Because there are no upstream users
> (or any users at all, to my knowledge) of these properties, they
> could even be removed in a future commit as far as I am concerned.
> (c) when I force-add sja1105,role-phy to a device tree for testing, the
> patternProperties matching does not work, it results in the following
> error:
>
> ethernet-switch@2: ethernet-ports:port@1: 'sja1105,role-phy' does not match any of the regexes: 'pinctrl-[0-9]+'
> From schema: Documentation/devicetree/bindings/net/dsa/nxp,sja1105.yaml
>
> But what's even more interesting is that if I remove the
> "additionalProperties: true" that dsa.yaml has, I get even more
> validation errors coming from patternProperties not matching either,
> from spi-controller.yaml:
>
> ethernet-switch@2: 'compatible', 'mdio', 'reg', 'spi-cpol', 'spi-max-frequency' do not match any of the regexes: '^(ethernet-)?ports$', 'pinctrl-[0-9]+'
>
> So... it is probably broken. Rob Herring says here:
> https://lore.kernel.org/linux-spi/20210324181037.GB3320002@robh.at.kernel.org/
>
> I'm aware of the issue, but I don't have a solution for this situation.
> It's a problem anywhere we have a parent or bus binding defining
> properties for child nodes. For now, I'd just avoid it in the examples
> and we'll figure out how to deal with actual dts files later.
>
> So that's what I did.
>
> Signed-off-by: Vladimir Oltean <vladimir.oltean@....com>
> ---
> .../bindings/net/dsa/nxp,sja1105.yaml | 128 ++++++++++++++
> .../devicetree/bindings/net/dsa/sja1105.txt | 156 ------------------
> 2 files changed, 128 insertions(+), 156 deletions(-)
> create mode 100644 Documentation/devicetree/bindings/net/dsa/nxp,sja1105.yaml
> delete mode 100644 Documentation/devicetree/bindings/net/dsa/sja1105.txt
>
My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
on your patch (DT_CHECKER_FLAGS is new in v5.13):
yamllint warnings/errors:
./Documentation/devicetree/bindings/net/dsa/nxp,sja1105.yaml:65:17: [warning] wrong indentation: expected 14 but found 16 (indentation)
dtschema/dtc warnings/errors:
See https://patchwork.ozlabs.org/patch/1485820
This check can fail if there are any dependencies. The base for a patch
series is generally the most recent rc1.
If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:
pip3 install dtschema --upgrade
Please check and re-submit.
Powered by blists - more mailing lists