1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Broadcom WiFi

Discussion in 'Mobile Computing' started by lissyara, Feb 26, 2009.

  1. Seeker

    Seeker Member

    Messages:
    859
    Thanks Received:
    11
    Don't forget Broadcom BCM4321 too. I'm ready to help testing too.
    Actually, I have 1 additional laptop, with Broadcom BCM4313, so I can do tests on it too.

    Duh! Buying dell's laptop?
    Refuse WiFi card and buy it on your own!
     
  2. pkubaj

    pkubaj Member

    Messages:
    455
    Thanks Received:
    51
    BCM43225 (yes there are two 2's) reporting in. Like others, I can test the driver.
     
  3. homie

    homie New Member

    Messages:
    1
    Thanks Received:
    0
    I have the same NIC in an iBook G4, but CPU architecture is PowerPC and the bwn driver doesn't work for me properly. For example I could connect to my AP (packet loss ~10-40%), ping it, but it was only possible near the AP (less than 3-2 meters). Any thoughts are welcome.

    Thanks.
     
  4. ForTozs

    ForTozs New Member

    Messages:
    21
    Thanks Received:
    0
    I would gladly test on a BCM4312 (low power) Dell Mini. bwn is close on this one, but I still am having problems.
     
  5. kr651129

    kr651129 New Member

    Messages:
    327
    Thanks Received:
    3
    I'd like to help test also but I think that Broadcom is just so bad that it shouldn't be supported or "supported" at all. The only reason I'm for the support of Broadcom drivers is because they are in a lot of Dell machines. I don't really know much about Broadcom in machines other than Dell.
     
  6. andersbo87

    andersbo87 New Member

    Messages:
    41
    Thanks Received:
    1
    Most newer Macs (at least MacBook Pros) from (at least) 2009 and newer also use Broadcom. The one I've got, a 2011 17-inch model, uses Broadcom for both wired and wireless Internet. The wired Broadcom driver (bge(4)) works fine in FreeBSD 9.0, however wireless does not work (I haven't tried it with NDIS yet).
     
  7. UglyJoe

    UglyJoe New Member

    Messages:
    13
    Thanks Received:
    0
    Any update on progress on this driver?
     
  8. KNOStic

    KNOStic New Member

    Messages:
    77
    Thanks Received:
    16
    So far, no. I'm hoping to be available to work with EMC in about 2-3 weeks perhaps. The problem with these cards is that they're all based on Broadcom's wl5 code, and neither bwi nor bwn modules will work with the "newer" Broadcom cards. In fact, on 64 bit versions, bwn, if it detects the cards at all will panic hard. I had to remove several PCI ID's from the /usr/src/sys/dev/siba/siba_bwn.c code (and reported it numerous times) since bwn doesn't work with them anyway after failing to attach and then spitting the bit in the kernel, going four paws to the moon. Jeung walked away from bwn over a year ago now.

    I've tried all sorts of tricks myself with NDIS, and although the cards get detected and attached and even have their firmware uploaded through NDIS, they come up brain dead on channel 1, won't scan and when you go through the step of # /etc/rc.d/netif restart after manually trying to wake them up, kernel panic. Now I know Richardpl has submitted new code to try to fix that, but not one line of it has made it into the kernel yet, not even the latest build of 10 current. For MY purposes, NDIS is hopelessly broken and is absolutely useless with Broadcom PCI-E stuff. I won't even get into how bad it gets if the card has bluetooth as well. :(

    So ... Since we last visited this topic, the kernel folks have finally gotten some work in on 802.11n support, so there's some hope that wasn't there before. bwi and bwn clearly ain't gonna cut it since the cards in question here are all bcmwl5-based and there IS a Linux driver and library released by Broadcom which of course doesn't help us here in beastie-land.

    I propose however that the only real way to go after this would be to take the code that Broadcom released for Linux and attempt to port the code to BSD. Either that, or snatch some Broadcom wiglets and hold them for ransom until they provide US a port. :)

    EMC ... what should we do? Be happy to do what I can once I've moved into my new location after the end of this month ... but like it or not, BSD *MUST* support Broadcom, we have no choice. Every POS computer made lately has that stuff in them, and Apple has abandoned their users who bought in with Tiger, Leopard and now Snow Leopard. EVERY Apple user I talk to WANTS BSD on there. But they have Broadcom out the wazoo. It *must* get done, one way or another. We really have no choice anymore.

    I wrote Windows drivers for years, I've cobbled BSD drivers here and there. I'm really not quite up to speed for something of this complexity, but I can certainly help if I can get a few other hands with a little more experience with the 802.11 stuff. Any takers?

    ---

    Finally for Dutch: I understand that this should go out on the "list" but I don't want to step on what's going on there until there's actually some degree of plan. I see they're insanely busy schmoozing ath into working and so far, all we have here is a dollar and a dream. Thus, for the moment, I think this is a smarter place to build an army and at least indicate to the rest of the community how important dealing with Broadcom's mess truly is. Hope you'll forgive me. :)
     
  9. Seeker

    Seeker Member

    Messages:
    859
    Thanks Received:
    11
    I think, that first step should be talking to Broadcom, to support FreeBSD and build native driver, as they did for Linux.
    If "diplomacy" fails ..., we might get a little harsher with them. ;)
     
  10. kpa

    kpa Well-Known Member

    Messages:
    4,081
    Thanks Received:
    803
    I don't think there's much you can do unless Broadcom sees some value (cash cash cash) in supporting FreeBSD. It doesn't help that FreeBSD has reputation of being a server OS and you don't see those wireless network adapters in servers that often.
     
  11. Seeker

    Seeker Member

    Messages:
    859
    Thanks Received:
    11
    Reputation is ... false!
    FreeBSD is what you make it to.
    Desktop, laptop, server, embedded ...
    If Nvidia has been made into seeing FreeBSD "the right way", than Broadcom could too.
    Nvidia is also a bigger company, so ..., has anyone started chatter with Broadcom?
     
  12. emc2

    emc2 New Member

    Messages:
    17
    Thanks Received:
    1
    I definitely have an interest in improving the hardware support on Apple platforms. As for time well... I've been supposedly working on EFI support under GSoC, except I'm backlogged there too, due to job searching/interviewing, and now I have to move and start a new job.

    I have plans on reverse-engineering the closed source linux driver, which I think I've discussed here before. In essence, there is an object file they distribute, which gets compiled against an open source linux kernel interface. From the look of things, the object file is OS-independent. If that's the case, it should be possible to build a replacement for the linux interface.

    I had plans to make some tools to try and decompile the object file. The process goes something like this: disassemble, reconstruct CFGs, run structural analysis to get back the control flow structures[0], try and figure out local variables from registers/stack slots, try and infer types using info from the headers. All but the last two steps can be fully automated. The last two may need help from a human somewhere along the way. I'm pretty confident that this could recover most if not all of the closed-source object file in this case. In the more general case, these tools could be a very useful for future efforts.


    [0]: See "Advanced Compiler Design and Implementation"
     
  13. Seeker

    Seeker Member

    Messages:
    859
    Thanks Received:
    11
    Post this on hackers@freebsd.org
    You'll get directly in touch with devs ...

    Hint: Fact that this is about driver, is very little relevant, but reverse-engineering bin code.
    Best help and assistance, you'll get there.
     
  14. yo9fah

    yo9fah New Member

    Messages:
    14
    Thanks Received:
    1
    How can I solve this problem, I cannot connecting to my wireless card http://i.imgur.com/NKxaX.png

    Not connecting. I get an error:
    I tried with bwi driver but not working.

    # pciconf -lvbc

    Code:
    siba_bwn0@pci0:4:0:0:	class=0x028000 card=0xe003105b chip=0x431514e4 rev=0x01 hdr=0x00
        vendor     = 'Broadcom Corporation'
        device     = 'BCM4312 802.11b/g LP-PHY'
        class      = network
        bar   [10] = type Memory, range 64, base 0xf8000000, size 16384, enabled
        cap 01[40] = powerspec 3  supports D0 D1 D2 D3  current D0
        cap 09[58] = vendor (length 120)
        cap 05[e8] = MSI supports 1 message, 64 bit enabled with 1 message
        cap 10[d0] = PCI-Express 1 endpoint max data 128(128) link x1(x1)
    ecap 0001[100] = AER 1 0 fatal 1 non-fatal 4 corrected
    ecap 0002[13c] = VC 1 max VC0
    ecap 0003[160] = Serial 1 4c473affff9a001f
    ecap 0004[16c] = unknown 1


    # kldstat

    Code:
    Id Refs Address            Size     Name
     1   39 0xffffffff80200000 1323288  kernel
     2    2 0xffffffff81524000 484c0    linux.ko
     3    1 0xffffffff8156d000 415d8    if_bwn.ko
     4    2 0xffffffff815af000 cc18     siba_bwn.ko
     5    1 0xffffffff815bc000 29e0     coretemp.ko
     6    1 0xffffffff815bf000 6668     sem.ko
     7    1 0xffffffff815c6000 6600     cuse4bsd.ko
     8    1 0xffffffff815cd000 de08     tmpfs.ko
     9    1 0xffffffff815db000 2d358    bwn_v4_lp_ucode.ko
    10    1 0xffffffff81812000 3dfc     linprocfs.ko
    11    1 0xffffffff81816000 15c2     fdescfs.ko
    12    1 0xffffffff81818000 a96b     fuse.ko
    13    1 0xffffffff81823000 8267     i915.ko
    14    1 0xffffffff8182c000 13815    drm.ko


    # netstat -r

    Code:
    Routing tables
    
    Internet:
    Destination        Gateway            Flags    Refs      Use  Netif Expire
    default            192.168.1.1        UGS         0      392   bge0
    localhost          link#12            UH          0        6    lo0
    192.168.1.0        link#13            U           0        0  wlan0
    192.168.1.100      link#4             UHS         0        0    lo0
    192.168.1.102      link#13            UHS         0        0    lo0
    
    Internet6:
    Destination        Gateway            Flags      Netif Expire
    ::                 localhost          UGRS        lo0
    localhost          link#12            UH          lo0
    ::ffff:0.0.0.0     localhost          UGRS        lo0
    fe80::             localhost          UGRS        lo0
    fe80::%bge0        link#4             U          bge0
    fe80::21d:72ff:fe3 link#4             UHS         lo0
    fe80::%lo0         link#12            U           lo0
    fe80::1%lo0        link#12            UHS         lo0
    ff01::%bge0        fe80::21d:72ff:fe3 U          bge0
    ff01::%lo0         localhost          U           lo0
    ff02::             localhost          UGRS        lo0
    ff02::%bge0        fe80::21d:72ff:fe3 U          bge0
    ff02::%lo0         localhost          U           lo0


    # ifconfig

    Code:
    bge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
    	options=c019b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,TSO4,VLAN_HWTSO,LINKSTATE>
    	ether 00:1d:72:32:45:5d
    	inet6 fe80::21d:72ff:fe32:455d%bge0 prefixlen 64 scopeid 0x4 
    	inet 192.168.1.100 netmask 0xffffff00 broadcast 192.168.1.255
    	nd6 options=23<PERFORMNUD,ACCEPT_RTADV,AUTO_LINKLOCAL>
    	media: Ethernet autoselect (100baseTX <full-duplex>)
    	status: active
    bwn0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 2290
    	ether 00:1f:3a:9a:4c:47
    	nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
    	media: IEEE 802.11 Wireless Ethernet autoselect mode 11g
    	status: associated
    fwe0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
    	options=8<VLAN_MTU>
    	ether 02:1d:72:32:45:5d
    	nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
    	ch 1 dma -1
    fwip0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
    	lladdr 0.1d.72.ff.ff.32.45.5d.a.2.ff.fe.0.0.0.0
    	nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
    lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
    	options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
    	inet6 ::1 prefixlen 128 
    	inet6 fe80::1%lo0 prefixlen 64 scopeid 0xc 
    	inet 127.0.0.1 netmask 0xff000000 
    	nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
    wlan0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
    	ether 00:1f:3a:9a:4c:47
    	inet 192.168.1.102 netmask 0xffffff00 broadcast 192.168.1.255
    	nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
    	media: IEEE 802.11 Wireless Ethernet OFDM/36Mbps mode 11g
    	status: associated
    	ssid YO9FAH channel 6 (2437 MHz 11g) bssid 00:22:6b:e9:5e:7a
    	country US authmode WPA2/802.11i privacy ON deftxkey UNDEF
    	AES-CCM 2:128-bit txpower 30 bmiss 7 scanvalid 450 bgscan
    	bgscanintvl 300 bgscanidle 250 roam:rssi 7 roam:rate 5 protmode CTS
    	wme roaming MANUAL


    # ifconfig wlan0 list scan sta

    Code:
    SSID/MESH ID    BSSID              CHAN RATE   S:N     INT CAPS
    union           00:e0:61:28:41:97    1   54M -138:-95  100 EP   WPS
    D.O.D           34:08:04:08:3c:14    1   54M -133:-95  100 EPS  WPS HTCAP WME
    YO9FAH          00:22:6b:e9:5e:7a    6   54M -115:-95  100 EP   RSN WME
    TRENDnet        00:14:d1:34:6b:8e    6   54M -137:-95  100 EPS 
    Nutunet         28:10:7b:62:fc:28    6   54M -122:-95  100 EP   HTCAP WPA RSN WME WPS
    cla@alex        f4:ec:38:cb:53:42    4   54M -124:-95  100 EPS  RSN WPA WME HTCAP ATH WPS
    ifconfig: sta: bad value


    loader.conf

    Code:
    linux_load="YES"
    coretemp_load="YES"
    sem_load="YES"
    cuse4bsd_load="YES"
    tmpfs_load="YES"
    linux_v4l2wrapper_load="YES"
    pwc_load="YES"
    # Enable the graphical boot-loader
    autoboot_delay="01"
    if_bwn_load="YES"
    bwn_v4_lp_ucode_load="YES"
    hw.bwn.usedma=0


    rc.conf

    Code:
    background_dhclient="YES"
    hostname="fbsd"
    keymap="us.iso.kbd"
    ifconfig_bge0="DHCP"
    ifconfig_bge0_ipv6="inet6 accept_rtadv"
    sshd_enable="YES"
    moused_enable="NO"
    ntpd_enable="YES"
    ntpd_sync_on_start="YES"
    powerd_enable="YES"
    # Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable
    dumpdev="NO"
    hald_enable="YES"
    dbus_enable="YES"
    slim_enable="YES"
    fusefs_enable="YES"
    linux_enable="YES"
    smartd_enable="YES"
    devfs_system_ruleset="devfsrules_common"
    # Clean out temporary files
    clear_tmp_enable="YES"
    clean_tmp_X="YES"
    webcamd_enable="YES"
    wlans_bwn0="wlan0"
    ifconfig_wlan0="WPA SYNCDHCP"


    And my dmesg: http://pastebin.com/RmN7W7ew
     
  15. yo9fah

    yo9fah New Member

    Messages:
    14
    Thanks Received:
    1
    LE: Oh God !!! I do not believe it !!! I work my wireless network card !!! Are now connected to my wireless card BCM4312 but works with "Project Devil"! :)
     
  16. dclegg

    dclegg New Member

    Messages:
    1
    Thanks Received:
    0
    willing to test BCM4322

    Hi, I also have a Dell Latitude E5500 with BCM4322 wireless.
    I'm very new to FreeBSD but excited to try to switch from Linux. I understand the broadcom support is in progress and wanted to volunteer testing andy developments. This is my first post here so please forgive my ignorance. Let me know if there's anything else I can supply.

    Bwi driver doesn't appear to do much, will load with kldload or in loader.conf but doesn't show any result in pciconf. Bwn driver makes kernel panic when put in loader.conf, similar to previous notes about this. When loaded with kldload it works. shows in kldstat and dmesg is as follows
    Code:
    siba_bwn0: <Unknown> mem 0xf69fc000-0xf69fffff irq 17 at device 0.0 on pci12
    siba_bwn0: warn: multiple PCI(E) cores
    siba_bwn0: unsupported coreid (USB 2.0 Device)
    siba_bwn0: unsupported coreid (unknown)
    siba_bwn0: unsupported coreid (Internal Memory)
    siba_bwn0: unknown chipid 0x4322 for PLL & PMU init
    bwn0 on siba_bwn0
    bwn0: unsupported PHY type (4)
    device_attach: bwn0 attach returned 6
    


    # pciconf -lv:
    Code:
    siba_bwn0@pci0:12:0:0:  class=0x028000 card=0x000d1028 chip=0x432b14e4 rev=0x01 hdr=0x00
        vendor     = 'Broadcom Corporation'
        device     = 'BCM4322 802.11a/b/g/n Wireless LAN Controller'
        class      = network
    


    # kldstat:
    Code:
    Id Refs Address            Size     Name
     1   14 0xffffffff80200000 11cd9b0  kernel
     3    1 0xffffffff81612000 8341     i915.ko
     4    1 0xffffffff8161b000 139a7    drm.ko
     9    1 0xffffffff8162f000 29889    if_bwn.ko
    10    1 0xffffffff81659000 61e4     siba_bwn.ko
     
  17. l2f

    l2f New Member

    Messages:
    47
    Thanks Received:
    1
    I remove the first line:
    Code:
     wpa_supplicant_enable="YES"
    and added
    Code:
    wpa_supplicant_flags="-Dndis"
    in my /etc/rc.conf

    I have a compaq mini 110c 1100ca running:
    Code:
    FreeBSD MiniBeastie.maison.org 8.3-RELEASE-p4 FreeBSD 8.3-RELEASE-p4 #0: Tue Oct 30 15:25:20 EDT 2012     root@MiniBeastie.maison.org:/usr/obj/usr/src/sys/GENERIC_P4  i386


    Thanks so much for the info

    Regards,

    l2f
     
  18. adrian@

    adrian@ New Member Developer

    Messages:
    27
    Thanks Received:
    8
    If you're serious about hacking on updated broadcom/marvell support

    .. then please join the FreeBSD wireless list (freebsd-wireless@freebsd.org) and don't be afraid to ask questions.

    I'm not really allowed to work on it (as I'm employed by Qualcomm Atheros), so I stick to net80211 and atheros wireless driver support.

    I and the other developers would love to see some traction made on updated broadcom support. Yes, this does likely mean porting the brcm80211 driver from Linux and all the relevant SIBA bus glue over. Yes, Broadcom _had_ (or have, internally?) a multi-platform driver which would likely work on FreeBSD with little changes. But what they push into Linux has been "linux-ified" and we'd likely have to undo all of that nonsense in order to get it working on FreeBSD.

    It's a catch-22 situation. If there's no-one using Broadcom on FreeBSD, no-one's going to ask, and thus Broadcom won't take it seriously, so they won't help, so there isn't any support on FreeBSD, hence no-one uses it, etc. If you want to see that cycle broken then we the community need to do the "linux thing" - stand up and take charge of it ourselves.

    The same goes for Marvell (mostly for their embedded wifi on various ARM *plug devices.) They do have a BSD wireless driver for their chipsets. They just don't open source it to FreeBSD any longer.
     
  19. G_Nerc

    G_Nerc New Member

    Messages:
    122
    Thanks Received:
    11
    adrian@, good day! As developer of wireless - subsystem, can you talk is anybody working in broadcom usb wireless on FreeBSD? For example for Netgear WNA-3100
    Broadcom is widely used chipset and support in FreeBSD will be necessary
     
  20. MasterOne

    MasterOne New Member

    Messages:
    73
    Thanks Received:
    5
    Damned, completely overlooked the Broadcom problem! :(

    I just checked, the Acer Aspire One 753 netbook I am trying to run FreeBSD 9.1-RELEASE amd64 on, has a BCM43225 wireless chipset, so I guess this is a dead end then?
     
  21. tzoi516

    tzoi516 Member

    Messages:
    366
    Thanks Received:
    8
    Did you install net/bwn-firmware-kmod?
     
  22. gustopn

    gustopn New Member

    Messages:
    23
    Thanks Received:
    0
    Be sure to disable APIC when using Broadcom wifi devices, because they have broken APIC, that's a problem on Linux too.
    Also, I have one of this miniPCIe BCM abgn adapters left, I am not using it any more, because I have newer Intel now, so if any developer would like to have it, just send me a message, I can send it away by DHL (or whatever).
    Ah, I see now, it is even BCM94321MC!
    And I also have one Apple Atheros 9k 802.11gn - with no part number on it.
     
  23. serverhamster

    serverhamster New Member

    Messages:
    54
    Thanks Received:
    8
    BCM43228 here. Doesn't appear to work with bwn(4).