How to disable ASPM for a certain PCIe device?

I have a rtl8821ce realtek network card and it drops connection every now and then. I suspect it could be because of ASPM. What am I supposed to edit/do to disable ASPM for it?

You can try using a kernel parameter.

pcie_aspm=off

How I hate effing AI-translated and -generated top search engine hits…

perplexity telling the following about this parameter:

The kernel parameter pcie_aspm=off does not actually disable PCIe Active State Power Management (ASPM). Instead, it instructs the Linux kernel to leave ASPM settings untouched, meaning it will not change or override any ASPM configuration that was set by the system firmware (BIOS/UEFI).

In other words, with pcie_aspm=off, the kernel ignores ASPM configuration and keeps whatever the firmware has already set. This was clarified in recent kernel documentation updates (Linux kernel 6.9+). Previously this parameter was believed to disable ASPM, but that is no longer the case.

kernel docs say:

 pcie_aspm=      [PCIE] Forcibly enable or ignore PCIe Active State Power
                        Management.
                off     Don't touch ASPM configuration at all.  Leave any
                        configuration done by firmware unchanged.
                force   Enable ASPM even on devices that claim not to support it.
                        WARNING: Forcing ASPM on may cause system lockups.

If you really want to turn of aspm only for your GPU you could give proper parameters to the driver module. E.g.

Also from perplexity:

options rtw88_pci disable_aspm=y
options rtw88_core disable_lps=y

disable_aspm=y disables ASPM.
disable_lps=y disables low power state to avoid power management issues that can cause drops.

It’s not the GPU. It’s the network or wireless card they are referring to. :thinking:

sorry, thats what I mean. rtw88_pci is the network driver for your device.

1 Like

You can also try setting this kernel parameter

pcie_aspm.policy=performance

instead of telling the kernel to ignore it.

To check the current policy run

cat /sys/module/pcie_aspm/parameters/policy

Also don’t forget run sudo reinstall-kernels if you are using dracut befor rebooting so the kernel paramaters actually get applied.

To check if any PCI devices have ASPM enabled you can run

sudo lspci -vvv | grep "ASPM .*abled"

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.