Re: [PATCH] r8169: add support for RTL8127ATF
From: Michael Zimmermann
Date: Tue Nov 18 2025 - 16:32:06 EST
On Tue, Nov 18, 2025 at 9:20 PM Fabio Baltieri <fabio.baltieri@xxxxxxxxx> wrote:
>
> On Tue, Nov 18, 2025 at 09:02:22PM +0100, Heiner Kallweit wrote:
> > A contact in Realtek confirmed that only 1G and 10G speeds are supported.
> > He wasn't sure whether copper SFP modules are supported, and will check
> > internally.
> >
> > I'll try to strip down the patch as far as possible, likely supporting 10G
> > only in the beginning (as 1G requires some more vendor magic to configure).
> > I assume the typical user won't spend money on a 10G card to use it with a
> > 1G fiber module.
> > Reducing complexity of the patch should make the decision easier to accept it.
> >
> > I don't have hw with RTL8127ATF, so I would give the patch to Fabio for testing.
>
> Hey thanks for following up on this, cc'ing Michael as well, as it turns
> out he was also working on upstream support for this at the same time as
> me, maybe he can help testing in more scenarios.
>
> I did test 1G support between two RTL8127ATF cards and it works fine,
> have not tried between that a 1G fiber only card (don't own any), happy
> to drop it if you think it may not work but hopefully it can be tested
> and kept, it was in the out of tree driver after all, I'd hope the
> vendor did some interoperability test with that code.
>
> Cheers,
> Fabio
One thing the out-of-tree driver does, which your patch doesn't do, is
disabling eee when in fiber mode. I'd suggest something like this:
@@ -845,7 +860,8 @@ static bool rtl_supports_eee(struct rtl8169_private *tp)
{
return tp->mac_version >= RTL_GIGA_MAC_VER_34 &&
tp->mac_version != RTL_GIGA_MAC_VER_37 &&
- tp->mac_version != RTL_GIGA_MAC_VER_39;
+ tp->mac_version != RTL_GIGA_MAC_VER_39 &&
+ !tp->fiber_enabled;
}
Michael