From: Simon Polack <spolack+git@mailbox.org>
To: andrew+netdev@lunn.ch, hkallweit1@gmail.com,
linux@armlinux.org.uk, davem@davemloft.net, edumazet@google.com,
kuba@kernel.org, pabeni@redhat.com, robh@kernel.org,
krzk+dt@kernel.org, conor+dt@kernel.org
Cc: f.fainelli@gmail.com, javen_xu@realsil.com.cn, chad@monroe.io,
vladimir.oltean@nxp.com, netdev@vger.kernel.org,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH net-next 1/3] dt-bindings: net: realtek,rtl82xx: Document RTL8261C/D PHYs
Date: Mon, 21 Sep 2026 18:18:15 +0200 [thread overview]
Message-ID: <20260921161817.565185-2-spolack+git@mailbox.org> (raw)
In-Reply-To: <20260921161817.565185-1-spolack+git@mailbox.org>
The RTL8261C/D family reports PHY IDs 0x001cc898 (RTL8261C/D),
0x001cc899 (RTL8261CE) and 0x001cc89a (RTL8261D_VM). Add the three
corresponding compatible strings.
These parts drive four LEDs from the VEND2 LED register block, so allow
the leds node for them the way it is already allowed for the RTL8221B.
They also accept the generic tx-polarity and rx-polarity properties to
invert the host-side SerDes lanes, which is needed on boards that route
the USXGMII lanes inverted between the SoC and the PHY. Reference
phy-common-props.yaml so those properties are described, restrict them
to the compatibles that implement them, and add an example using both.
Signed-off-by: Simon Polack <spolack+git@mailbox.org>
Assisted-by: LLM
---
.../bindings/net/realtek,rtl82xx.yaml | 52 ++++++++++++++++++-
1 file changed, 51 insertions(+), 1 deletion(-)
diff --git a/Documentation/devicetree/bindings/net/realtek,rtl82xx.yaml b/Documentation/devicetree/bindings/net/realtek,rtl82xx.yaml
index 07b39ef1fc62..b21efcb9b255 100644
--- a/Documentation/devicetree/bindings/net/realtek,rtl82xx.yaml
+++ b/Documentation/devicetree/bindings/net/realtek,rtl82xx.yaml
@@ -27,6 +27,9 @@ properties:
- ethernet-phy-id001c.c862
- ethernet-phy-id001c.c878
- ethernet-phy-id001c.c880
+ - ethernet-phy-id001c.c898
+ - ethernet-phy-id001c.c899
+ - ethernet-phy-id001c.c89a
- ethernet-phy-id001c.c910
- ethernet-phy-id001c.c912
- ethernet-phy-id001c.c913
@@ -74,15 +77,35 @@ unevaluatedProperties: false
allOf:
- $ref: ethernet-phy.yaml#
+ - $ref: /schemas/phy/phy-common-props.yaml#
- if:
not:
properties:
compatible:
contains:
- const: ethernet-phy-id001c.c916
+ enum:
+ - ethernet-phy-id001c.c898
+ - ethernet-phy-id001c.c899
+ - ethernet-phy-id001c.c89a
+ - ethernet-phy-id001c.c916
then:
properties:
leds: false
+ - if:
+ not:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - ethernet-phy-id001c.c898
+ - ethernet-phy-id001c.c899
+ - ethernet-phy-id001c.c89a
+ then:
+ properties:
+ rx-polarity: false
+ rx-polarity-names: false
+ tx-polarity: false
+ tx-polarity-names: false
examples:
- |
@@ -96,3 +119,30 @@ examples:
realtek,aldps-enable;
};
};
+
+ - |
+ #include <dt-bindings/leds/common.h>
+ #include <dt-bindings/phy/phy.h>
+
+ mdio {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ ethernet-phy@0 {
+ compatible = "ethernet-phy-id001c.c899";
+ reg = <0>;
+ tx-polarity = <PHY_POL_INVERT>;
+ rx-polarity = <PHY_POL_INVERT>;
+
+ leds {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ led@3 {
+ reg = <3>;
+ color = <LED_COLOR_ID_GREEN>;
+ function = LED_FUNCTION_LAN;
+ };
+ };
+ };
+ };
--
2.55.0
next prev parent reply other threads:[~2026-09-21 16:19 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-21 16:18 [PATCH net-next 0/3] net: phy: realtek: SerDes lane polarity and LEDs for RTL8261C/D Simon Polack
2026-09-21 16:18 ` Simon Polack [this message]
2026-09-21 16:18 ` [PATCH net-next 2/3] net: phy: realtek: apply SerDes lane polarity on RTL8261C/D Simon Polack
2026-09-21 16:18 ` [PATCH net-next 3/3] net: phy: realtek: add LED support for RTL8261C/D Simon Polack
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=20260921161817.565185-2-spolack+git@mailbox.org \
--to=spolack+git@mailbox.org \
--cc=andrew+netdev@lunn.ch \
--cc=chad@monroe.io \
--cc=conor+dt@kernel.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=edumazet@google.com \
--cc=f.fainelli@gmail.com \
--cc=hkallweit1@gmail.com \
--cc=javen_xu@realsil.com.cn \
--cc=krzk+dt@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=robh@kernel.org \
--cc=vladimir.oltean@nxp.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®