Ubuntu 24.04 on the Framework 13 Ryzen AI 300 Series

Ok, I’ve just found a workaround to resolve the issue.

If I do sudo modprobe -r iwlwifi before I put the system to sleep, then it resumes successfully.

Afterwards I’m able to bring the wifi back using sudo modprobe iwlwifi.

So indeed, the issue was with the driver not handling resume properly.

Probably need to put this line into suspend/resume scripts.

Update: For some reason that workaround worked only yesterday and today everything broke in another fashion.

Now the system boots, but wifi fails to get back from the state with the message similar to:

iwlwifi 0000:01:00.0: Unable to change power state from D3COLD to D0, device inaccessible

In the end I resolved the issue by disabling power PCIe management using kernel argument pcie_port_pm=off

I was now able to bring the system from the sleep without messing with the modules, and wifi worked.

Obviously the workaround would probably negatively affect the battery life.

Update 2: Nope, still no luck. The trick with pcie_port_pm=off works, but only once.

The first suspend/resume cycle works as intended, but then the second one breaks NVMe access, so even ls in a terminal causes Input/Output error.

Sigh.

Update 3: I gave up and swapped the WiFi card to a non-intel one (RTL8822BE).

But even then I had the same device inaccessible message. That makes me think that the issue is not caused by the driver, but the mainboard itself.

Finally (?) solved by disabling PM using driver setting:

echo "options rtw_pci disable_aspm=Y"  | sudo tee  /etc/modprobe.d/rtw_pci.conf