b43 and b43legacy
The b43 drivers (bcm43xx in mainline kernels, b43 and b43legacy in wireless-2.6 and 2.6.24 and later) are drivers for the 802.11 B/G/N family of wireless chips Broadcom produces. The choice of which driver your card uses depends on the revision level of the 802.11 core. This number is read by driver ssb, and the correct choice for your device is made at that point.
Note: If your card is a BCM4306 Rev 2, or only has 802.11b capability, it uses b43legacy. All other models use b43.
Contents
Frequently asked questions
Please read this whole document and the FAQ before asking questions to the developers.
Caveats
All Broadcom chips require firmware that is loaded onto the wireless chip before it can operate. See below.
If you have an USB device with Broadcom chip, please use the rndis_wlan driver. The b43/b43legacy driver is not meant to support this device.
Both the b43 and b43legacy drivers conflict with the broadcom-wl driver, otherwise known as Broadcom's 802.11 Linux STA driver or simply broadcom-sta. If you want to use the b43 driver in favor of broadcom-wl, make sure that your Broadcom wireless chipset is supported on the supported device list. You will need to either remove or unload the broadcom-wl driver prior to using b43 by following: How do I use b43/b43legacy driver instead of broadcom-wl?
Known PCI devices
To find out whether a PCI device is supported by the b43 or b43legacy drivers, issue this lspci command:
lspci -vnn | grep 14e4
The command will output a string similiar to this example:
0001:01:01.0 Network controller [0280]: Broadcom Corporation BCM4318 [AirForce One 54g] 802.11g Wireless LAN Controller [14e4:4318] (rev 02)
Ignore everything, except the last part inside of the [ ] brackets. Check that phrase with the below table to determine support.
Note that for any of the devices that have two or more supported drivers separated by a slash (/), you can only use one of the mentioned drivers at a time. It does not mean you can run two or more drivers simultaneously, as the drivers will conflict with each other.
PCI-ID |
Supported? |
Chip ID |
Modes |
PHY version |
Alternative |
14e4:0576 |
no |
BCM43224 |
? |
? |
wl (aka STA) |
14e4:4301 |
yes (b43legacy) |
BCM4301 |
b |
B |
|
14e4:4306 |
yes (b43legacy) |
BCM4306/2 |
b/g |
G |
|
14e4:4307 |
yes |
BCM4306/3 |
b/g |
G |
|
14e4:4311 |
yes |
BCM4311 |
b/g |
G |
wl |
14e4:4312 |
yes |
BCM4311 |
a/b/g |
G (r8) |
wl |
14e4:4313 |
not tested |
BCM4311 |
a |
? |
wl |
14e4:4315 |
partially in 2.6.33+ |
BCM4312 |
b/g |
LP (r1) |
wl |
14e4:4318 |
yes |
BCM4318 |
b/g |
G (r7) |
|
14e4:4319 |
yes |
BCM4318 |
a/b/g |
G |
|
14e4:4320 |
yes (b43legacy) |
BCM4306/2 |
b/g |
G |
|
14e4:4320 |
yes |
BCM4306/3 |
? |
? |
|
14e4:4320 (USB) |
no (USB device) |
? |
? |
? |
|
14e4:4321 |
partially in 2.6.39+ |
BCM4321 |
? |
N (r2) |
|
14e4:4322 |
no |
BCM4322 |
b/g/n |
N (r4) |
|
14e4:4323 (USB) |
no (USB device) |
? |
? |
? |
ndiswrapper |
14e4:4324 |
yes (b43legacy) |
BCM4306 |
? |
G (r1/2) |
|
14e4:4325 |
not tested |
BCM4306 |
? |
? |
|
14e4:4328 |
partially in 2.6.39+ |
BCM4321 |
b/g/n |
N (r2) |
wl |
14e4:4329 |
partially in 2.6.39+ |
BCM4321 |
b/g/n |
N (r1) |
wl/brcm80211 |
14e4:432a |
not tested |
BCM4321 |
? |
N |
wl |
14e4:432b |
partially in 2.6.39+ |
BCM4322 |
? |
N (r4) |
wl |
14e4:432c |
not tested |
BCM4322 |
? |
N |
wl |
14e4:432d |
not tested |
BCM4322 |
? |
N |
wl |
14e4:4331 |
no |
BCM4331 |
? |
HT (r1) |
|
14e4:4353 |
no (WIP) |
BCM43224 |
a/b/g/n |
N (r6) |
wl/brcm80211 |
14e4:4357 |
no (WIP) |
BCM43225 |
a/b/g/n? |
N (r6) |
wl/brcm80211 |
14e4:4358 |
no |
BCM43227 |
? |
? |
wl |
14e4:4359 |
no |
BCM43228 |
? |
? |
wl |
14e4:435a |
no |
? |
? |
? |
wl |
14e4:4727 |
no |
BCM4313 |
b/g/n |
LCN (r1) |
wl/brcm80211 |
14e4:5354 |
yes? |
? |
b/g |
LP |
|
14e4:a99d |
no |
? |
? |
? |
wl |
Also note that the PCI-ID is not in direct correlation with the Chip ID. Often the PCI-ID equals the Chip ID, but that is not always the case and it is a constant source of confusion. The Chip ID is printed to the kernel log by the b43 driver on startup (For example):
b43-phy0: Broadcom 4318 WLAN found
Supported chips
- BCM4301 (802.11b-only chips, uses b43legacy)
- BCM4306 (Rev. 2 uses b43legacy, Rev. 3 uses b43)
- BCM4311 rev 1 (only the 2.4GHz part)
- BCM4311 rev 2 (only the 2.4GHz part) starting with 2.6.25
- BCM4312 (linux-kernel 2.6.32 is needed, 2.6.33 or latter is recommended)
- BCM4318
- BCM4321 (experimental in 2.6.38, kernel 2.6.39+ suggested)
- BCM4322 (experimental in 2.6.38, kernel 2.6.39+ suggested)
Unsupported chips
- The 802.11a part of the 4311 is not supported
BCM4320 (USB) - try rndis_wlan
- BCM43224/BCM43225 - chipsets on BCMA bus, work in progress
- BCM4313 - chipset uses unsupported LCN PHY
- BCM4331 - chipset uses unsupported HT PHY
- All other Broadcom chipsets not listed above are not supported. Feel free to notify the devs via mailing list and/or IRC channel of newer chipsets.
Known issues
- LP-PHY devices: DMA errors on some machines with kernel 2.6. Problem was fixed in 3.0. Using PIO (module param) can be used as workaround for 2.6.
BCM4318 chipset: AP mode does not work because of packet loss in high transmission rates. Hard to debug & fix.
- BCM4321: some cards do not work in DMA mode (PIO is needed).
Available devices
Please see the device list.
Features
Working
- Station mode
- Mesh networking mode (b43 only)
- Access Point mode
- Ad-Hoc (IBSS) mode (b43 only)
- Monitor and Promisc mode.
- "Monitor while operating" and multiple monitor interfaces.
- In-Hardware traffic de/encryption (relieves your CPU).
- LEDs to signal card state and traffic.
- In-Hardware MAC address filter (b43 only; impossible on b43legacy hardware)
- Packet injection (with radiotap; no FCS injection currently though hardware supports it - a radiotap flag is being discussed for this)
- Bluetooth coexistence protection, if the bluetooth card is physically connected to the wireless chip. (Does not protect against external BT dongles)
- Probably something we forgot to add here.
Not working yet
- Interference mitigation.
- HT
- 40MHz channels
- 5GHz for N-PHY cards
- Probably something else that's not listed under "Works".
Donations
Many people have donated money, hardware or other services to make this driver possible. Thanks! Please see the donations page for details.
Support
- IRC: server is irc.freenode.net, channel is #bcm-users (English please). Please note that we do not support users with wl drivers, you should email Broadcom for support instead.
Mailing list: http://lists.infradead.org/mailman/listinfo/b43-dev
Device firmware installation
The Broadcom wireless chip needs proprietary software (called "firmware") that runs on the wireless chip itself to work properly. This firmware is copyrighted by Broadcom and must be extracted from Broadcom's proprietary drivers. To get such firmware on your system, you must download the driver from a legal distribution point, extract it, and install it. This is accomplished different ways by different Linux distributions, so please read the section for yours for the best results. You will need an alternate working internet connection (by Ethernet cable, for example) since the firmware cannot be included with the distro itself.
Post details for missing distributions at b43-dev@lists.infradead.org. Note: the firmware from the binary drivers is copyrighted by Broadcom Corporation and cannot be redistributed.
Fedora
With Fedora 10 and above, you should install wget and the b43-fwcutter tool (which will extract firmware from the Windows driver):
Next use the instructions here, skipping b43-fwcutter installation part.
openSUSE
openSUSE 11.0 and above includes a utility that will automatically download the firmware and install it into its proper location. With working Internet access, run the following command:
1 sudo /usr/sbin/install_bcm43xx_firmware
Ubuntu/Debian
In recent versions of Ubuntu and Debian, installing the b43-fwcutter package will handle everything for you:
1 sudo apt-get install b43-fwcutter
You will be asked to automatically fetch and install the firmware into the right location. Again, you will need an internet connection.
Ubuntu Community Documentation
Ubuntu also has a page detailing the process of installing Broadcom wireless drivers on their community documentation. If you have internet access on the device that you want to install the b43 driver onto, follow this link: https://help.ubuntu.com/community/WifiDocs/Driver/bcm43xx#b43%20-%20Internet%20access . If you do not have internet access on the device that has a b43 supported broadcom wireless chipset and would like to use b43, follow this link instead: https://help.ubuntu.com/community/WifiDocs/Driver/bcm43xx#b43%20-%20No%20Internet%20access.
Note that you can only follow one of the two guides, not both.
Gentoo
Gentoo systems supply a pre-compiled binary for b43-fwcutter. You need to:
1 emerge b43-fwcutter
2 }}
3
4 and then follow the instructions [[http://linuxwireless.org/en/users/Drivers/b43#other_distros|below]] to download the Broadcom driver. The line that invokes b43-fwcutter will need to be changed to execute the program emerged above.
5
6 == Mandriva ==
7 Mandriva's graphical network card configuration tool, drakconnect, will extract the firmware from the Broadcom driver, which must be downloaded before configuring the card. For versions through 2008 Spring, you will need the V3 driver described below. Beginning with 2009, you will need either the V3 or V4 driver depending on whether your device uses b43legacy or b43. Either the wget command below, or a browser download will get the appropriate file.
8
9 <<Anchor(other_distros)>>
10
11 == Other distributions that are not mentioned above ==
12 '''Note: If you cannot use your distribution's packages, you need to have a compiler and headers for libc installed, since you will have to build fwcutter from source'''
13
14 To accomplish this task, do the following:
15
16 <<Anchor(b43-fwcutter)>>
17
18 === Install b43-fwcutter ===
19
20 Use version 014 of b43-fwcutter.<<BR>>Download, extract the b43-fwcutter tarball and build it:
21
22 {{{#!highlight sh
23 wget http://bu3sch.de/b43/fwcutter/b43-fwcutter-014.tar.bz2
24 tar xjf b43-fwcutter-014.tar.bz2
25 cd b43-fwcutter-014
26 make
27 sudo make install
28 cd ..
If you are using the b43 driver:
After installing b43-fwcutter, download version 5.10.56.27.3 of Broadcom's proprietary driver and extract the firmware from it:
Note that you must adjust the FIRMWARE_INSTALL_DIR path to your distribution. The standard place where firmware is installed to is /lib/firmware. However some distributions put firmware in a different place.
If you are using the b43legacy driver:
After installing b43-fwcutter, download version 3.130.20.0 of Broadcom's proprietary driver and extract the firmware from it:
Note that you must adjust the FIRMWARE_INSTALL_DIR path to your distribution. The standard place where firmware is installed to is /lib/firmware. However some distributions put firmware in a different place.
List of firmware
Earlier we were using other, older firmwares. The table contains all drivers supported by fwcutter.
Driver |
Version of wl |
Firmware |
Firmware extractor |
b43 |
508.1084 |
b43-fwcutter-014 |
|
b43 |
478.104 |
b43-fwcutter-013 |
|
b43 |
410.2160 |
b43-fwcutter-012 |
|
b43 |
351.126 |
b43-fwcutter-012 |
|
b43legacy |
295.14 |
b43-fwcutter-012 |
|
bcm43xx (deprecated) |
295.14 |
bcm43xx-fwcutter-006 |
Bug reporting
If you encounter a bug, you should send a message to the b43/b43legacy mailing list at b43-dev@lists.infradead.org containing ALL of the following:
- A description of the problem at hand
- When it happens
- How to reproduce
- wlan configuration and authentication/encryption type
- The output of the following commands:
1 uname -a
1 lspci -vvn|grep 43 -A7
1 dmesg
In addition the following may be of interest to developers:
- If you have built the kernel from git, tell which tree, the output of "git describe"
- If the driver worked with earlier kernels, but has since stopped working, a bisection is of great value.
bcm43xx, b43legacy, b43, softmac,... the full story
Many different drivers are or have been in use to support Broadcom chipsets, so the terminology is very confusing. The sections below aim to help you understand what is what.
bcm43xx
bcm43xx is the old deprecated driver. It uses the ieee80211 + softmac libraries of code shared with other drivers. This stack is deprecated and being replaced by the new mac80211 stack. A new stack implies brand new, re-written driver(s): b43 and b43legacy.
What's the difference between b43legacy and b43?
b43 offers a newer codebase and hardware cryptography support. However, Broadcom did not release any version 4 firmware files for some older boards, possibly due to memory constraints on the cards themselves. Stuck with firmware version 3, these cards must use b43legacy which doesn't have hardware crypto support because it has not been reverse engineered completely.
|
bcm43xx |
b43legacy |
b43 |
needs firmware |
version 3 |
version 4 |
|
extracted by |
bcm43xx-fwcutter |
b43-fwcutter |
|
depends on |
softmac |
mac80211 |
b43legacy should be used on all BCM4301 cards and BCM4306 cards with a 80211 core revision of 4 or less. b43 should be used on all other cards. You can safely have both versions built on the same system. Info about cores is printed by ssb when the driver finds a board, type "dmesg" to see it. If you are unsure and don't know what we are talking about here, always build both b43 and b43legacy (and get firmware for both too). The kernel autoloader will automatically do the right thing and load the correct driver for your device.
And why is there now broadcom-wl?
Broadcom has elected to create their own proprietary driver possibly due to various portable computer manufacturers like Dell including Broadcom's wireless chipsets in their devices. Many users/owners have expressed concerns and the pain of using ndiswrapper so the driver was created to alleviate such issues.
The difference with broadcom-wl driver compared to b43/b43legacy is that broadcom-wl can only offer connection to AP or Ad-Hoc network, it does not offer AP modes and Monitor modes. Furthermore the driver does not corporate well with iw tools because it has its own ieee80211 stack that is both outdated and does not work with mac80211 stack which b43/b43legacy is based on.
Users/Owners of unsupported Broadcom device wanting more functionality/support out of wl driver will have no choice but to continue emailing Broadcom. There will be no support offered on either the mailing list or the IRC channel due to the fact that the driver is mainly a proprietary binary blob. This is not due to b43 developers' fault but Broadcom's own internal conflicts with the linux community.
Any potential unsupported Broadcom wireless owners should note that if they would want native linux driver support should seek another wireless chipset manufacturer apart from Broadcom to alleviate this issue.
Update 09/09/2010: Broadcom has released an open driver for their SSB-less chipsets, whilst it only supports three chipsets (bcm4313, bcm43224, bcm43225) and the driver is in staging (which will be merged into kernel 2.6.37 under brcm80211). More information: http://lwn.net/Articles/404248/
Update 27/11/2010: Broadcom has now added staging support for bcm4329 via brcmfmac under brcm80211. The included documentation noted 4329 (SDIO) support however this may work with other variants of the bus interconnection apart from SDIO.
How do I use b43/b43legacy driver instead of broadcom-wl?
If you want to use b43 in favour of broadcom-sta and your Broadcom wireless chipset is supported from the device list you will need to either remove or unload the broadcom-wl driver first prior to using b43. To do this you must first unload the module:
1 modprobe -r wl
For those whom have partial b43 support may want to retain broadcom-wl driver. Blacklisting broadcom-wl is recommended to prevent the driver from being automatically loaded:
1 echo "blacklist wl" >> /etc/modprobe.d/blacklist
This will make b43 to be automatically loaded when the device starts up instead of broadcom-wl however you may want to switch across to broadcom-wl driver so that you can use broadcom-wl driver instead of b43. So to switch from b43/b43legacy to wl you will need to first unload the b43/b43legacy driver:
Those who wish to remove broadcom-wl driver should seek their distribution documentation in regards to removing the driver entirely.
Once the driver has been unloaded you may use b43/b43legacy or vice versa. Do also make sure to note that you will need to follow device firmware installation should you have not followed the guide previously for your current device setup.
related tools
- ssb-sprom
- A tool for the modification of the Broadcom Sonics Silicon Backplane SPROM (e.g. you can permanently change the MAC address or the PCI IDs of your wireless card – useful on some (e.g. Compaq/HP) laptops where the BIOS checks these at boot. It's now part of b43-tools:
git clone git://git.bu3sch.de/b43-tools.git
- To use the sprom tool, it is necessary to get a disk copy of your sprom from the /sys file system. The file path for the sprom contents depends on the bus layout of the specific computer being used and will be something like
/sys/devices/pci0000:00/0000:00:0d.0/0000:04:00.0/ssb_sprom
- It is not recommended that you try to type the name. Instead, you should use the following commands to get the working copy:
SSB_SPROM=$(find /sys/devices -name ssb_sprom) echo $SSB_SPROM
- If the echo command only results in a single instance of "/sys/...", you may proceed. For systems with more than one SSB-based interface, there will be such a string for each, and the command that sets the SSB_SPROM symbol will have to be changed. In the name above, the sequence states that this device is attached to the 0'th PCI bus via bridge 0d.0 and is device 04:00.0 on that bridge. To find which of your SSB devices to select, use the 'lspci -v' command. On my system, the first line of such output for my interface is "04:00.0 Network controller: Broadcom Corporation BCM94311MCG wlan mini-PCI (rev 02)". For this device, one would use
SSB_SPROM=$(find /sys/devices -name ssb_sprom | grep 04:00.0) echo $SSB_SPROM
- Of course, the "04:00.0" needs to match your system, and check the output value to determine that there is now a single instance of "/sys..." and that the path matches the device whose SPROM is to be changed. If not, adjust the string after 'grep' accordingly.
- Once the SSB_SPROM variable matches the path to ssb_sprom for your device, get a working copy of the sprom contents with
sudo cat $SSB_SPROM > ssb_sprom_copy
- You may now look at the contents of your sprom with the command
ssb-sprom -i ssb_sprom_copy -P
- As an example, let us suppose that you have purchased a Dell mini-pci card to use in an HP laptop. The HP BIOS refuses to use the card when the pcivendor is Dell (code 0x1028), not HP (code 0x103C). From the information provided by an "ssb-prom –help" command, we learn that the switch needed to change this vendor code is "–subv". To change that code, we use the command
ssb-sprom -i ssb_sprom_copy -o new_ssb_sprom_copy --subv 0x103C
- to write the HP vendor ID to our working copy. I use different input and output files so as not to destroy the original. If further changes are needed, for example the PCI product ID, the command
ssb-sprom -i new_ssb_sprom_copy -o new_ssb_sprom_copy --subp 0x137C
- would be used. Note that the input and output files may be the same.
- Once you think you have updated correctly, use the following to check the contents:
ssb-sprom -i ssb_sprom_copy -P
- Once the sprom contents are the way you want them, and presumably correct, you are ready to rewrite the file. First, use
echo $SSB_SPROM
- to ensure that this symbol still contains the SPROM path. If not, then it will have to be reloaded as discussed above.
- You are then ready to rewrite the sprom with
sudo cp new_ssb_sprom_copy $SSB_SPROM
IMPORTANT: The 2.6.32 kernel will throw the following error message and refuse to write the SPROM:
SPROM write: Could not freeze devices. No suspend support. Is CONFIG_PM enabled?
Apply the following patch to the 2.6.32 kernel to allow programming the SPROM on that kernel. Alternatively install a newer or an older kernel.
http://marc.info/?l=linux-wireless&m=125900356410309&q=raw
- Once again, you are urged to be absolutely certain of the contents of the working copy BEFORE writing it to hardware. If your interface becomes unusable as a result of writing incorrect data into the sprom, the responsibility is YOURS. Once again, you have been warned.
- A tool for the modification of the Broadcom Sonics Silicon Backplane SPROM (e.g. you can permanently change the MAC address or the PCI IDs of your wireless card – useful on some (e.g. Compaq/HP) laptops where the BIOS checks these at boot. It's now part of b43-tools:
- A firmware assembler/disassembler can be found in the git repository at
git clone git://git.bu3sch.de/b43-tools.git
- There are more development and debugging tools available in the b43-tools git repository. Just clone it and read the shipped documentation files.
git clone git://git.bu3sch.de/b43-tools.git
- wpa_supplicant
- A tool for enabling WPA and full IEEE 802.11i/RSN/WPA2 WPA-PSK and WPA2-PSK (pre-shared key) ("WPA-Personal") WPA with EAP.
- wpa_supplicant may have a 'broadcom' driver that is used with the proprietary Broadcom driver. The bcm43xx, b43 and b43legacy drivers use the linux wireless extensions properly and so need the wext driver. This is set using the -D option like this:
wpa_supplicant -iwlan0 -Dwext -c/etc/wpa_supplement.conf
Of course, you don't need this if you're using NetworkManager.