Thread (11 messages) flat view 11 messages, 2 authors, 2026-07-03

RE: [PATCH rtw-next v3 1/3] wifi: rtlwifi: fix disabling of ASPM for RTL8723BE with AER flooding

From: Ping-Ke Shih <pkshih@realtek.com>
Date: 2026-06-29 01:59:45
Also in: lkml

William Hansen-Baird [off-list ref] wrote:
commit 77a6407c6ab2 ("wifi: rtlwifi: disable ASPM for RTL8723BE with subsystem ID 11ad:1723")
adds code which sets ppsc->support_aspm to false in
_rtl_pci_update_default_setting() in order to disable ASPM.
This does not, however, disable ASPM. Rather, it disables driver
control of ASPM, and blocks calls to rtl_pci_enable_aspm()
and rtl_pci_disable_aspm().

In some cases, the pci device supplied to the probe function has
ASPM enabled. The code would therefore not disable ASPM, as it means to,
but rather just leave it enabled.
This was discovered through testing on a Razer Blade 14 2017.

Implement a new __rtl_pci_disable_aspm(hw) function which does not check
ppsc->support_aspm before disabling and call it from
rtl_pci_disable_aspm().

Then move the code added in the previous commit to rtl_pci_init_aspm() to
allow adding a call to __rtl_pci_disable_aspm(hw).
This makes sure ASPM is disabled while still disabling
driver control of ASPM to block it from being enabled later.

Signed-off-by: William Hansen-Baird <redacted>
A minor warning. Otherwise, looks good to me.

Acked-by: Ping-Ke Shih <pkshih@realtek.com>

quoted hunk ↗ jump to hunk
@@ -330,10 +328,25 @@ static void rtl_pci_parse_configuration(struct pci_dev *pdev,

 static void rtl_pci_init_aspm(struct ieee80211_hw *hw)
 {
+       struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
        struct rtl_ps_ctl *ppsc = rtl_psc(rtl_priv(hw));
+       struct rtl_priv *rtlpriv = rtl_priv(hw);

        _rtl_pci_update_default_setting(hw);

+       /*
.git/rebase-apply/patch:71: trailing whitespace.
        /*
warning: 1 line adds whitespace errors.
+        * RTL8723BE found on some ASUSTek laptops, such as F441U and
+        * X555UQ with subsystem ID 11ad:1723 are known to output large
+        * amounts of PCIe AER errors during and after boot up, causing
+        * heavy lags, poor network throughput, and occasional lock-ups.
+        */
+       if (rtlpriv->rtlhal.hw_type == HARDWARE_TYPE_RTL8723BE &&
+           (rtlpci->pdev->subsystem_vendor == 0x11ad &&
+            rtlpci->pdev->subsystem_device == 0x1723)) {
+               __rtl_pci_disable_aspm(hw);
+               ppsc->support_aspm = false;
+       }
+
        if (ppsc->reg_rfps_level & RT_RF_PS_LEVEL_ALWAYS_ASPM) {
                /*Always enable ASPM & Clock Req. */
                rtl_pci_enable_aspm(hw);
--
2.54.0
  
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help