From: Aleksander Jan Bajkowski <olek2@wp.pl>
To: javen <javen_xu@realsil.com.cn>,
andrew@lunn.ch, hkallweit1@gmail.com, linux@armlinux.org.uk,
davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, freddy_gu@realsil.com.cn
Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
daniel@makrotopia.org, vladimir.oltean@nxp.com
Subject: Re: [PATCH net-next v1 1/2] net: phy: realtek: add support for RTL8261
Date: Thu, 28 May 2026 18:56:37 +0200 [thread overview]
Message-ID: <17fd1f36-2f98-4c79-8b67-e407de599350@wp.pl> (raw)
In-Reply-To: <20260528075226.1054-2-javen_xu@realsil.com.cn>
Hi Javen,
On 28/05/2026 09:52, javen wrote:
> From: Javen Xu <javen_xu@realsil.com.cn>
>
> This patch adds support for Realtek phy chip RTL8261. Its PHY id is
> 0x001cc898 and 0x001cc899.
>
> Signed-off-by: Javen Xu <javen_xu@realsil.com.cn>
> ---
> drivers/net/phy/realtek/realtek_main.c | 315 +++++++++++++++++++++++++
> 1 file changed, 315 insertions(+)
>
> diff --git a/drivers/net/phy/realtek/realtek_main.c b/drivers/net/phy/realtek/realtek_main.c
> index 27268811f564..fe743fd0421b 100644
> --- a/drivers/net/phy/realtek/realtek_main.c
> +++ b/drivers/net/phy/realtek/realtek_main.c
> +static int rtl8261x_config_aneg(struct phy_device *phydev)
> +{
> + u16 adv_1g = 0;
> + int ret;
> +
> + if (phydev->autoneg == AUTONEG_DISABLE)
> + return genphy_c45_pma_setup_forced(phydev);
> +
> + ret = rtl8261x_config_master_slave(phydev);
> + if (ret < 0)
> + return ret;
> +
> + ret = genphy_c45_config_aneg(phydev);
> + if (ret < 0)
> + return ret;
> +
> + if (linkmode_test_bit(ETHTOOL_LINK_MODE_1000baseT_Full_BIT,
> + phydev->advertising))
> + adv_1g = BIT(9);
adv_1g = ADVERTISE_1000FULL;
> +
> + ret = phy_modify_mmd_changed(phydev, MDIO_MMD_VEND2,
> + RTL8261X_GBCR_REG,
> + BIT(9), adv_1g);
This is the C22 register mapped in VEND2 page. You can replace it with:
ret = phy_modify_mmd_changed(phydev, MDIO_MMD_VEND2,
RTL822X_VND2_C22_REG(MII_CTRL1000 ),
ADVERTISE_1000FULL, adv_1g);
Best regards,
Aleksander
next prev parent reply other threads:[~2026-05-28 16:56 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-28 7:52 [PATCH net-next v1 0/2] Add support for RTL8261c javen
2026-05-28 7:52 ` [PATCH net-next v1 1/2] net: phy: realtek: add support for RTL8261 javen
2026-05-28 9:37 ` Nicolai Buchwitz
2026-05-29 0:51 ` Andrew Lunn
2026-06-03 2:35 ` Javen
2026-05-28 12:39 ` Andrew Lunn
2026-05-28 12:42 ` Andrew Lunn
2026-05-28 16:56 ` Aleksander Jan Bajkowski [this message]
2026-05-28 7:52 ` [PATCH net-next v1 2/2] net: phy: realtek: load firmware for RTL8261C javen
2026-05-28 9:08 ` Nicolai Buchwitz
2026-05-28 12:20 ` Daniel Golle
2026-06-01 5:38 ` Javen
2026-05-29 1:01 ` Andrew Lunn
2026-06-03 2:32 [PATCH net-next v1 1/2] net: phy: realtek: add support for RTL8261 Javen
2026-06-03 2:57 ` Andrew Lunn
2026-06-04 7:28 ` Javen
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=17fd1f36-2f98-4c79-8b67-e407de599350@wp.pl \
--to=olek2@wp.pl \
--cc=andrew@lunn.ch \
--cc=daniel@makrotopia.org \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=freddy_gu@realsil.com.cn \
--cc=hkallweit1@gmail.com \
--cc=javen_xu@realsil.com.cn \
--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=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®