mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
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 0/3] net: phy: realtek: SerDes lane polarity and LEDs for RTL8261C/D
Date: Mon, 21 Sep 2026 18:18:14 +0200	[thread overview]
Message-ID: <20260921161817.565185-1-spolack+git@mailbox.org> (raw)

The RTL8261CE on the Gemtek W1700K (Airoha AN7581) binds, but the 10G
ports don't come up: the board routes the USXGMII lanes inverted and the
driver never applies tx-polarity/rx-polarity from the device tree.
Patch 2 fixes that; the link then comes up at 1G and 10G.

The inversion is done in the PHY because the AN7581 PCS has no known
polarity control - nor does its MT7988 XFI T-PHY sibling - and Airoha's
own EN8811H driver handles it the same way.

Patch 3 is Chad Monroe's LED support, rebased onto the merged driver
with the RTL822X_VND2 LED definitions reused and a polarity bit fix.
Patch 1 adds the bindings for both.

Tested on an RTL8261CE (W1700K). Polarity is applied unchanged to the
RTL8261C, RTL8261D and RTL8261D_VM, which share config_init() but are
untested with inverted lanes. LEDs were also tested on RTL8261C
and RTL8261D boards.

The LED callbacks duplicate rtl822xb_led_*(); sharing the code means
touching the RTL8221B path, so that is left for a follow-up.

An LLM assistant (Claude) was used for rebasing, restructuring and the
changelogs. The register usage comes from existing driver sources and
was verified on hardware; the code has been reviewed by me.

Chad Monroe (1):
  net: phy: realtek: add LED support for RTL8261C/D

Simon Polack (2):
  dt-bindings: net: realtek,rtl82xx: Document RTL8261C/D PHYs
  net: phy: realtek: apply SerDes lane polarity on RTL8261C/D

 .../bindings/net/realtek,rtl82xx.yaml         |  52 ++-
 drivers/net/phy/realtek/Kconfig               |   1 +
 drivers/net/phy/realtek/realtek_main.c        | 402 ++++++++++++++++--
 3 files changed, 427 insertions(+), 28 deletions(-)


base-commit: 8830e65ed46de41f849eefb8ba227d4852c460f6
-- 
2.55.0


             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 Simon Polack [this message]
2026-09-21 16:18 ` [PATCH net-next 1/3] dt-bindings: net: realtek,rtl82xx: Document RTL8261C/D PHYs Simon Polack
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-1-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®