Difference between revisions of "Broadcom wireless"

From ArchWiki
Jump to: navigation, search
(Miscellaneous user notes: Added one case where the broadcom-wl driver works better than the brcmsmac one.)
m (Interface is showing but doesn't allow connections: remove contraction in heading; reword for slight clarity improvement)
(48 intermediate revisions by 27 users not shown)
Line 1: Line 1:
 
[[zh-CN:Broadcom wireless]]
 
[[zh-CN:Broadcom wireless]]
 
[[Category:Wireless Networking]]
 
[[Category:Wireless Networking]]
 
 
== Introduction ==
 
== Introduction ==
  
Line 12: Line 11:
 
At the time of writing, there are three choices for users with Broadcom Wi-Fi chipsets:
 
At the time of writing, there are three choices for users with Broadcom Wi-Fi chipsets:
  
{| class="wikitable" border="1" cellpadding="5" cellspacing="0"
+
{| class="wikitable"
 
! Driver !! Description
 
! Driver !! Description
 
|-
 
|-
|brcmsmac/brcmfmac || Open source kernel driver
+
|brcmsmac/brcmfmac || Open-source kernel driver
 
|-
 
|-
|b43 || Reversed engineered kernel driver
+
|b43 || Reverse-engineered kernel driver
 
|-
 
|-
 
|broadcom-wl || Proprietary Broadcom STA driver
 
|broadcom-wl || Proprietary Broadcom STA driver
Line 25: Line 24:
  
 
First, determine your card's [[Wikipedia:PCI_configuration_space|PCI-ID]]. Type the following (case-sensitive) command into a console:
 
First, determine your card's [[Wikipedia:PCI_configuration_space|PCI-ID]]. Type the following (case-sensitive) command into a console:
  $ lspci -vnn | grep 14e4
+
  $ lspci -vnn | grep 14e4:
  
If your card is in the following list, you can use the [[#brcmsmac.2Fbrcmfmac|{{ic|brcmsmac}} driver]]:
+
Then check your card against this [http://wireless.kernel.org/en/users/Drivers/b43#Supported_devices list of supported b43 devices] and this [http://wireless.kernel.org/en/users/Drivers/brcm80211#Supported_Chips list of supported brcm80211 devices].
{| border="1"
+
! PCI-ID !! Name
+
|-
+
| {{ic|[14e4:4727]}} || BCM4313
+
|-
+
| {{ic|[14e4:4353]}} || BCM43224
+
|-
+
| {{ic|[14e4:4357]}} || BCM43225
+
|}
+
If your card is in the following list, you can use the [[#brcmsmac.2Fbrcmfmac|{{ic|brcmfmac}} SDIO driver]]:
+
{| border="1"
+
! Name
+
|-
+
| BCM4329
+
|}
+
A more up-to-date list may be found [http://linuxwireless.org/en/users/Drivers/brcm80211 here].
+
 
+
If your card is not in the above lists, you need to use the older {{ic|b43}} or {{ic|b43legacy}} driver, which supports following devices.
+
{| border="1"
+
! PCI-ID !! Name !! Notes
+
|-
+
| {{ic|[14e4:4301]}} || BCM4301 || legacy-only
+
|-
+
| {{ic|[14e4:4306]}} || BCM4306 || <s>?legacy</s>
+
|-
+
| {{ic|[14e4:4307]}} || BCM4306 ||
+
|-
+
| {{ic|[14e4:4311]}} || BCM4311 ||
+
|-
+
| {{ic|[14e4:4312]}} || BCM4311 ||
+
|-
+
| {{ic|[14e4:4313]}} || BCM4311 ||
+
|-
+
| {{ic|[14e4:4315]}} || BCM4312 || Not in kernel26-lts
+
|-
+
| {{ic|[14e4:4318]}} || BCM4318 ||
+
|-
+
| {{ic|[14e4:4319]}} || BCM4318 ||
+
|-
+
| {{ic|[14e4:4320]}} || BCM4306 || ?legacy
+
|-
+
| {{ic|[14e4:4321]}} || BCM4321 || Not in kernel26-lts
+
|-
+
| {{ic|[14e4:4324]}} || BCM4306 || legacy-only
+
|-
+
| {{ic|[14e4:4325]}} || BCM4306 || legacy-only
+
|-
+
| {{ic|[14e4:4328]}} || BCM4321 || Not in kernel26-lts
+
|-
+
| {{ic|[14e4:4329]}} || BCM4321 || Not in kernel26-lts
+
|-
+
| {{ic|[14e4:432a]}} || BCM4321 ||
+
|-
+
| {{ic|[14e4:432b]}} || BCM4322 || Not in kernel26-lts
+
|-
+
| {{ic|[14e4:432c]}} || BCM4322 ||
+
|-
+
| {{ic|[14e4:432d]}} || BCM4322 ||
+
|-
+
| {{ic|[14e4:4359]}} || BCM43228 ||
+
|}
+
?legacy means that there are devices with same PCI-IDs, but with different hardware available.
+
Some of these work with the {{ic|b43}} driver, but some might need {{ic|b43legacy}} driver.
+
legacy-only means that you need to use the {{ic|b43legacy}} driver.
+
 
+
A more up-to-date list may be found [http://linuxwireless.org/en/users/Drivers/b43 here].
+
 
+
If your card is in the following list, you can use the [[#broadcom-wl|{{ic|broadcom-wl}} driver]]:
+
{| border="1"
+
! PCI-ID !! Name
+
|-
+
| {{ic|[14e4:4311]}} || BCM4311
+
|-
+
| {{ic|[14e4:4312]}} || BCM4311
+
|-
+
| {{ic|[14e4:4313]}} || BCM4311
+
|-
+
| {{ic|[14e4:4315]}} || BCM4312
+
|-
+
| {{ic|[14e4:4727]}} || BCM4313
+
|-
+
| {{ic|[14e4:4328]}} || BCM4321
+
|-
+
| {{ic|[14e4:4329]}} || BCM4321
+
|-
+
| {{ic|[14e4:432a]}} || BCM4321
+
|-
+
| {{ic|[14e4:432b]}} || BCM4322
+
|-
+
| {{ic|[14e4:432c]}} || BCM4322
+
|-
+
| {{ic|[14e4:432d]}} || BCM4322
+
|-
+
| {{ic|[14e4:4353]}} || BCM43224
+
|-
+
| {{ic|[14e4:4357]}} || BCM43225
+
|-
+
| {{ic|[14e4:4358]}} || BCM43227
+
|-
+
| {{ic|[14e4:4359]}} || BCM43228
+
|}
+
A more up-to-date list may be found [http://www.broadcom.com/docs/linux_sta/README.txt here].
+
 
+
 
+
If your card is in the following list, you should use broadcom-wl in version 6.20.55.19 (or later), which may be found [https://aur.archlinux.org/packages.php?ID=62666 in AUR]
+
(more informations about this package can be found [https://bbs.archlinux.org/viewtopic.php?id=145884 here]).
+
{| border="1"
+
! PCI-ID !! Name
+
|-
+
| {{ic|[14e4:4365]}} || BCM43142
+
|}
+
  
 
== Getting the driver ==
 
== Getting the driver ==
  
 
=== brcmsmac/brcmfmac ===
 
=== brcmsmac/brcmfmac ===
The {{ic|brcm80211}} drivers have been included in the kernel since 2.6.37. Since the release of 2.6.39, they have been renamed to {{ic|brcmsmac}} (for PCI cards) and {{ic|brcmfmac}} (for SDIO).
+
The {{ic|brcm80211}} drivers are included in the kernel. They are named {{ic|brcmsmac}} for PCI cards and {{ic|brcmfmac}} for SDIO devices.
 
+
These drivers should be automatically loaded during startup and no further action should be required of the user. If the driver doesn't auto load, try the following commands.
+
# modprobe brcmsmac
+
or
+
# modprobe brcmfmac
+
  
{{Note|The {{ic|bcma}} module can prevent some cards from showing up and may need to be [[#Wi-Fi_card_does_not_work.2Fshow_up_since_kernel_upgrade_.28brcmsmac.29|blacklisted]].}}
+
These drivers should be automatically loaded during start-up and no further action should be required of the user. If the driver does not load automatically, simply [[Kernel modules#Loading|load]] it manually.
  
{{Note|Since linux 3.3.1 the {{ic|brcmsmac}} driver depends on the {{ic|bcma}} module and blacklisting is no longer required.}}
+
{{Note|1=Since {{pkg|linux}}>=3.3.1, the {{ic|brcmsmac}} driver depends on the {{ic|bcma}} module; therefore, make sure the {{ic|bcma}} module is not [[Kernel_modules#Blacklisting|blacklisted]].}}
  
{{Note|[http://wireless.kernel.org/en/users/Drivers/brcm80211 wireless.kernel.org] states that brcm80211 does not support older PCI/PCI-E chips with ssb backplane.}}
+
{{Note|[http://wireless.kernel.org/en/users/Drivers/brcm80211 wireless.kernel.org] states that brcm80211 does not support older PCI/PCI-E chips with SSB backplane.}}
  
 
=== b43/b43legacy ===
 
=== b43/b43legacy ===
Line 160: Line 43:
  
 
==== Loading the b43/b43legacy kernel module ====
 
==== Loading the b43/b43legacy kernel module ====
Verify which module you need by looking up your device [http://wireless.kernel.org/en/users/Drivers/b43#Known_PCI_devices here]. You can also check by computer model [http://linuxwireless.org/en/users/Drivers/b43/devices here]. Blacklist the other module (either {{ic|b43}} or {{ic|b43legacy}}) to prevent possible problems/confusion. For instructions, see [[Kernel_modules#Blacklisting]].
+
Verify which module you need by looking up your device [http://wireless.kernel.org/en/users/Drivers/b43#Known_PCI_devices here]. You can also check by computer model [http://wireless.kernel.org/en/users/Drivers/b43/devices here]. Blacklist the other module (either {{ic|b43}} or {{ic|b43legacy}}) to prevent possible problems/confusion. For instructions, see [[Kernel_modules#Blacklisting]].
  
 
Install the appropriate {{AUR|b43-firmware}} or {{AUR|b43-firmware-legacy}} package from the [[AUR]].
 
Install the appropriate {{AUR|b43-firmware}} or {{AUR|b43-firmware-legacy}} package from the [[AUR]].
  
You can now configure your device.
+
If you have a low-power version of a b43-supported device, you will need to install special firmware. A quick way to check whether you have a low-power chip is by running {{ic|<nowiki>lspci | grep Broadcom | grep LP-PHY</nowiki>}}. You can install it by downloading [http://downloads.openwrt.org/sources/broadcom-wl-4.178.10.4.tar.bz2 the appropriate package] and using {{ic|b43-fwcutter}} as outlined below, or by using [https://github.com/dbb/scripts/blob/master/b43-lp-installer this installation script].
 +
 
 +
To install the LP-PHY firmware, perform the following:
 +
{{bc|<nowiki>curl -LO http://downloads.openwrt.org/sources/broadcom-wl-4.178.10.4.tar.bz2
 +
tar xjf broadcom-wl-4.178.10.4.tar.bz2
 +
cd broadcom-wl-4.178.10.4/linux
 +
b43-fwcutter -w /lib/firmware wl_apsta.o</nowiki>}}
 +
 
 +
After installing the firwmare, you can now configure your device.
 +
 
 +
{{Note|1=If the b43 module appears to be loaded and functional but the device is inaccessible, you may need to [[Kernel_modules#Blacklisting|blacklist]] the {{ic|bcma}} module.  See [[Broadcom_wireless#Wi-Fi_card_does_not_work_or_show_up_after_kernel_upgrade_.28brcmsmac.29|Section 4.1]]. If that does not help, you might have to recompile the kernel with the {{ic|CONFIG_B43_BCMA_EXTRA}} option set to use b43. This option was introduced to avoid race conditions between the modules and is at least needed for cards with the BCM4322, BCM43224 and BCM43225 chipsets.}}
  
 
=== broadcom-wl ===
 
=== broadcom-wl ===
{{Warning|Even though this driver has matured a lot throughout the years and works quite good nowadays, it's usage is recommended only when none of the two opensource drivers support your device. Please refer to project [http://linuxwireless.org/en/users/Drivers/b43/#Supported_devices b43's] page for list of supported devices.}}
+
{{Warning|Even though this driver has matured a lot throughout the years and works quite well now, its usage is recommended only when neither of the two open-source drivers support your device. Please refer to project [http://linuxwireless.org/en/users/Drivers/b43/#Supported_devices b43's] page for list of supported devices.}}
For users of the {{ic|broadcom-wl}} driver, there is a PKGBUILD available in the AUR ({{AUR|broadcom-wl}}). You can also download this driver directly from [http://www.broadcom.com/support/802.11/linux_sta.php Broadcom]. However, the PKGBUILD method is strongly encouraged, as that way will have [[pacman]] track all of the files.
+
For users of the {{ic|broadcom-wl}} driver, there is a PKGBUILD available in the [[Arch User Repository|AUR]] named {{AUR|broadcom-wl}}. There is also a newer version available (supporting more recent cards), see {{AUR|broadcom-wl-dkms}}.
  
 
==== Loading the wl kernel module ====
 
==== Loading the wl kernel module ====
Line 191: Line 84:
 
  # depmod -a
 
  # depmod -a
  
To make the module load at boot, add {{ic|wl}} (and {{ic|lib80211}}/{{ic|lib80211_crypt_tkip}}, if needed) to your MODULES array in {{ic|/etc/rc.conf}}.
+
To make the module load at boot, refer to [[Kernel modules]].
MODULES=(... wl...)
+
  
You can also blacklist other modules (to prevent them from interfering) in {{ic|/etc/modprobe.d/modprobe.conf}}. To blacklist a module just append a new line with the syntax {{ic|blacklist <module name>}}:
+
You can also blacklist other modules (to prevent them from interfering) in {{ic|/etc/modprobe.d/modprobe.conf}}. To blacklist a module, refer to [[Kernel modules#Blacklisting]].
blacklist b43
+
blacklist ssb
+
  
{{Warning|Broadcom Corporation BCM4311 802.11b/g WLAN [14e4:4311] does not work with blacklisting {{ic|b43}} and {{ic|ssb}}.}}
+
{{Note|Broadcom Corporation BCM4311 802.11b/g WLAN [14e4:4311] does not work with blacklisting {{ic|b43}} and {{ic|ssb}}.}}
  
 
== Troubleshooting ==
 
== Troubleshooting ==
 +
=== Wi-Fi card does not seem to even exist ===
 +
 +
{{Expansion|no solution provided}}
 +
 +
Some users with newer cards like the Broadcom BCM43241 will experience an issue where lspci or lsusb will not show any trace of the card. A solution to this will be posted when found.
 +
 
=== Wi-Fi card does not work or show up after kernel upgrade (brcmsmac) ===
 
=== Wi-Fi card does not work or show up after kernel upgrade (brcmsmac) ===
  
Line 219: Line 115:
  
 
=== Interfaces swapped (broadcom-wl) ===
 
=== Interfaces swapped (broadcom-wl) ===
Users of the {{ic|broadcom-wl}} driver may find their Ethernet and Wi-Fi interfaces have been swapped. The [http://wiki.archlinux.org/index.php/Udev#Mixed_Up_Devices.2C_Sound.2FNetwork_Cards_Changing_Order_Each_Boot udev] page explains how to resolve this. Create a file named {{ic|/etc/udev/rules.d/10-network.rules}} and bind the MAC address of each of your cards to a certain interface name:
+
Users of the {{ic|broadcom-wl}} driver may find their Ethernet and Wi-Fi interfaces have been swapped. See [[Network configuration#Device_names]] for solution.
SUBSYSTEM=="net", ATTR{address}=="aa:bb:cc:dd:ee:ff", NAME="eth0"
+
SUBSYSTEM=="net", ATTR{address}=="ff:ee:dd:cc:bb:aa", NAME="eth1"
+
  
Ensure that the interface name appears correctly in {{ic|/etc/rc.conf}} and other configuration files that refer to it.
+
=== The b43 driver and Linux 3.8+ ===
 +
The b43 driver has some major issues starting with the release of Linux 3.8+, namely that you are unable to see / connect to some access points.
 +
 
 +
Solution: Try the latest broadcom-wl driver (version 6+), see above.
 +
 
 +
=== Suppressing console messages ===
 +
 
 +
You may continuously get some verbose and annoying messages during the boot, similar to
 +
 
 +
phy0: brcms_ops_bss_info_changed: arp filtering: enabled true, count 0 (implement)
 +
phy0: brcms_ops_bss_info_changed: qos enabled: false (implement)
 +
phy0: brcms_ops_bss_info_changed: arp filtering: enabled true, count 1 (implement)
 +
enabled, active
 +
 
 +
These do not seem to be suppressible via normal means, such as setting {{ic|MaxLevelConsole}} in {{ic|/etc/systemd/journald.conf}}. To hide them, you must lower the level at which {{ic|dmesg}} messages are printed to the console. This can be done on start-up by creating a simple [[systemd]] service.
 +
 
 +
Create a file in {{ic|/etc/systemd/system/}} called {{ic|brcms_suppression.service}} or something similar:
 +
{{hc|brcms_suppression.service|
 +
<nowiki>
 +
[Unit]
 +
Description=Broadcom console message suppression script
 +
 
 +
[Service]
 +
Type=oneshot
 +
RemainAfterExit=yes
 +
ExecStart=/bin/sh -c 'dmesg -n 3'
 +
 
 +
[Install]
 +
WantedBy=multi-user.target
 +
</nowiki>
 +
}}
 +
 
 +
Like all other systemd services, you can then enable it with
 +
# systemctl enable brcms_suppression
 +
=== Interface is showing but does not allow connections ===
 +
 
 +
Append the following to your [[Kernel parameters|kernel command line]]:
 +
b43.allhwsupport=1
  
 
=== Miscellaneous user notes ===
 
=== Miscellaneous user notes ===
 +
{{Poor writing|This section must be rewritten impersonally, very likely as a FAQ or Troubleshooting section (also remove or update out-of-date information). See also [[Help:Style]].|section=Allowing user signatures on main article pages in limited situations?}}
 +
 
* In my Dell Inspiron Laptop, I have a Broadcom BCM4401 Ethernet card and a Broadcom BCM4328 wireless card. If I just remove {{ic|b43}}, I can load the {{ic|wl}} driver, but no wireless card shows up. However, if I first remove the {{ic|b44}} (and {{ic|ssb}}) driver for my Ethernet card, and ''then'' load the {{ic|wl}} driver, I get a wireless device using the name ''eth0''. Afterwards, I can load {{ic|b44}} again, to have an Ethernet ''eth1'' device.
 
* In my Dell Inspiron Laptop, I have a Broadcom BCM4401 Ethernet card and a Broadcom BCM4328 wireless card. If I just remove {{ic|b43}}, I can load the {{ic|wl}} driver, but no wireless card shows up. However, if I first remove the {{ic|b44}} (and {{ic|ssb}}) driver for my Ethernet card, and ''then'' load the {{ic|wl}} driver, I get a wireless device using the name ''eth0''. Afterwards, I can load {{ic|b44}} again, to have an Ethernet ''eth1'' device.
  
 
* I could not get the BCM4313 chip on a Lenovo B560 to work before following these steps:
 
* I could not get the BCM4313 chip on a Lenovo B560 to work before following these steps:
 
*# "Load defaults" in the BIOS. After that, the wireless was working under MS Windows. There are not many options in there, so I do not know what the reset may have changed, but it did the trick.
 
*# "Load defaults" in the BIOS. After that, the wireless was working under MS Windows. There are not many options in there, so I do not know what the reset may have changed, but it did the trick.
*# Blacklist the {{ic|acer_wmi}} module. For testing, you can add the following to the kernel line in GRUB: {{ic|acer_wmi.disable<nowiki>=</nowiki>1}}
+
*# Blacklist the {{ic|acer_wmi}} module. For testing, you can add the following to the kernel line in GRUB: {{ic|1=acer_wmi.disable=1}}
  
 
* I have found that to get the {{ic|wl}} drivers working for the Broadcom 4313 chip, you need to blacklist {{ic|brcm80211}} along with {{ic|b43}} and {{ic|ssb}}.
 
* I have found that to get the {{ic|wl}} drivers working for the Broadcom 4313 chip, you need to blacklist {{ic|brcm80211}} along with {{ic|b43}} and {{ic|ssb}}.
 +
:--[[User:Admiralspark|Admiralspark]], 20 June 2011
  
 
* If you notice slow wireless speeds when your laptop/netbook is not connected to AC power, you may need to disable Wi-Fi power management by adding the following line (assuming ''wlan0'' is your wireless device) {{ic|iwconfig wlan0 power off}} to {{ic|/etc/rc.local}} and create an empty file {{ic|/etc/pm/power.d/wireless}}. In case you also experience interface swapping (discussed above), you might want to add another line for the second interface name as well. The command will have no effect on the wired interface.
 
* If you notice slow wireless speeds when your laptop/netbook is not connected to AC power, you may need to disable Wi-Fi power management by adding the following line (assuming ''wlan0'' is your wireless device) {{ic|iwconfig wlan0 power off}} to {{ic|/etc/rc.local}} and create an empty file {{ic|/etc/pm/power.d/wireless}}. In case you also experience interface swapping (discussed above), you might want to add another line for the second interface name as well. The command will have no effect on the wired interface.
 +
:--[[User:Tom.yan|Tom.yan]], 16 August 2011
  
* In my case on a HP pavilion netbook DM1 with a BCM4313 chip, with the original kernel brcmsmac driver, the LED didn't work, the power was awful, and it kept loosing the signal all the time, unless very close to the wifi hotspot. The last broadcom driver {{ic|wl}} solved everything. So in some cases, it's actually better than the kernel driver. However, I had to install it in the initram image, along with lib80211 and lib80211_crypt_tkip to avoid a recurring kernel panic. (Use mkinitcpio)
+
* In my case on a HP pavilion netbook DM1 with a BCM4313 chip, with the original kernel brcmsmac driver, the LED didn't work, the power was awful, and it kept loosing the signal all the time, unless very close to the Wi-Fi hotspot. The last Broadcom driver {{ic|wl}} solved everything. So in some cases, it's actually better than the kernel driver. However, I had to install it in the [[Mkinitcpio|initramfs image]], along with lib80211 and lib80211_crypt_tkip to avoid a recurring kernel panic.  
 +
:--[[User:Ivanoff|Ivanoff]], 18 March 2012 *Edit* It's all solved with the latest kernel versions. --[[User:Ivanoff|Ivanoff]] ([[User talk:Ivanoff|talk]]) 14:19, 14 December 2013 (UTC)
  
* On a similar HP DM1 netbook I found the brcmsmac driver did not work either. The kernel panic can also be solved by blacklisting the brcmsmac, b43 and wl drivers. In rc.local you can modprobe wl without problems. On a sidenote: I get hard lockups, without any way to debug because there is nothing in kernel.log. Not sure if related to the wl driver though.
+
* On a similar HP DM1 netbook I found the brcmsmac driver did not work either. The kernel panic can also be solved by blacklisting the brcmsmac, b43 and wl drivers. In rc.local you can {{ic|modprobe wl}} without problems. On a sidenote: I get hard lockups, without any way to debug because there is nothing in kernel.log. Not sure if related to the wl driver though.
 +
:--[[User:Wilco|Wilco]], 5 May 2012
  
 
* Likewise, my HP Pavilion g7-1374ca also had problems with stock kernel drivers. I downloaded Broadcom tarball, but it wouldn't compile in 3.4.3. I removed the #include <asm/system.h> line and commented out a line referencing .ndo_set_multicast_list (there's only one). Then I was able to compile and load the module for a 100% strength signal, no lockups so far.
 
* Likewise, my HP Pavilion g7-1374ca also had problems with stock kernel drivers. I downloaded Broadcom tarball, but it wouldn't compile in 3.4.3. I removed the #include <asm/system.h> line and commented out a line referencing .ndo_set_multicast_list (there's only one). Then I was able to compile and load the module for a 100% strength signal, no lockups so far.
  
 
* On a Dell Inspiron N5110 with BCM4313, when the wireless was hardware-off, the system would always hang at boot with the kernel {{ic|brcmsmac}} driver. Using the {{ic|broadcom-wl}} driver the problem was solved.
 
* On a Dell Inspiron N5110 with BCM4313, when the wireless was hardware-off, the system would always hang at boot with the kernel {{ic|brcmsmac}} driver. Using the {{ic|broadcom-wl}} driver the problem was solved.
 +
:--[[User:Nplatis|Nplatis]], 14 October 2012
 +
 +
* On a Dell M4700 with BCM4313 got hideously slow "performance" with default driver -- switched to broadcom-wl and got near advertised link rate speed (65 to 72 Mb/sec)...until restarting, then was not able to associate with wireless access point. The solution was to [[Kernel modules#Blacklisting|blacklist]] the kernel modules {{ic|dell_wmi}} and {{ic|cfg80211}}.
 +
:--[[User:virtualeyes|virtualeyes]], 23 February 2013
 +
 +
* On a Lenovo G580 mounting a BCM4313 the proprietary driver module kept crashing because some dependencies were unsatisfied (the same problem found by [[User:Ivanoff|Ivanoff]]). What worked for me was to put a file in /etc/modprobe.d/ with the following content:
 +
{{hc|/etc/modprobe.d/10_wl.conf|
 +
blacklist brcmsmac
 +
blacklist bcma
 +
softdep wl pre: lib80211_crypt_tkip lib80211_crypt_ccmp lib80211_crypt_wep
 +
}}
 +
:--[[User:zarel|zarel]], 21 June 2013
 +
 +
* On MacBook Pro late 2013 (MacBookPro11,1) with BCM4360 the proprietary STA driver loses connection after running iwconfig (and possibly other software that calls iw_get_ext(..., ..., SIOCGIWTXPOW, ...)) with error messages
 +
{{hc|dmesg|<nowiki>kernel: ERROR @wl_dev_intvar_get : error (-1)
 +
kernel: ERROR @wl_cfg80211_get_tx_power : error (-1)</nowiki>}}
 +
Here's a dirty workaround for the kernel
 +
{{hc|patch|<nowiki>--- /tmp/wireless.h 2014-05-02 04:38:22.403321811 +0400
 +
+++ /usr/src/linux/include/uapi/linux/wireless.h 2014-05-02 04:29:15.291996332 +0400
 +
@@ -283,7 +283,7 @@
 +
#define SIOCSIWFRAG 0x8B24 /* set fragmentation thr (bytes) */
 +
#define SIOCGIWFRAG 0x8B25 /* get fragmentation thr (bytes) */
 +
#define SIOCSIWTXPOW 0x8B26 /* set transmit power (dBm) */
 +
-#define SIOCGIWTXPOW 0x8B27 /* get transmit power (dBm) */
 +
+//#define SIOCGIWTXPOW 0x8B27 /* get transmit power (dBm) */
 +
#define SIOCSIWRETRY 0x8B28 /* set retry limits and lifetime */
 +
#define SIOCGIWRETRY 0x8B29 /* get retry limits and lifetime */
 +
 +
@@ -294,6 +294,8 @@
 +
#define SIOCSIWPOWER 0x8B2C /* set Power Management settings */
 +
#define SIOCGIWPOWER 0x8B2D /* get Power Management settings */
 +
 +
+#define SIOCGIWTXPOW SIOCGIWPOWER
 +
+
 +
/* WPA : Generic IEEE 802.11 informatiom element (e.g., for WPA/RSN/WMM).
 +
  * This ioctl uses struct iw_point and data buffer that includes IE id and len
 +
  * fields. More than one IE may be included in the request. Setting the generic</nowiki>}}
 +
:--[[User:sbar|sbar]], 03 May 2014
 +
 +
* On Ahtec PBL01 with wireless controller BCM4313 (using kernel 3.11.0-12 and brcmsmac module) half of times I cannot connect to home wireless network. However I can connect to other networks, for example if I setup my smartphone as access point. What is more confusing is that after connecting to my smartphone network I can switch to my home network and it will connect fine.
 +
:--[[User:Pablog|Pablog]] ([[User talk:Pablog|talk]]) 13:16, 5 June 2014 (UTC)

Revision as of 05:14, 20 June 2014

Introduction

Broadcom has been notorious in its support for its Wi-Fi cards on GNU/Linux. Until recently, most Broadcom chips were either entirely unsupported or required the user to tinker with firmware. A limited set of wireless chips were supported by various reverse-engineered drivers (brcm4xxx, b43, etc.). The reverse-engineered b43 drivers have been in the kernel since 2.6.24.

In August 2008, Broadcom released the 802.11 Linux STA driver officially supporting Broadcom wireless hardware on GNU/Linux. These are restrictively licensed drivers, but Broadcom promised to work towards a more open approach in the future. Further, they do not work with hidden ESSIDs.

In September 2010, Broadcom finally released fully open source drivers for its hardware. This driver, brcm80211, has been included into the kernel since 2.6.37. With the release of 2.6.39, these drivers have been renamed to brcmsmac and brcmfmac.

At the time of writing, there are three choices for users with Broadcom Wi-Fi chipsets:

Driver Description
brcmsmac/brcmfmac Open-source kernel driver
b43 Reverse-engineered kernel driver
broadcom-wl Proprietary Broadcom STA driver

Determine which driver you need/can use

First, determine your card's PCI-ID. Type the following (case-sensitive) command into a console:

$ lspci -vnn | grep 14e4:

Then check your card against this list of supported b43 devices and this list of supported brcm80211 devices.

Getting the driver

brcmsmac/brcmfmac

The brcm80211 drivers are included in the kernel. They are named brcmsmac for PCI cards and brcmfmac for SDIO devices.

These drivers should be automatically loaded during start-up and no further action should be required of the user. If the driver does not load automatically, simply load it manually.

Note: Since linux>=3.3.1, the brcmsmac driver depends on the bcma module; therefore, make sure the bcma module is not blacklisted.
Note: wireless.kernel.org states that brcm80211 does not support older PCI/PCI-E chips with SSB backplane.

b43/b43legacy

The drivers are included in the kernel since 2.6.24.

Loading the b43/b43legacy kernel module

Verify which module you need by looking up your device here. You can also check by computer model here. Blacklist the other module (either b43 or b43legacy) to prevent possible problems/confusion. For instructions, see Kernel_modules#Blacklisting.

Install the appropriate b43-firmwareAUR or b43-firmware-legacyAUR package from the AUR.

If you have a low-power version of a b43-supported device, you will need to install special firmware. A quick way to check whether you have a low-power chip is by running lspci | grep Broadcom | grep LP-PHY. You can install it by downloading the appropriate package and using b43-fwcutter as outlined below, or by using this installation script.

To install the LP-PHY firmware, perform the following:

curl -LO http://downloads.openwrt.org/sources/broadcom-wl-4.178.10.4.tar.bz2
tar xjf broadcom-wl-4.178.10.4.tar.bz2
cd broadcom-wl-4.178.10.4/linux
b43-fwcutter -w /lib/firmware wl_apsta.o

After installing the firwmare, you can now configure your device.

Note: If the b43 module appears to be loaded and functional but the device is inaccessible, you may need to blacklist the bcma module. See Section 4.1. If that does not help, you might have to recompile the kernel with the CONFIG_B43_BCMA_EXTRA option set to use b43. This option was introduced to avoid race conditions between the modules and is at least needed for cards with the BCM4322, BCM43224 and BCM43225 chipsets.

broadcom-wl

Warning: Even though this driver has matured a lot throughout the years and works quite well now, its usage is recommended only when neither of the two open-source drivers support your device. Please refer to project b43's page for list of supported devices.

For users of the broadcom-wl driver, there is a PKGBUILD available in the AUR named broadcom-wlAUR. There is also a newer version available (supporting more recent cards), see broadcom-wl-dkmsAUR.

Loading the wl kernel module

The wl module may need to be manually loaded if there are other usable modules present. Before loading the wl module, remove the b43 or other module that may have been automatically loaded instead:

# rmmod b43

Also unload ssb, if loaded:

# rmmod ssb
Note: Failure to unload ssb may result in the wireless interface not being created.

Load the wl module

# modprobe wl

The wl module should automatically load lib80211 or lib80211_crypt_tkip. Check with lsmod to see if this is the case. If not, you may need to add one of those two modules as well.

# modprobe lib80211

or

# modprobe lib80211_crypt_tkip

If you installed the driver directly from Broadcom, you may also need to update the dependencies:

# depmod -a

To make the module load at boot, refer to Kernel modules.

You can also blacklist other modules (to prevent them from interfering) in /etc/modprobe.d/modprobe.conf. To blacklist a module, refer to Kernel modules#Blacklisting.

Note: Broadcom Corporation BCM4311 802.11b/g WLAN [14e4:4311] does not work with blacklisting b43 and ssb.

Troubleshooting

Wi-Fi card does not seem to even exist

Tango-view-fullscreen.pngThis article or section needs expansion.Tango-view-fullscreen.png

Reason: no solution provided (Discuss in Talk:Broadcom wireless#)

Some users with newer cards like the Broadcom BCM43241 will experience an issue where lspci or lsusb will not show any trace of the card. A solution to this will be posted when found.

Wi-Fi card does not work or show up after kernel upgrade (brcmsmac)

This is caused by the kernel using the bcma module instead of the brcmsmac module. The solution is to blacklist the bcma module. For instructions, see Kernel_modules#Blacklisting.

Note: This affects only Linux kernels 3.0, 3.1, and 3.2. Since kernel 3.3, the brcmsmac module actually uses bcma, so bcma needs to be unblacklisted or the Wi-Fi interface will not appear.

Wi-Fi card does not work/show up (broadcom-wl)

Check if you are loading the correct modules. You may need to blacklist the brcm80211, b43, and ssb kernel modules to prevent them from loading automatically. For instructions, see Kernel_modules#Blacklisting.

Note: You may not have to blacklist the brcm80211 driver; although as of 2011-06-20, it will still default to loading the brcm80211 module before the wl driver, which prevents wl from being used.

Check if you updated your module dependencies:

# depmod -a
  • Verify that your wireless interface(s) appear using ip addr.
  • You may need to restart your machine to see the device appear in iwconfig or ip addr.
  • If you have recently upgraded your kernel, you need to rebuild the broadcom-wl package with the new kernel installed to update the module.

Interfaces swapped (broadcom-wl)

Users of the broadcom-wl driver may find their Ethernet and Wi-Fi interfaces have been swapped. See Network configuration#Device_names for solution.

The b43 driver and Linux 3.8+

The b43 driver has some major issues starting with the release of Linux 3.8+, namely that you are unable to see / connect to some access points.

Solution: Try the latest broadcom-wl driver (version 6+), see above.

Suppressing console messages

You may continuously get some verbose and annoying messages during the boot, similar to

phy0: brcms_ops_bss_info_changed: arp filtering: enabled true, count 0 (implement)
phy0: brcms_ops_bss_info_changed: qos enabled: false (implement)
phy0: brcms_ops_bss_info_changed: arp filtering: enabled true, count 1 (implement)
enabled, active

These do not seem to be suppressible via normal means, such as setting MaxLevelConsole in /etc/systemd/journald.conf. To hide them, you must lower the level at which dmesg messages are printed to the console. This can be done on start-up by creating a simple systemd service.

Create a file in /etc/systemd/system/ called brcms_suppression.service or something similar:

brcms_suppression.service

[Unit]
Description=Broadcom console message suppression script

[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=/bin/sh -c 'dmesg -n 3'

[Install]
WantedBy=multi-user.target

Like all other systemd services, you can then enable it with

# systemctl enable brcms_suppression

Interface is showing but does not allow connections

Append the following to your kernel command line:

b43.allhwsupport=1

Miscellaneous user notes

Tango-edit-clear.pngThis article or section needs language, wiki syntax or style improvements.Tango-edit-clear.png

Reason: This section must be rewritten impersonally, very likely as a FAQ or Troubleshooting section (also remove or update out-of-date information). See also Help:Style. (Discuss in Talk:Broadcom wireless#Allowing user signatures on main article pages in limited situations?)
  • In my Dell Inspiron Laptop, I have a Broadcom BCM4401 Ethernet card and a Broadcom BCM4328 wireless card. If I just remove b43, I can load the wl driver, but no wireless card shows up. However, if I first remove the b44 (and ssb) driver for my Ethernet card, and then load the wl driver, I get a wireless device using the name eth0. Afterwards, I can load b44 again, to have an Ethernet eth1 device.
  • I could not get the BCM4313 chip on a Lenovo B560 to work before following these steps:
    1. "Load defaults" in the BIOS. After that, the wireless was working under MS Windows. There are not many options in there, so I do not know what the reset may have changed, but it did the trick.
    2. Blacklist the acer_wmi module. For testing, you can add the following to the kernel line in GRUB: acer_wmi.disable=1
  • I have found that to get the wl drivers working for the Broadcom 4313 chip, you need to blacklist brcm80211 along with b43 and ssb.
--Admiralspark, 20 June 2011
  • If you notice slow wireless speeds when your laptop/netbook is not connected to AC power, you may need to disable Wi-Fi power management by adding the following line (assuming wlan0 is your wireless device) iwconfig wlan0 power off to /etc/rc.local and create an empty file /etc/pm/power.d/wireless. In case you also experience interface swapping (discussed above), you might want to add another line for the second interface name as well. The command will have no effect on the wired interface.
--Tom.yan, 16 August 2011
  • In my case on a HP pavilion netbook DM1 with a BCM4313 chip, with the original kernel brcmsmac driver, the LED didn't work, the power was awful, and it kept loosing the signal all the time, unless very close to the Wi-Fi hotspot. The last Broadcom driver wl solved everything. So in some cases, it's actually better than the kernel driver. However, I had to install it in the initramfs image, along with lib80211 and lib80211_crypt_tkip to avoid a recurring kernel panic.
--Ivanoff, 18 March 2012 *Edit* It's all solved with the latest kernel versions. --Ivanoff (talk) 14:19, 14 December 2013 (UTC)
  • On a similar HP DM1 netbook I found the brcmsmac driver did not work either. The kernel panic can also be solved by blacklisting the brcmsmac, b43 and wl drivers. In rc.local you can modprobe wl without problems. On a sidenote: I get hard lockups, without any way to debug because there is nothing in kernel.log. Not sure if related to the wl driver though.
--Wilco, 5 May 2012
  • Likewise, my HP Pavilion g7-1374ca also had problems with stock kernel drivers. I downloaded Broadcom tarball, but it wouldn't compile in 3.4.3. I removed the #include <asm/system.h> line and commented out a line referencing .ndo_set_multicast_list (there's only one). Then I was able to compile and load the module for a 100% strength signal, no lockups so far.
  • On a Dell Inspiron N5110 with BCM4313, when the wireless was hardware-off, the system would always hang at boot with the kernel brcmsmac driver. Using the broadcom-wl driver the problem was solved.
--Nplatis, 14 October 2012
  • On a Dell M4700 with BCM4313 got hideously slow "performance" with default driver -- switched to broadcom-wl and got near advertised link rate speed (65 to 72 Mb/sec)...until restarting, then was not able to associate with wireless access point. The solution was to blacklist the kernel modules dell_wmi and cfg80211.
--virtualeyes, 23 February 2013
  • On a Lenovo G580 mounting a BCM4313 the proprietary driver module kept crashing because some dependencies were unsatisfied (the same problem found by Ivanoff). What worked for me was to put a file in /etc/modprobe.d/ with the following content:
/etc/modprobe.d/10_wl.conf
blacklist brcmsmac
blacklist bcma
softdep wl pre: lib80211_crypt_tkip lib80211_crypt_ccmp lib80211_crypt_wep
--zarel, 21 June 2013
  • On MacBook Pro late 2013 (MacBookPro11,1) with BCM4360 the proprietary STA driver loses connection after running iwconfig (and possibly other software that calls iw_get_ext(..., ..., SIOCGIWTXPOW, ...)) with error messages
dmesg
kernel: ERROR @wl_dev_intvar_get : error (-1)
kernel: ERROR @wl_cfg80211_get_tx_power : error (-1)

Here's a dirty workaround for the kernel

patch
--- /tmp/wireless.h	2014-05-02 04:38:22.403321811 +0400
+++ /usr/src/linux/include/uapi/linux/wireless.h	2014-05-02 04:29:15.291996332 +0400
@@ -283,7 +283,7 @@
 #define SIOCSIWFRAG	0x8B24		/* set fragmentation thr (bytes) */
 #define SIOCGIWFRAG	0x8B25		/* get fragmentation thr (bytes) */
 #define SIOCSIWTXPOW	0x8B26		/* set transmit power (dBm) */
-#define SIOCGIWTXPOW	0x8B27		/* get transmit power (dBm) */
+//#define SIOCGIWTXPOW	0x8B27		/* get transmit power (dBm) */
 #define SIOCSIWRETRY	0x8B28		/* set retry limits and lifetime */
 #define SIOCGIWRETRY	0x8B29		/* get retry limits and lifetime */
 
@@ -294,6 +294,8 @@
 #define SIOCSIWPOWER	0x8B2C		/* set Power Management settings */
 #define SIOCGIWPOWER	0x8B2D		/* get Power Management settings */
 
+#define SIOCGIWTXPOW	SIOCGIWPOWER
+
 /* WPA : Generic IEEE 802.11 informatiom element (e.g., for WPA/RSN/WMM).
  * This ioctl uses struct iw_point and data buffer that includes IE id and len
  * fields. More than one IE may be included in the request. Setting the generic
--sbar, 03 May 2014
  • On Ahtec PBL01 with wireless controller BCM4313 (using kernel 3.11.0-12 and brcmsmac module) half of times I cannot connect to home wireless network. However I can connect to other networks, for example if I setup my smartphone as access point. What is more confusing is that after connecting to my smartphone network I can switch to my home network and it will connect fine.
--Pablog (talk) 13:16, 5 June 2014 (UTC)