R8168H Enabling RSS on Linux Help

My motherboard has a Realtek R8168H. According to their product page, it, “[s]upports quad core Receive-Side Scaling (RSS)”. This means it can have up to four receive queues and spread the load across multiple cores on my CPU.

Whenever using the ethtool command to check for the queues, I get:

hurricane@TheCloutPC ~ $ sudo ethtool -l enp34s0 
[sudo] password for hurricane: 
netlink error: Operation not supported
hurricane@TheCloutPC ~ $ 

So, I went ahead and installed the proprietary r8168 driver with RSS support turned on via the Makefile:

hurricane@TheCloutPC ~ $ ethtool -l enp34s0 
Channel parameters for enp34s0:
Pre-set maximums:
RX:             4
TX:             2
Other:          n/a
Combined:       n/a
Current hardware settings:
RX:             1
TX:             1
Other:          n/a
Combined:       n/a
hurricane@TheCloutPC ~ $ sudo ethtool -L enp34s0 rx 4
netlink error: Operation not supported
hurricane@TheCloutPC ~ $ sudo ethtool -L enp34s0 tx 2
netlink error: Operation not supported
hurricane@TheCloutPC ~ $ sudo ethtool -L enp34s0 combined 2
netlink error: Operation not supported

As shown above, I can’t actually go ahead and enable the feature, which is rather frustrating.

I was wondering if anyone here knew any ways to do so? I wanna use the hardware I already have—I know getting like a modern Intel NIC, Marvell, or even the Realtek R8127 (which just got upstream r8169 RSS support according to the Linux git repo) would give me RSS.

Edit: For those not aware, RSS is a feature that allows multiple cores be used for interrupts whenever receiving packets. This prevents bottlenecks stemming from an overloaded core, as far as I understand it.

1 Like

Not supported through ethtool. They’re compile-time options.

You have to change dkms.conf to include ENALBE_MULTI_TX_QUEUE and ENABLE_RSS_SUPPORT. Also append r8168_rss.o to the obj list. Like this:

diff --git a/dkms.conf b/dkms.conf
index 025f998..3f9a350 100644
--- a/dkms.conf
+++ b/dkms.conf
@@ -1,6 +1,6 @@
 PACKAGE_NAME="@PKGNAME@"
 PACKAGE_VERSION="@PKGVER@"
-MAKE[0]="make -C $kernel_source_dir M=$dkms_tree/$module/$module_version/build/src EXTRA_CFLAGS='-DCONFIG_R8168_NAPI=y -DCONFIG_R8168_VLAN=y -DCONFIG_ASPM=y -DENABLE_S5WOL=y -DENABLE_EEE=y -DCONFIG_DYNAMIC_ASPM=y -DENABLE_GIGA_LITE=y -DENABLE_USE_FIRMWARE_FILE' r8168-objs='r8168_n.o r8168_asf.o rtl_eeprom.o rtltool.o r8168_firmware.o' modules"
+MAKE[0]="make -C $kernel_source_dir M=$dkms_tree/$module/$module_version/build/src EXTRA_CFLAGS='-DCONFIG_R8168_NAPI=y -DCONFIG_R8168_VLAN=y -DCONFIG_ASPM=y -DENABLE_S5WOL=y -DENABLE_EEE=y -DCONFIG_DYNAMIC_ASPM=y -DENABLE_USE_FIRMWARE_FILE -DENABLE_MULTIPLE_TX_QUEUE -DENABLE_RSS_SUPPORT' r8168-objs='r8168_n.o r8168_asf.o rtl_eeprom.o rtltool.o r8168_firmware.o r8168_rss.o' modules"
 BUILT_MODULE_NAME[0]="@PKGNAME@"
 BUILT_MODULE_LOCATION[0]="src/"
 DEST_MODULE_LOCATION[0]="/kernel/drivers/net/ethernet/realtek"

RSS in r8168 seems broken for Linux 7.2 due to hardened NAPI and restructured GRO layer.