I have a dell xps m1530 laptop, and it's a little dated, the physical wifi switch is broken, can not be switched on, so I bought a usb wifi dongle, but it didn't work, the network-manager detected that both the internal and usb wifi is switch off by the hardware switch, but it worked perfectly under windows, so I wonder how to bypass the hardware switch when using the usb wifi.
2 Answers
I had a very similar issue with an old Sony Vaio. Having tried rfkill options I could see that the built in wi-fi adapter was hardware blocked (the switch stopped working Loooooong ago) but there were no such blocks on my USB wi-fi dongle even though my connections menu showed that both were disabled by a hardware switch.
Additionally, I even tried checking my BIOS to try to disable the hardware in general.
I finally found that blacklisting the built in hardware seemed to do the trick. Unfortunately, the process had to be pieced together by researching a bunch of different subjects as I could not find one set of steps to do this. Here's how I found the module to disable and how to blacklist it
Use the following command in Terminal to get a list of hardware modules in use:
lspci -v
Scroll through the list until you find the appropriate hardware
Note the exact value named after the line beginning with
Kernel driver in use:
In Terminal, use the following command line to edit your blacklist
sudo nano /etc/modprobe.d/blacklist.conf
At the bottom of the blacklist, insert a new entry following the convention of the ones above. I included a comment in mine for future reference. (Could not get this to blockquote correctly...there are not actually spaces between each line in my blocklist)
#
Built in Wireless adapter hardware switch will not turn on. Disables
#
USB wifi adapter. Hopefully blacklisting will prevent this from happening.blacklist iwl3945
Save the blacklist.conf file
Reboot
At this point, my built in Wi-Fi adapter is not loading at all and all I see with rfkill list is as follows (Only one wireless adapter!), and I am able to connect to my wireless network correctly.
0: phy0: Wireless LAN
Soft blocked: no
Hard blocked: no
Hope that helps!
-
1Thanks, man! Indeed, that was quite nontrivial and it looks more like a bug in NetworkManager or its controlling UI that states that all wireless adapter are not available when only one is in state "Hard blocked: yes"– GreyCatMar 2, 2014 at 6:46
Install all the necessary compilation tools at first and download the latest driver from its git repository:
$$ sudo apt-get install build-essential linux-headers-generic git
$$ mkdir ~/RTL8188EU
$$ cd ~/RTL8188EU
$$ git clone git://github.com/lwfinger/rtl8188eu.git
Afterwards, the driver can be compiled and installed:
Go into the folder and execute following commands.
$$ make
$$ sudo make install
The new kernel module can be loaded via modprobe and can be installed system-wide for automatic loading:
$$ sudo depmod -a
$$ sudo update-initramfs -u
$$ sudo modprobe 8188eu
(Automatic boot:) To enable the module at each boot add your module to /etc/modules
$$ echo 8188eu >> /etc/modules
Run command
$$ lspci -v
and search for your built-in wifi card...
03:00.0 Network controller: Intel Corporation WiFi Link 5100 Subsystem: Intel Corporation WiFi Link 5100 AGN Flags: bus master, fast devsel, latency 0, IRQ 47 Memory at d6500000 (64-bit, non-prefetchable) [size=8K] Capabilities: [c8] Power Management version 3 Capabilities: [d0] MSI: Enable+ Count=1/1 Maskable- 64bit+ Capabilities: [e0] Express Endpoint, MSI 00 Capabilities: [100] Advanced Error Reporting Capabilities: [140] Device Serial Number 00-24-d6-ff-ff-3e-5e-a4 Kernel driver in use: iwlwifi
Now block that card....
$$ sudo echo "blacklist iwlwifi" >> /etc/modprobe.d/blacklist.conf
Now run
$$ lsmod | grep sony
replace sony with company name of your laptop....
Block your laptop (like for sony vaio it is "sony_laptop"....
$$ sudo echo "blacklist sony_laptop" >> /etc/modprobe.d/blacklist.conf
DONE..!!!
Now reboot... You will be able to run your wifi adapter even if your wireless switch is turned off....!!
sudo rfkill unblock all
, and enter your password when prompted. Then check if it works.