From: "Marek Behún" <kabel@kernel.org>
To: netdev@vger.kernel.org, Andrew Lunn <andrew@lunn.ch>,
"David S . Miller" <davem@davemloft.net>,
Florian Fainelli <f.fainelli@gmail.com>,
Heiner Kallweit <hkallweit1@gmail.com>,
Russell King <rmk+kernel@armlinux.org.uk>,
Rob Herring <robh@kernel.org>,
devicetree@vger.kernel.org
Cc: "Marek Behún" <kabel@kernel.org>
Subject: [RFC net-next 2/2] dt-bindings: ethernet-phy: define `unsupported-mac-connection-types` property
Date: Mon, 22 Mar 2021 20:50:01 +0100 [thread overview]
Message-ID: <20210322195001.28036-4-kabel@kernel.org> (raw)
In-Reply-To: <20210322195001.28036-1-kabel@kernel.org>
An ethernet PHY may support PHY interface modes that are not wired on a
specific board (or are broken for some other reason). In order for the
kernel to know that these modes should not be used, we need to specify
this in device tree.
Define a new ethernet PHY property `unsupported-mac-connection-types`,
which lists these unsupported modes.
Signed-off-by: Marek Behún <kabel@kernel.org>
---
As in the previous patch: we allow both `phy-connection-type` and
`phy-mode` to define PHY interface mode. Should we call this new
property as it is proposed by this patch, or something different,
like `unsupported-mac-phy-modes`?
Also, some PHYs (marvell10g for example) also multiple units (host
unit for connecting to the MAC, fiber unit for connecting for example
via a SFP). Should we also add `unsupported-fiber-connection-types`
property?
Moreover should this property be a member of PHY's node, or the
ethernet controller's node? Were it a member of ethernet controller's
node, we wouldn't need to $ref a definition from another file's $defs
(which Rob Herring says that so far is done only in withing single
file).
On the other hand `unsupported-fiber-connection-types` property should
be a member of PHY's node, if we will add this in the future.
---
.../devicetree/bindings/net/ethernet-phy.yaml | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/Documentation/devicetree/bindings/net/ethernet-phy.yaml b/Documentation/devicetree/bindings/net/ethernet-phy.yaml
index 2766fe45bb98..4c5b8fabbec3 100644
--- a/Documentation/devicetree/bindings/net/ethernet-phy.yaml
+++ b/Documentation/devicetree/bindings/net/ethernet-phy.yaml
@@ -136,6 +136,20 @@ properties:
used. The absence of this property indicates the muxers
should be configured so that the external PHY is used.
+ unsupported-mac-connection-types:
+ $ref: "ethernet-controller.yaml#/$defs/phy-connection-type-array"
+ description:
+ The PHY device may support different interface types for
+ connecting the Ethernet MAC device to the PHY device (i.e.
+ rgmii, sgmii, xaui, ...), but not all of these interface
+ types must necessarily be supported for a specific board
+ (either not all of them are wired, or there is a known bug
+ for a specific mode).
+ This property specifies a list of interface modes are not
+ supported on the board.
+ minItems: 1
+ maxItems: 128
+
resets:
maxItems: 1
@@ -196,5 +210,6 @@ examples:
reset-gpios = <&gpio1 4 1>;
reset-assert-us = <1000>;
reset-deassert-us = <2000>;
+ unsupported-mac-connection-types = "xaui", "rxaui";
};
};
--
2.26.2
next prev parent reply other threads:[~2021-03-22 19:51 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-22 19:49 [RFC net-next 1/2] dt-bindings: ethernet-controller: create a type for PHY interface modes Marek Behún
2021-03-22 19:49 ` [RFC net-next 2/2] dt-bindings: ethernet-phy: define `unsupported-mac-connection-types` property Marek Behún
2021-03-22 19:56 ` Russell King - ARM Linux admin
2021-03-22 21:11 ` Marek Behún
2021-03-22 19:50 ` [RFC net-next 1/2] dt-bindings: ethernet-controller: create a type for PHY interface modes Marek Behún
2021-03-22 19:50 ` Marek Behún [this message]
2021-03-22 21:11 ` Andrew Lunn
2021-03-23 0:01 ` Marek Behún
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=20210322195001.28036-4-kabel@kernel.org \
--to=kabel@kernel.org \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=f.fainelli@gmail.com \
--cc=hkallweit1@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=rmk+kernel@armlinux.org.uk \
--cc=robh@kernel.org \
/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).