Wi-Fi Kernel Module Blacklisting method.


✅ Disable Wi-Fi Using Kernel Module Blacklisting

This will completely disable Wi-Fi by preventing the kernel from loading the Wi-Fi driver.

1️⃣ Create a blacklist file:

echo "blacklist xradio_wlan" | sudo tee /etc/modprobe.d/disable-wifi.conf

2️⃣ Unload the Wi-Fi driver immediately:

sudo modprobe -r xradio_wlan

3️⃣ Check if the module is gone:

lsmod | grep xradio
  • If there is no output, Wi-Fi is disabled. ✅
  • If the module still appears, a reboot is needed.

4️⃣ Rebuild the kernel initramfs (optional, but recommended):

sudo update-initramfs -u

5️⃣ Reboot to apply the changes:

sudo reboot

6️⃣ After reboot, verify Wi-Fi is disabled:

nmcli device status

wlan0 should not appear anymore.


🛠 If You Want to Re-enable Wi-Fi Later

Simply delete the blacklist file:

sudo rm /etc/modprobe.d/disable-wifi.conf
sudo update-initramfs -u
sudo reboot

Then manually load the driver:

sudo modprobe xradio_wlan