iwlwifi Wifi Microcode SW error detected (Ubuntu 18.04 x64)

Solution 1:

Try to create a configuration file, like so:

echo "options cfg80211 cfg80211_disable_40mhz_24ghz=Y" > /etc/modprobe.d/cfg80211.conf

Solution 2:

Had similar issues with Wi-Fi Link 5100. The firmware (reliably) hangs when performing iperf3 transmit tests. The solution was to disable TX aggregation.

options iwlwifi 11n_disable=2

Other answers on the internet suggest using 11n_disable=1 but that disables 802.11n entirely.