[SRU][R][Unstable][PATCH 1/2] UBUNTU: SAUCE: r8169: enable ASPM on all new Dell platforms
AceLan Kao
acelan.kao at canonical.com
Mon Dec 15 05:04:54 UTC 2025
From: "Chia-Lin Kao (AceLan)" <acelan.kao at canonical.com>
BugLink: https://bugs.launchpad.net/bugs/2121200
By default the r8169 driver disables ASPM feature to avoid random link
failures and system hangs on problematic systems. Dell's new models will
be verified to work reliably with RTL NIC PCIe ASPM feature is enabled.
And Dell will push RTL to fix any issues result from the ASPM.
So, this patch enables the RTL NIC ASPM feature, and the listed product
family names are only used in the new Dell platforms.
Signed-off-by: Chia-Lin Kao (AceLan) <acelan.kao at canonical.com>
(cherry picked from commit https://lore.kernel.org/lkml/20250912072939.2553835-1-acelan.kao@canonical.com/)
Signed-off-by: Chia-Lin Kao (AceLan) <acelan.kao at canonical.com>
Acked-by: Kuan-Ying Lee <kuan-ying.lee at canonical.com>
Signed-off-by: Kuan-Ying Lee <kuan-ying.lee at canonical.com>
---
drivers/net/ethernet/realtek/r8169_main.c | 30 +++++++++++++++++++++++
1 file changed, 30 insertions(+)
diff --git a/drivers/net/ethernet/realtek/r8169_main.c b/drivers/net/ethernet/realtek/r8169_main.c
index e5427dfce2680..7fdb594ae4dcf 100644
--- a/drivers/net/ethernet/realtek/r8169_main.c
+++ b/drivers/net/ethernet/realtek/r8169_main.c
@@ -15,6 +15,7 @@
#include <linux/etherdevice.h>
#include <linux/clk.h>
#include <linux/delay.h>
+#include <linux/dmi.h>
#include <linux/ethtool.h>
#include <linux/phy.h>
#include <linux/if_vlan.h>
@@ -5366,6 +5367,32 @@ static void rtl_init_mac_address(struct rtl8169_private *tp)
rtl_rar_set(tp, mac_addr);
}
+static bool rtl_aspm_new_dell_platforms(void)
+{
+ const char *family = dmi_get_system_info(DMI_PRODUCT_FAMILY);
+ static const char * const dell_product_families[] = {
+ "Alienware",
+ "Dell Laptops",
+ "Dell Pro Laptops",
+ "Dell Pro Max Laptops",
+ "Dell Desktops",
+ "Dell Pro Desktops",
+ "Dell Pro Max Desktops",
+ "Dell Pro Rugged Laptops"
+ };
+ int i;
+
+ if (!family)
+ return false;
+
+ for (i = 0; i < ARRAY_SIZE(dell_product_families); i++) {
+ if (str_has_prefix(family, dell_product_families[i]))
+ return true;
+ }
+
+ return false;
+}
+
/* register is set if system vendor successfully tested ASPM 1.2 */
static bool rtl_aspm_is_safe(struct rtl8169_private *tp)
{
@@ -5373,6 +5400,9 @@ static bool rtl_aspm_is_safe(struct rtl8169_private *tp)
r8168_mac_ocp_read(tp, 0xc0b2) & 0xf)
return true;
+ if (rtl_aspm_new_dell_platforms())
+ return true;
+
return false;
}
--
2.43.0
More information about the kernel-team
mailing list