From: Daniel Golle <daniel@makrotopia.org>
To: Birger Koblitz <mail@birger-koblitz.de>
Cc: "Andrew Lunn" <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
"Eric Dumazet" <edumazet@google.com>,
"Jakub Kicinski" <kuba@kernel.org>,
"Paolo Abeni" <pabeni@redhat.com>,
linux-usb@vger.kernel.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org,
"René van Dorst" <opensource@vdorst.com>
Subject: Re: [PATCH net-next] r8152: Add 2500baseT EEE status/configuration support
Date: Tue, 24 Feb 2026 01:33:07 +0000 [thread overview]
Message-ID: <aZz_0_Zt67XsOyTM@makrotopia.org> (raw)
In-Reply-To: <20260223-b4-eee2g5-v1-1-7006b537b144@birger-koblitz.de>
On Mon, Feb 23, 2026 at 08:20:35PM +0100, Birger Koblitz wrote:
> The r8152 driver supports the RTL8156, which is a 2.5Gbit Ethernet controller for
> USB 3.0, for which support is added for configuring and displaying the EEE
> advertisement status for 2.5GBit connections.
>
> The patch also corrects the determination of whether EEE is active to include
> the 2.5GBit connection status and make the determination dependent not on the
> desired speed configuration (tp->speed), but on the actual speed used by
> the controller. For consistency, this is corrected also for the RTL8152/3.
>
> This was tested on an Edimax EU-4307 V1.0 USB-Ethernet adapter with RTL8156,
> and a SECOMP Value 12.99.1115 USB-C 3.1 Ethernet converter with RTL8153.
>
> Signed-off-by: Birger Koblitz <mail@birger-koblitz.de>
> ---
> drivers/net/usb/r8152.c | 42 +++++++++++++++++++++++++++++++++++++-----
> 1 file changed, 37 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
> index 49433301e7b1d5c98fc32c72f821e31335bc3527..0bc3b1b93017c80e1761b00767904ff1c2e6ac87 100644
> --- a/drivers/net/usb/r8152.c
> +++ b/drivers/net/usb/r8152.c
> @@ -213,6 +213,7 @@
> #define OCP_EEE_LPABLE 0xa5d2
> #define OCP_10GBT_CTRL 0xa5d4
> #define OCP_10GBT_STAT 0xa5d6
> +#define OCP_EEE_LPABLE2 0xa6d0
> #define OCP_EEE_ADV2 0xa6d4
> #define OCP_PHY_STATE 0xa708 /* nway state for 8153 */
> #define OCP_PHY_PATCH_STAT 0xb800
> @@ -954,6 +955,7 @@ struct r8152 {
> u16 ocp_base;
> u16 speed;
> u16 eee_adv;
> + u16 eee_adv2;
> u8 *intr_buff;
> u8 version;
> u8 duplex;
> ...
> @@ -8953,7 +8962,10 @@ static int r8152_set_eee(struct r8152 *tp, struct ethtool_keee *eee)
>
> tp->eee_en = eee->eee_enabled;
> tp->eee_adv = val;
> -
> + if (tp->support_2500full) {
> + val = linkmode_to_mii_eee_cap2_t(eee->advertised);
> + tp->eee_adv2 = val;
eee_adv2 set here is never actually written to the hardware.
ie. you are never doing
ocp_reg_write(tp, OCP_EEE_ADV2, tp->eee_adv2);
for capable NICs.
next prev parent reply other threads:[~2026-02-24 1:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-23 19:20 [PATCH net-next] r8152: Add 2500baseT EEE status/configuration support Birger Koblitz
2026-02-24 1:33 ` Daniel Golle [this message]
2026-02-24 17:32 ` Birger Koblitz
2026-02-24 17:02 ` [net-next] " Simon Horman
2026-02-24 17:36 ` Birger Koblitz
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=aZz_0_Zt67XsOyTM@makrotopia.org \
--to=daniel@makrotopia.org \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=mail@birger-koblitz.de \
--cc=netdev@vger.kernel.org \
--cc=opensource@vdorst.com \
--cc=pabeni@redhat.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