🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #18384

RE: [PATCH net-next v8 10/11] r8152: add TGPHY register access for RTL8157 and RTL8159

#18384
From: Chih Kai Hsu
Date: Wed, 18 Nov 2026 09:01
233 lines
27990 bytes
> Thank you for your contribution! Sashiko AI review found 5 potential
> issue(s) to consider.
> 
> Critical: 0 · High: 1 · Medium: 3 · Low: 1
> 
> If you believe none of the issues are legitimate, please reply to each issue of
> Medium severity or higher and explain why the AI is wrong.
> If any of them are legitimate and you plan to respin, please let patchwork know
> by including "pw-bot: cr" as a separate line at the end of your reply (one such
> reply per series is enough).
> 
> - [High] set_carrier() (drivers/net/usb/r8152.c:7468) was not converted
>   to the new error contract.
> - [Medium] The commit message says rtl8152_get_link_ksettings() now
>   propagates the error.
> - [Medium] rtl8153_in_nway() (line 7431) now returns false when the
>   OCP_PHY_STATE read fails, which means 'the PHY is not in…
> - [Medium] r8152: negative errnos returned by read_mii_word() to MII
>   library
> - [Low] rtl8152_set_speed() (line 6835) can now return early on a failed
>   PHY access, after it has already written some advertisement registers…
> 
> --
> 
> r8152: add TGPHY register access for RTL8157 and RTL8159
> 
> This patch adds a TGPHY command channel for PHY register access on RTL8157
> and RTL8159. Access goes through new rtl_ops.phy_read/phy_write hooks.
> A TGPHY access can fail, so the PHY accessors and their helpers now return int,
> and a set of callers is updated to act on errors.
> 
> > diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c index
> > fad4473caf2a4..703ec5483778b 100644
> > --- a/drivers/net/usb/r8152.c
> > +++ b/drivers/net/usb/r8152.c
> 
> [ ... ]
> 
> > @@ -1669,16 +1680,33 @@ static void ocp_reg_write(struct r8152 *tp,
> > u16 addr, u16 data)
> 
> [ ... ]
> 
> > -static inline int r8152_mdio_read(struct r8152 *tp, u32 reg_addr)
> > +static int r8152_mdio_read(struct r8152 *tp, u32 reg_addr)
> >  {
> > -     return ocp_reg_read(tp, OCP_BASE_MII + reg_addr * 2);
> > +     u16 data;
> > +     int ret;
> > +
> > +     ret = ocp_reg_read(tp, OCP_BASE_MII + reg_addr * 2, &data);
> > +
> > +     return ret < 0 ? ret : data;
> >  }
> 
> [Severity: Medium]
> The added comment says a failed read must not reach the MII library as an
> errno, but the two early returns at the top of read_mii_word() still pass one on.
> The RTL8152_INACCESSIBLE check returns -ENODEV and the phy_id check
> returns -EINVAL. Neither goes through the new ret < 0 ? 0 : ret conversion.
> Those returns are not new, but with this patch they no longer match the stated
> contract.
> 
> -ENODEV is 0xffffffed, which has BMCR_ANENABLE, BMSR_LSTATUS and
> BMSR_ANEGCOMPLETE set. -EINVAL is 0xffffffea, which also has
> BMCR_ANENABLE set. The MII library always passes tp->mii.phy_id, though, so
> the -EINVAL path is mostly theoretical.
> 
> mii_nway_restart() tests BMCR_ANENABLE directly on the mdio_read() result.
> Suppose RTL8152_INACCESSIBLE is set when rtl8152_nway_reset() or
> rtl_ethtool_set_eee() calls it. The -ENODEV then reads as autoneg enabled,
> write_mii_word() drops the restart without reporting it, and
> mii_nway_restart() returns 0.
> 
> Neither caller checks the flag first. On RTL8157/RTL8159,
> r8152_set_eee() can latch it through rtl_eee_enable() right before the
> mii_nway_restart() call. Userspace is then told the renegotiation succeeded on a
> device that is gone.
> 
> In mii_ethtool_get_link_ksettings() the two conventions get mixed. The TGPHY
> access that latches the flag makes the MII_BMCR read return 0.
> The MII_BMSR, MII_CTRL1000, MII_STAT1000 and MII_ADVERTISE reads after
> it hit the early return and come back as 0xffed.
> 
> Should these early returns also return 0, so read_mii_word() follows its own
> comment? Or, since a 0 BMCR has problems of its own, would it be better for
> the callers of the MII library to check RTL8152_INACCESSIBLE before calling into
> it?

