Laptop freezes after updated to kernel 6.4.X

Hi there! I’m using Fedora 38 KDE and have been experiencing some issues with my system. After updating kernel from version 6.3.12 to 6.4.X, my system has been freezing after about an hour or two of use. The only solution is to perform a hard reset, as nothing else seems to work. I’ve checked the logs in systemctl, but there are no entries around the time of the crash. The errors in the log files are the same across kernel versions 6.3.12 and newer ones, but there are two errors related to the wifi module that occur multiple times from boot until the system crashes.

wpa_supplicant[1249]: nl80211: kernel reports: key addition failed
wpa_supplicant[1249]: TDLS: Failed to set TPK to the driver

These errors didn’t cause any problems in kernel 6.3.12 and older kernels.

I tried turning off wifi and using an ethernet cable instead, and this seemed to fix the issue - the errors was gone and my system worked fine without any freezes. So, I think these errors might be causing the kernel to crash. I checked multiple log files and it seems that the crash happens 2 or 3 minutes after these errors occur exactly 13 times.

Is there any way to prevent these errors or stop the kernel from freezing? Thanks for your help!

Network controller: Intel Dual BandWireless-AC 7265 802.11 ac 1x1 WiFi + BT 4.0 Combo

lspci -nnk output:

08:00.0 Network controller [0280]: Intel Corporation Wireless 7265 [8086:095a] (rev 61)
        DeviceName: Intel Dual BandWireless-AC 7265 802.11 ac 1x1 WiFi + BT 4.0 Combo Adapter
        Subsystem: Intel Corporation Dual Band Wireless-AC 7265 [Stone Peak 2 AC] [8086:5010]
        Kernel driver in use: iwlwifi
        Kernel modules: iwlwifi

possibly by getting the correct or updated driver.
We cannot tell exactly which card & chipset is installed with that info.

Please post the output of lspci -nnk and then show us the portion that relates to the wifi card. It should look something like this

05:00.0 Network controller [0280]: Intel Corporation Wi-Fi 6 AX210/AX211/AX411 160MHz [8086:2725] (rev 1a)
	Subsystem: Intel Corporation Wi-Fi 6 AX210 160MHz [8086:0024]
	Kernel driver in use: iwlwifi
	Kernel modules: iwlwifi

thanks for reply I updated post with output.

This sounds similar to an issue I had with an older wifi adapter (mine was a qualcom) that had been working fine and had no issues of any kind until about the time of the kernel 6.4 release.
It began having similar behavior as you describe and I finally wound up just replacing it with a newer intel wifi card. My crashes seemed caused by cpu hangs and freezes that eventually caused a machine check and reboot. I was getting a crash report every time it happened.

Replacing the adapter solved the issue entirely.

More detail about the events may be seen by using journalctl -b -1 to see the last boot logs. The number -1, -2, etc in that command show which boot before the current to select the logs for.

Edited to use the intended details of the wifi hardware:

Searching with Intel Corporation Wireless 7265 [8086:095a] (rev 61) gives many hits for cards with PCI Id’s like ?id=pci:8086-095a-8086-NNNN. You should run lspci -d 8086:095a -nn -vv. This will produce a line of the form:

Subsystem: <some_text> [8086:NNNN]

If the Linux Hardware Database has scans for your hardware, you can see whether it is working for others, and sometimes there will be links to alternative drivers or patches.

Intel Drivers iwlwifi has notes on various common issues.

Note that I am not having a problem. I only posted that as an example to assist the OP in locating the requested info.

Sorry – should have pasted from the OP’s lspci -nnk output. I’ll edit my post.

thanks I’ve already checked journalctl but unfortunately, I couldn’t find anything related to the crash other than those two events that keep repeating.

Thanks. I checked for an alternative driver but couldn’t find one. Other people seem to have no problem with newer versions of Fedora. Apart from the crash problem, my wifi works fine and it runs correctly. I have seen these events in journalctl in older versions kernel too, but they never caused any problems.

Mine ran fine as well, except it began showing repeated connect – disconnect – connect cycles in dmesg and journalctl. The card showed no errors, logs showed no errors, but the unstable connection was my clue that it was wifi related.

Update: I discovered that wpa_supplicant was attempting to establish a direct connection with my phone using Tunneled Direct Link Setup (TDLS), but it was unsuccessful. After several attempts, it appears that a memory overflow occurred, causing the kernel to crash. I believe that there may be a bug in either wpa_supplicant or the kernel, as this should not cause the kernel to crash. I came across this post describing a similar events with wpa_supplicant and they suggested switching to iwd. I followed their advice and everything is now working fine.