Kernel Module r8169 and the Realtek 8126 PCIe 5 G/bps WIRED ethernet adapter
A message that is not in the archive (sent off-list or not yet received): [email protected]
Heiner Kallweit
maintainerQuoted 39 lines · Joe Salmeri
Hi,
I recently built a new PC using the Asus z790 Maximus Formula motherboard.
The z790 Formula uses the Realtek 8126 PCIe 5 G/bps WIRED ethernet adapter.
I am using openSUSE Tumbleweed build 20231228 with kernel 6.6.7-1
There does not seem to be a driver for the Realtek 8126.
Here is the device info from "lspci | grep -i net"
04:00.0 Network controller: Intel Corporation Device 272b (rev 1a) 05:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. Device 8126 (rev 01)
So it is detects the 8126 just fine it just doesn't have a driver for it.
I checked realtek.com and found
The download link still says 8125 ( and kernel 6.4 ), but I compiled the source and since I have Secure boot enabled, I signed the resulting module file.
The driver loads successfully and I now have wired networking and it has worked flawlessly for the last 2 months.
I submitted a bug in Tumbleweed requesting support for the Realtek 8126 be added and was informed that the r8169 kernel module is what is used to support the older Realtek 8125 device.
Since the drivers from Realtek seem to support both the r8125 and my newer r8126, the Tumbleweed support prepared a test kernel 6.6.7-1 for me where they added the PCI entry for the r8126 and I installed and tested it out.
Although it does now load the r8169 module with their test kernel, the r8126 device still does not work.
The only 2 lines that reference the r8169 in the dmesg log are these 2 lines:
[ 3.237151] r8169 0000:05:00.0: enabling device (0000 -> 0003)
[ 3.237289] r8169 0000:05:00.0: error-ENODEV: unknown chip XID 649, contact r8169 maintainers (seeMAINTAINERSfile)
Quoted 9 lines
I reported the results of the test to Tumbleweed support and they said that additional tweaks will be needed for the r8169 module to support the r8126 wired network adapter and thatn I should request to you to add support.
The details of the openSUSE bug report on the issue can be found here:
https://bugzilla.suse.com/show_bug.cgi?id=1217417
Could we please get support added for the r8126 - Realtek 8126 PCIe 5 G/bps WIRED ethernet adapter added to the kernel ?
Thanks for the report. Actually it's not a bug report but a feature request.
Realtek provides no information about new chip versions and no data sheets, therefore the only source of information is the r8125 vendor driver. Each chip requires a lot of version-specific handling, therefore the first steps you described go in the right direction, but are by far not sufficient. Patch below applies on linux-next, please test whether it works for you, and report back.
Disclaimer:
r8125 references a firmware file that hasn't been provided to linux-firmware by Realtek yet. Typically the firmware files tune PHY parameters to deal with compatibility issues. In addition r8125 includes a lot of PHY tuning for RTL8126A.
Depending on cabling, link partner etc. the patch may work for you, or you may experience link instability or worst case no link at all.
Maybe RTL8126a also has a new integrated PHY version that isn't supported yet. In this case the driver will complain with the following message and I'd need the PHY ID. "no dedicated PHY driver found for PHY ID xxx"
Quoted 4 lines
Please let me know if you need any further details.
Thank you!
--- drivers/net/ethernet/realtek/r8169.h | 1 + drivers/net/ethernet/realtek/r8169_main.c | 91 +++++++++++++++---- .../net/ethernet/realtek/r8169_phy_config.c | 1 + 3 files changed, 77 insertions(+), 16 deletions(-)
drivers/net/ethernet/realtek/r8169.h +1 -0
@@ -68,6 +68,7 @@ enum mac_version {/* support for RTL_GIGA_MAC_VER_60 has been removed */ RTL_GIGA_MAC_VER_61 ,RTL_GIGA_MAC_VER_63 , +RTL_GIGA_MAC_VER_65 , RTL_GIGA_MAC_NONE };
drivers/net/ethernet/realtek/r8169_main.c +75 -16
226 lines not on this page · raw message
drivers/net/ethernet/realtek/r8169_phy_config.c +1 -0
@@ -1152,6 +1152,7 @@ void r8169_hw_phy_config(struct rtl8169_private *tp, struct phy_device *phydev, [RTL_GIGA_MAC_VER_53] = rtl8117_hw_phy_config, [RTL_GIGA_MAC_VER_61] = rtl8125a_2_hw_phy_config, [RTL_GIGA_MAC_VER_63] = rtl8125b_hw_phy_config, + [RTL_GIGA_MAC_VER_65] = NULL, };if (phy_configs[ver])
Signature · 1 line
2.43.0