I plan to add two new functions, rtl_nway_restart() and rtl8152_get_link_ksettings, 
to replace mii_nway_restart() and mii_ethtool_get_link_ksettings, respectively.

The two functions call r8152_mdio_read() directly and handle each read's errno,
including RTL8152_INACCESSIBLE, before using any register value.

Nothing calls read_mii_word() anymore, so its early returns can no longer reach
the MII library as register bits, and BMCR/BMSR decoding problem does not arise.

> 
> [Severity: High]
> With this change, r8152_mdio_read() can return a negative errno on
> RTL8157/RTL8159. The failure comes from
> ocp_reg_read()->r8157_phy_read()->rtl_tgphy_access().
> 
> Was set_carrier() meant to be converted too? It still treats the return value as
> register content:
> 
> drivers/net/usb/r8152.c:set_carrier() {
>         if (r8152_mdio_read(tp, MII_BMSR) & BMSR_LSTATUS) {
>                 if (!netif_carrier_ok(netdev)) {
>                         tp->rtl_ops.enable(tp);
>                         ...
>                         netif_carrier_on(netdev);
>                         rtl_start_rx(tp);
>         ...
>         } else {
>                 if (netif_carrier_ok(netdev)) {
>                         netif_carrier_off(netdev);
>                         ...
>                         tp->rtl_ops.disable(tp);
>         ...
>                 if (rtl8152_get_speed(tp) & LINK_STATUS) {
>                         set_bit(RTL8152_LINK_CHG, &tp->flags);
>                         schedule_delayed_work(&tp->schedule, 0);
>                 }
>         }
> }
> 
> -ENODEV is 0xffffffed, which has BMSR_LSTATUS (bit 2) set. If the device is gone
> and the carrier is off, set_carrier() would see link up.
> It would then call rtl_ops.enable(), netif_carrier_on() and rtl_start_rx().
> 
> -ETIMEDOUT is 0xffffff92, which has BMSR_LSTATUS clear. One TGPHY busy
> timeout from wait_tgphy_cmd_ready() while the carrier is up would read as link
> down. The carrier would go off and rtl_ops.disable() would run.
> rtl8152_get_speed() still reports LINK_STATUS, so LINK_CHG is rescheduled.
> Wouldn't that give a carrier off/on flap?

Yes, I will add errno handling for this read in the next version.

> 
> set_carrier() runs from rtl_work_func_t() on every link change, and that function
> checks RTL8152_INACCESSIBLE only on entry. set_carrier() is missing from both
> lists in the commit message: the converted callers and the callers left for the
> follow-up series.
> 
> [ ... ]
> 
> > @@ -6726,12 +6929,19 @@ static int rtl8152_set_speed(struct r8152 *tp,
> u8 autoneg, u32 speed, u8 duplex,
> >               }
> >
> >               if (orig != new1) {
> > -                     r8152_mdio_write(tp, MII_ADVERTISE, new1);
> > +                     ret = r8152_mdio_write(tp, MII_ADVERTISE, new1);
> > +                     if (ret < 0)
> > +                             goto out;
> > +
> >                       tp->mii.advertising = new1;
> >               }
> >
> >               if (tp->mii.supports_gmii) {
> > -                     orig = r8152_mdio_read(tp, MII_CTRL1000);
> > +                     ret = r8152_mdio_read(tp, MII_CTRL1000);
> > +                     if (ret < 0)
> > +                             goto out;
> > +
> > +                     orig = ret;
> >                       new1 = orig & ~(ADVERTISE_1000FULL |
> >                                       ADVERTISE_1000HALF);
> 
> [ ... ]
> 
> > @@ -6776,20 +6995,26 @@ static int rtl8152_set_speed(struct r8152 *tp,
> u8 autoneg, u32 speed, u8 duplex,
> >       if (test_and_clear_bit(PHY_RESET, &tp->flags))
> >               bmcr |= BMCR_RESET;
> >
> > -     r8152_mdio_write(tp, MII_BMCR, bmcr);
> > +     ret = r8152_mdio_write(tp, MII_BMCR, bmcr);
> > +     if (ret < 0) {
> > +             if (bmcr & BMCR_RESET)
> > +                     set_bit(PHY_RESET, &tp->flags);
> > +             goto out;
> > +     }
> 
> [Severity: Low]
> The commit message says a failed write in rtl8152_set_speed() leaves the
> cached advertising and a pending PHY reset untouched. Does that cover all the
> state changed before these early exits?
> 
> In the autoneg branch, MII_ADVERTISE may already be written when the
> MII_CTRL1000 or OCP_10GBT_CTRL access fails. tp->mii.advertising and
> tp->ups_info.speed_duplex may already be updated too. The early return
> skips BMCR_ANRESTART. The PHY then keeps the new 10/100 advertisement
> together with the old 1000/multi-gig one, and the next renegotiation uses that
> mix.
> 
> In the forced branch, tp->mii.force_media, tp->mii.full_duplex and
> tp->ups_info.speed_duplex are set before the MII_BMCR write. If that
> write fails, only PHY_RESET is restored, and the PHY is still autonegotiating.
> 
> Since ret is non-zero, rtl8152_set_link_ksettings() keeps the old
> tp->autoneg/speed/duplex/advertising. Later in the series,
> r8157_ups_en() calls r8156_ups_flags(), which writes
> tp->ups_info.speed_duplex into USB_UPS_FLAGS. The stale value would then
> reach the UPS firmware as well.
> 
> Should this partly applied state be rolled back, or should the commit message
> describe what is left behind?

Agreed, the old wording didn't cover that. In the next version, rtl8152_set_speed()
stages the new values in locals and updates tp->ups_info.speed_duplex,
tp->mii.full_duplex, tp->mii.force_media , when it was written,
and tp->mii.advertising only after the final MII_BMCR write succeeds.

Earlier failures leave the cached state as it was, so r8156_ups_flags() never sees
a value that was not applied. PHY_RESET is still restored when the BMCR write fails.

> 
> [ ... ]
> 
> > @@ -7205,7 +7430,12 @@ static bool rtl8152_in_nway(struct r8152 *tp)
> >
> >  static bool rtl8153_in_nway(struct r8152 *tp)  {
> > -     u16 phy_state = ocp_reg_read(tp, OCP_PHY_STATE) & 0xff;
> > +     u16 phy_state;
> > +
> > +     if (ocp_reg_read(tp, OCP_PHY_STATE, &phy_state) < 0)
> > +             return false;
> 
> [Severity: Medium]
> Is false the safe answer when the read fails? RTL8157/RTL8159 use
> rtl8153_in_nway() as ops->in_nway. delay_autosuspend() relies on it to avoid
> suspending while the PHY is negotiating:

Agreed. When the read fails, delay_autosuspend() should return true.

> 
> drivers/net/usb/r8152.c:delay_autosuspend() {
>         ...
>         /* If the linking down is occurred by nway, the device may miss the
>          * linking change event. And it wouldn't wake when linking on.
>          */
>         if (!sw_linking && tp->rtl_ops.in_nway(tp))
>                 return true;
>         ...
> }
> 
> A TGPHY timeout while the PHY is mid-negotiation would let runtime suspend
> go ahead. The adapter could then miss the link-up wake event and stay
> suspended.
> 
> Before this patch, a failed control transfer filled the data with 0xff through
> get_registers(). The low byte then read as "in nway", which delayed suspend.
> Would returning true on a failed read be the safer choice here?
> 
> [ ... ]
> 
> > @@ -9388,8 +9621,16 @@ int rtl8152_get_link_ksettings(struct net_device
> *netdev,
> >                        cmd->link_modes.supported,
> > tp->support_10000full);
> >
> >       if (tp->support_2500full || tp->support_5000full ||
> tp->support_10000full) {
> > -             u16 ocp_10gbt_ctrl = ocp_reg_read(tp, OCP_10GBT_CTRL);
> > -             u16 ocp_10gbt_stat = ocp_reg_read(tp, OCP_10GBT_STAT);
> > +             u16 ocp_10gbt_ctrl;
> > +             u16 ocp_10gbt_stat;
> > +
> > +             ret = ocp_reg_read(tp, OCP_10GBT_CTRL, &ocp_10gbt_ctrl);
> > +             if (ret < 0)
> > +                     goto out_unlock;
> > +
> > +             ret = ocp_reg_read(tp, OCP_10GBT_STAT, &ocp_10gbt_stat);
> > +             if (ret < 0)
> > +                     goto out_unlock;
> 
> [Severity: Medium]
> The commit message says rtl8152_get_link_ksettings() propagates the error.
> Does that apply only to these two OCP_10GBT reads?
> 
> Earlier in this function, mii_ethtool_get_link_ksettings() reads BMCR, BMSR,
> CTRL1000, STAT1000, ADVERTISE and LPA through tp->mii.mdio_read, which is
> read_mii_word(). After this patch, read_mii_word() turns a failed read into 0:
> 
>         return ret < 0 ? 0 : ret;
> 
> A BMCR of 0 looks like autoneg off with forced 10M half duplex.
> mii_ethtool_get_link_ksettings() also stores that duplex into
> tp->mii.full_duplex. Suppose the MII reads fail but the 10GBT reads
> succeed. Can ethtool then return success with a made-up forced 10M/half
> configuration?
> 
> The same 0 makes mii_nway_restart() return -EINVAL (autoneg off) instead of
> the I/O error. That affects rtl8152_nway_reset() and the eee_set path.
> 
> [ ... ]

By rewriting rtl8152_get_link_ksetting without mii_ethtool_get_link_ksettings,
a failed read can no longer be decoded as BMSR = 0, so ethtool doesn't report
a forced 10M/half link.

Same as rtl8152_nway_reset and the eee path.

> 
> --
> Sashiko AI review ·
> https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261110032416.16968-1
> -nic_swsd%40realtek.com

Best Regards,
Chih-Kai
---
pw-bot: cr
Technical Details
Message-ID: <0c6318e175b14ce8b86a957c7c79d5db@realtek.com>
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srv.newsdeef.eu!newsfeed.endofthelinebbs.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-365967-linux-kernel-netdev=dewy.ru
References: <20261110032416.16968-11-nic_swsd@realtek.com> <179464851836.2199510.10154643847175029122@kernel.org>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srv.newsdeef.eu!newsfeed.endofthelinebbs.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-365967-linux-kernel-netdev=dewy.ru
From: hsu.chih.kai@realtek.com (Chih Kai Hsu)
Newsgroups: linux.kernel.netdev
Subject: RE: [PATCH net-next v8 10/11] r8152: add TGPHY register access for
 RTL8157 and RTL8159
Date: Wed, 18 Nov 2026 09:01:27 +0000
Organization: Usenet Network
Message-ID: <0c6318e175b14ce8b86a957c7c79d5db@realtek.com>
References: <20261110032416.16968-11-nic_swsd@realtek.com>
 <179464851836.2199510.10154643847175029122@kernel.org>
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
Injection-Info: usenet.network;
	logging-data="2548207"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:fAyF/2mUgddakS+krEPEFj1a95s= sha256:6ktveBDsVqM/T3/wnQe+XWnm3EFVzbk/kz9L7WA+AI4=
	sha1:X2+cH4lVRF4zk8wRKeFQHFJ1ptE= sha256:8XOUC2dA/32Jkpy5LelFi7Hz0yN1ho4kk1eDBqJ2uJo=
Content-Language: zh-TW
List-ID: <netdev.vger.kernel.org>
X-Mailpost-Empty-Hdrs: X-Spam-Level
X-Received: from localhost (localhost [127.0.0.1])
	by mail.dewy.ru (Postfix) with ESMTP id D9A6C115204; Wed, 18 Nov 2026 12:02:21 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.05
X-Spam-Status: No, score=-3.05 tagged_above=-9999 required=6.31
	tests=[DCC_REPUT_70_89=0.1, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,
	DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.249,
	MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001,
	SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key)
	header.d=realtek.com
X-Received: from mail.dewy.ru ([127.0.0.1])
	by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id CCxhg3a78u9x;
	Wed, 18 Nov 2026 12:02:15 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-365967-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> 
X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=realtek.com
X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10])
	by mail.dewy.ru (Postfix) with ESMTPS id C3DD4114F03; Wed, 18 Nov 2026 12:02:06 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by sea.lore.kernel.org (Postfix) with ESMTP id 012E538C7E; Wed, 18 Nov 2026 09:02:05 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.remote-ip=127.0.0.1
X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=fail;
	t=1794992524;
	b=3JxRDMwXeIyYHUUd7dO27ntnjSXd1+KUdLJvz82TE108Z8sxhaoubtuXAcOVwVND6fjo
	 Og3RMTYluGfdd8whW3n2165qkMnaulCqqAm2GI4Wmmklbskd23NieqRROtOR6mrH0FHj/
	 ej4PcfAiHENMDUpsX0FeiO0xwtnXZyx/bNsx7padLmmdT3NV6WNfl3F4cSsCTvFzDYD6/
	 O4vayXVSt2lgyY3CmnFi2RkV3FCHu2eFBYzbpFM47Cd3jJlTgr9bnyPlVXzgE7fa8qtVt
	 kZjPPFr3+A27FhU7J60QxrRrnvRw+dAJW/36DZm8EbTKCAS8QGhjujJOQsihFU+7vOA==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1794992524;
	h=X-Original-To:Received:DMARC-Filter:X-SpamFilter-By:DKIM-Signature:
	 Received:Received:Received:Received:From:To:CC:Subject:Thread-Topic:
	 Thread-Index:Date:Message-ID:References:In-Reply-To:Accept-Language:
	 Content-Language:Content-Type:Content-Transfer-Encoding:
	 X-Mailing-List:List-Id:List-Post:List-Help:List-Subscribe:
	 List-Unsubscribe:List-Owner:Precedence:MIME-Version;
	bh=utZGkN434AK9o81+reJmHSyjIOunkPkPioLTtEoamzA=;
	b=igX+n4zyBTVXekIpSjxaSLSmiruF9oVrYUnGvbdrDBnsMEwvLRUyctpkAl+Qb2R9tFFd
	 v9l42rjw71bbwvp5etyrYQYTlRA1Zrj+rBZjApSwh+cCSMFBHO994j0lFXNInYD09die6
	 1tKUPQkOmGm+gx45t9MkRBshr1ASfj2/2AOprfZFZkLD3QT4pCpnVFnzdbKkY8dU/lL6x
	 +HX0lY9kKgYqbEPmVhTXkZDU7eSDk+JUUCde+v+IYw+r+J2NBl9w66R7yF3+XUvRMIscd
	 PINmAcDefZFGV0QC1NanLjJ6fr9dOpgRlkt1fbglNvnxSD81Jxzc/sXiH3eYL+SIhhA==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dkim=pass header.d=realtek.com header.i=@realtek.com header.a=rsa-sha256 header.s=dkim header.b=bdBGpAUE;
	dmarc=pass header.from=realtek.com;
	spf=pass smtp.mailfrom=realtek.com;
	arc=fail smtp.remote-ip=127.0.0.1
X-Received: from localhost.localdomain (localhost [127.0.0.1])
	by smtp.subspace.kernel.org (Postfix) with ESMTP id 2711A606A335;
	Wed, 18 Nov 2026 09:02:04 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
	dkim=pass (2048-bit key) header.d=realtek.com header.i=@realtek.com header.a=rsa-sha256 header.s=dkim header.b=bdBGpAUE
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=211.75.126.72
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
	t=1794992523;
	b=zQ/RJsPktQEF1l6j9vTGgf5mU8tLlLuAcKbR+1L8ioc29CrwUhe7LuRgQuFrFcl6D7Q1
	 dGXOKMy4knHopo6uByyS5r1fZmXrdDZwN4mB1AHgAJXFCiBrr8A/cZ2pU4gUgV5a5yV0o
	 i9wg7pDkYWhLnact8327VJ2re6A9CZlHmyccMTY8+pRWmL8uYdnTiZXBkHcjOQ8t0J7Rb
	 GwkxbxVbWcFH1HVz35T/hbCOEGN6UIqVI199dURPqwrMafw4iPeTS95RCMO2NShPL4BW/
	 2wc/0+LGw1tO8CLyyVusBNxKiQ+vMRqE/iH60PhirCJuTtQM8XVd+b7ybENTiv1VGrA==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1794992523;
	h=DMARC-Filter:X-SpamFilter-By:DKIM-Signature:Received:Received:
	 Received:Received:From:To:CC:Subject:Thread-Topic:Thread-Index:Date:
	 Message-ID:References:In-Reply-To:Accept-Language:Content-Language:
	 x-originating-ip:Content-Type:Content-Transfer-Encoding:MIME-Version;
	bh=utZGkN434AK9o81+reJmHSyjIOunkPkPioLTtEoamzA=;
	b=E1M0fXxanhoMmUb7dmXcEX5WlcjRymbCrymmSHvm8nzbJYVffsX9mei4CzKbjed4nlsz
	 UtybMsx46+a4YALM2cIVwNgJLtHhQV+iJTngNPYz4Ca9E9jALNzCB4R0g5WKrJ/JtZegb
	 LEzCe/t5jz1g44GM77aW2T/4oNsZOjBQJecQz7CxImZbuCeImJVaQVXF3/LYptmbGIe+O
	 xodOpGP46Uo1Ttebj8UlFR5C16fDn4TKNHPho4XxfbFZYYNNHXG8nQgnf2rMtfgPi2q62
	 T5c6tW7evJn3Guxx3uQfGZjKQkeX1S0ppO1RwsFsXHbMMY6nbEpU5oYgEqQGNw0AkKg==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dmarc=pass header.from=realtek.com;
	spf=pass smtp.mailfrom=realtek.com;
	dkim=pass header.d=realtek.com header.i=@realtek.com header.a=rsa-sha256 header.s=dkim header.b=bdBGpAUE;
	arc=none smtp.remote-ip=211.75.126.72
X-Received: from rtits2.realtek.com.tw (rtits2.realtek.com [211.75.126.72])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256)
	(No client certificate requested)
	by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7D2C4606A31C;
	Wed, 18 Nov 2026 09:02:01 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 7D2C4606A31C
X-Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=realtek.com
X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=realtek.com
X-SpamFilter-By: ArmorX SpamTrap 5.80 with qID 6AI91S0j81198498, This message is accepted by code: ctloc85258
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=realtek.com; s=dkim;
	t=1794992488; bh=utZGkN434AK9o81+reJmHSyjIOunkPkPioLTtEoamzA=;
	h=From:To:CC:Subject:Date:Message-ID:References:In-Reply-To:
	 Content-Type:Content-Transfer-Encoding:MIME-Version;
	b=bdBGpAUEUgs4zFb6Rx5PK1QEE/6sLTld69ZnFV0rypgzuKkto4H3pkHkIY9NZc+LC
	 6gLT59yoNoafxjhyzuc0ZrlK4w4wGDcBYLkI28mCLK7UiPTqUFn8jpCE08ot96uDyP
	 goau/YkoVEkMTTWtvXDQSIOba0p8z4ery5DtBCd8OgsGplYdMYSrBj5jQTXnIA1I2I
	 ddkkfeLjdCoJ9IxVxNgDQrHelqDxSr2lkv4yQeyloK4HmOKKT06GQ7WDiIV5HFa5y3
	 /c65Ao20o7AtpwJAY5FisW/11T1FhiwzNWkAC1li9pSWCJfbUcjd6yCmAGvxdKw5Ix
	 g7HhcDG8wktfw==
X-Received: from mail.realtek.com (rtkexhmbs03.realtek.com.tw[10.21.1.53])
	by rtits2.realtek.com.tw (8.15.2/3.29/5.94) with ESMTPS id 6AI91S0j81198498
	(version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL);
	Wed, 18 Nov 2026 17:01:28 +0800
X-Received: from RTKEXHMBS01.realtek.com.tw (172.21.6.40) by
 RTKEXHMBS03.realtek.com.tw (10.21.1.53) with Microsoft SMTP Server
 (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id
 15.2.2562.56; Wed, 18 Nov 2026 17:01:28 +0800
X-Received: from RTKEXHMBS06.realtek.com.tw (10.21.1.56) by
 RTKEXHMBS01.realtek.com.tw (172.21.6.40) with Microsoft SMTP Server
 (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id
 15.2.2562.56; Wed, 18 Nov 2026 17:01:28 +0800
X-Received: from RTKEXHMBS06.realtek.com.tw ([fe80::eeeb:c765:ca73:5eef]) by
 RTKEXHMBS06.realtek.com.tw ([fe80::eeeb:c765:ca73:5eef%10]) with mapi id
 15.02.2562.056; Wed, 18 Nov 2026 17:01:28 +0800
X-CC: "davem@davemloft.net" <davem@davemloft.net>, "kuba@kernel.org"
	<kuba@kernel.org>, "netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	nic_swsd <nic_swsd@realtek.com>, "linux-kernel@vger.kernel.org"
	<linux-kernel@vger.kernel.org>, "linux-usb@vger.kernel.org"
	<linux-usb@vger.kernel.org>, "edumazet@google.com" <edumazet@google.com>,
	"bjorn@mork.no" <bjorn@mork.no>, "pabeni@redhat.com" <pabeni@redhat.com>,
	"andrew+netdev@lunn.ch" <andrew+netdev@lunn.ch>, "mail@birger-koblitz.de"
	<mail@birger-koblitz.de>
X-Thread-Topic: [PATCH net-next v8 10/11] r8152: add TGPHY register access for
 RTL8157 and RTL8159
X-Thread-Index: AQHdcMMAVp0iERnuiECMnOxwgdqzp7cszWwAgAbBatA=
X-In-Reply-To: <179464851836.2199510.10154643847175029122@kernel.org>
X-Accept-Language: zh-TW, en-US
X-Mailing-List: netdev@vger.kernel.org
X-List-Post: <mailto:netdev@vger.kernel.org>
X-List-Help: <mailto:netdev+help@vger.kernel.org>
X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org>
X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org>
X-List-Owner: <mailto:netdev+owner@vger.kernel.org>
X-Precedence: list