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. gnemmi

    gnemmi New Member

    Messages:
    219
    Likes Received:
    0
    have you tried sending PM to those who posted on this thread in order to see if some of them can help?

    Would you like me to start a thread on -current@ asking for help?
     
  2. Eponasoft

    Eponasoft New Member

    Messages:
    218
    Likes Received:
    0
    OK I've got a problem getting this bugger to work. I built and installed the bwi.03 driver (as this was the one noted for FreeBSD 7.2), and it appears to work, but I have no idea how to actually use it. :(

    All relevant data follows.

    Code:
    pceconf -lvcb
    
    bwi0@pci0:3:0:0:        class=0x028000 card=0x04221468 chip=0x431114e4 rev=0x01 hdr=0x00
        vendor     = 'Broadcom Corporation'
        device     = 'Dell Wireless 1390 WLAN Mini-PCI Card'
        class      = network
        bar   [10] = type Memory, range 32, base 0xd0100000, size 16384, enabled
        cap 01[40] = powerspec 2  supports D0 D1 D2 D3  current D0
        cap 05[58] = MSI supports 1 message
        cap 10[d0] = PCI-Express 1 legacy endpoint
    Code:
    dmesg
    
    bwi0: <Broadcom BCM4311 802.11 Wireless Lan> mem 0xd0100000-0xd0103fff irq 16 at device 0.0 on pci3
    bwi0: [GIANT-LOCKED]
    bwi0: [ITHREAD]
    bwi0: regwin: chipcommon (0x800), rev 17, vendor 0x4243
    bwi0: BBP: id 0x4311, rev 0x1, pkg 0
    bwi0: nregwin 4, cap 0x0064000d
    bwi0: regwin: 802.11 MAC (0x812), rev 10, vendor 0x4243
    bwi0: MAC: rev 10
    bwi0: regwin: usb 1.1 host (0x817), rev 3, vendor 0x4243
    bwi0: regwin: pci express (0x820), rev 1, vendor 0x4243
    bwi0: clksrc CS_OSC
    bwi0: clkfreq min 990000, max 1010000
    bwi0: power on delay 3
    bwi0: bus rev 1
    bwi0: pci express is enabled
    bwi0: card flags 0x4a49
    bwi0: 0th led, act 2, lowact 0
    bwi0: 1th led, act 5, lowact 0
    bwi0: 2th led, act 4, lowact 0
    bwi0: 3th led, act 0, lowact 0
    bwi0: 802.11 MAC was already disabled
    bwi0: PHY is linked
    bwi0: PHY: type 2, rev 8, ver 4
    bwi0: PHY: 802.11G attach
    bwi0: RF: manu 0x17f, type 0x2050, rev 2
    bwi0: bus rev 1
    bwi0: PHY is linked
    bwi0: 32bit bus space
    bwi0: max txpower from sprom: 74 dBm
    bwi0: invalid antenna gain in sprom
    bwi0: ant gain 8 dBm
    bwi0: region/domain max txpower 76 dBm
    bwi0: max txpower 74 dBm
    bwi0: sprom idle tssi: 0xff3e
    bwi0: TSSI-TX power map:
    85 85 84 84 84 83 83 83
    82 82 81 81 80 80 79 79
    78 78 77 77 77 76 76 74
    74 73 73 72 71 70 70 69
    68 67 66 65 64 63 62 61
    60 59 57 56 54 53 51 50
    48 46 44 42 39 37 35 32
    30 26 23 19 15 11 6 1
    bwi0: idle tssi0: 62
    bwi0: bus rev 1
    bwi0: locale: 0
    bwi0: WARNING: using obsoleted if_watchdog interface
    bwi0: Ethernet address: 00:19:7e:5e:8c:a3
    KDE3's "Network Tools" shows the device listed as "Wireless Interface (bwi0)" but gives its state as "inactive". So then...how do I activate it? I seem to be missing something here...
     
  3. paradox

    paradox New Member

    Messages:
    97
    Likes Received:
    0
  4. Eponasoft

    Eponasoft New Member

    Messages:
    218
    Likes Received:
    0
    Code:
    ifconfig bwi0
    
    bwi0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
            ether 00:19:7e:5e:8c:a3
            media: IEEE 802.11 Wireless Ethernet autoselect (autoselect)
            status: no carrier
            ssid "" channel 1 (2412 Mhz 11b)
            authmode OPEN privacy OFF bmiss 7 scanvalid 60 bintval 0
    Hrm...that article is highly technical and most of it just flies over my head. Is there an idiot's version of it somewhere? :)
     
  5. Gusi

    Gusi New Member

    Messages:
    21
    Likes Received:
    0
    Phy

    Hi,

    I've been testing the driver for a while, my system is :
    and my card :

    and I found those errors while being quite near to my AP (which is a FBSD 7.2 machine with and Atheros card) :

    The connection remains dead until an /etc/rc.d/netif restart is made. I seen this kind of errors quite frequently. If I try large transfer it happens. If I try no activity, it seems to remain stable. If I try web activity, it happens from time to time.

    The error happens at if_bwi.c:1650.

    With a pcmcia atheros card (not mine) I didn't saw those problems. Should it (the bwi card) be able to recover automagically ?

    Greets,

    Gusi
     
  6. everypot

    everypot New Member

    Messages:
    202
    Likes Received:
    0
    I did the same. But mine doesn't work...

    Code:
    # ifconfig
    re0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
            options=389b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,WOL_UCAST,WOL_MCAST,WOL_MAGIC>
            ether 00:23:5a:d1:70:84
            inet 192.168.1.107 netmask 0xffffff00 broadcast 192.168.1.255
            media: Ethernet autoselect (100baseTX <full-duplex>)
            status: active
    lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
            options=3<RXCSUM,TXCSUM>
            inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
            inet6 ::1 prefixlen 128
            inet 127.0.0.1 netmask 0xff000000
    Code:
    pciconf -lvcb
    
    bwi0@pci0:2:0:0:        class=0x028000 card=0x04b514e4 chip=0x431514e4 rev=0x01 hdr=0x00                                                                        
        vendor     = 'Broadcom Corporation'                                         
        device     = 'Broadcom Wireless b/g (BCM4315/BCM22062000)'                  
        class      = network                                                        
        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
        cap 10[d0] = PCI-Express 1 endpoint max data 128(128) link x1(x1)
    re0@pci0:3:0:0: class=0x020000 card=0x389e17aa chip=0x813610ec rev=0x02 hdr=0x00
        vendor     = 'Realtek Semiconductor'
        device     = 'RTL8100E/RTL8101E/RTL8102E-GR (RTL8100-8101E-8102E-PCIEXPRESS)'
        class      = network
        subclass   = ethernet
        bar   [10] = type I/O Port, range 32, base 0x2000, size 256, enabled
        bar   [18] = type Prefetchable Memory, range 64, base 0x92010000, size 4096, enabled
        bar   [20] = type Prefetchable Memory, range 64, base 0x92000000, size 65536, enabled
        cap 01[40] = powerspec 3  supports D0 D1 D2 D3  current D0
        cap 05[50] = MSI supports 1 message, 64 bit enabled with 1 message
        cap 10[70] = PCI-Express 2 endpoint IRQ 2 max data 128(256) link x1(x1)
        cap 11[ac] = MSI-X supports 2 messages in map 0x20
        cap 03[cc] = VPD
    Code:
    dmesg
    
    bwi0: PHY: type 5, rev 1, ver 6
    phy_att 4
    phy_att 5
    bwi0: RF: manu 0x17f, type 0x2062, rev 2
    bwi0: unsupported 11LP PHY, rev 1
    att fa 4
    device_attach: bwi0 attach returned 6
    re0: link state changed to DOWN
    re0: link state changed to UP



     
  7. paradox

    paradox New Member

    Messages:
    97
    Likes Received:
    0
    this log I need to determine which versions radiochip in the broadcom

    as i see
    only versions 0x2062 in model 0x4315
    but i know there exist is 0x2063

    I would like to know who has such

    my be version 2063 inside asus-wl router
     
  8. everypot

    everypot New Member

    Messages:
    202
    Likes Received:
    0
    My Lenovo s10-2 has BCM4315 ( Lenovo says it is a BCM4312. wtf.). Cannot make it work on FreeBSD 8 beta 3.

    So BCM4315 is not supported on FreeBSD 8?
     
  9. paradox

    paradox New Member

    Messages:
    97
    Likes Received:
    0
    not yet
     
  10. everypot

    everypot New Member

    Messages:
    202
    Likes Received:
    0
    Hi Paradox,

    I tried to use ndisgen and/or NDIS to convert the windows driver. I got the .ko files successful:

    Code:
    # pwd
    /usr/src/sys/modules/if_ndis
    # ls
    Makefile                if_ndis.ko              opt_usb.h
    bcmwl5.inf              if_ndis.o               pccarddevs.h
    bcmwl5.inf.ascii        if_ndis_pccard.o        pci_if.h
    bcmwl5.sys              if_ndis_pci.o           usb_if.h
    bcmwl5_sys.ko           if_ndis_usb.o           usbdevs.h
    card_if.h               ndis_driver_data.h
    if_ndis.kld             opt_bus.h
    
    # kldload ndis
    #kldload if_ndis
    # kldload bcmwl5_sys.ko
    [B]kldload: bcmwl5_sys.ko is not in the module path[/B]
    # kldstat
    Id Refs Address    Size     Name
     1   47 0xc0400000 d01484   kernel
     2    1 0xc1102000 a63c     if_re.ko
     3    1 0xc110d000 362e0    if_bwi.ko
     4    1 0xc637c000 9000     i915.ko
     5    1 0xc6385000 14000    drm.ko
     6    2 0xc7c66000 27000    linux.ko
     7    1 0xca070000 8000     linprocfs.ko
     8    1 0xcb0eb000 19000    snd_hda.ko
     9    1 0xcb104000 57000    sound.ko
    10    1 0xcbae9000 d000     if_ndis.ko
    11    1 0xcc0ee000 19000    ndis.ko
    
    ifconfig shows no wireless card. I don't know what's wrong.

    Followed instruction from:
    http://www.freebsd.org/doc/en/books/handbook/config-network-setup.html

    and

    http://dannyman.toldme.com/2005/01/05/freebsd-howto-ndisulate-windows-drivers/
     
  11. paradox

    paradox New Member

    Messages:
    97
    Likes Received:
    0
    try to put .ko module in the dir /boot/modules/
     
  12. richardpl

    richardpl New Member

    Messages:
    841
    Likes Received:
    0
    Instead of ndiscvt you should really use ndisgen(8) instead, it is available for FreeBSD 6 and higher.
     
  13. everypot

    everypot New Member

    Messages:
    202
    Likes Received:
    0
    ---------------------------------------------------------

    I put bcmwl5_sys.ko(by ndisgen), if_ndis.ko & ndis.ko (by ndiscvt)into /boot/modules and rebooted the system. Now I get


    Code:
    ifconfig
    ndis0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 2290
            ether 00:21:00:f7:46:35
            media: IEEE 802.11 Wireless Ethernet autoselect (autoselect)
            status: [color="Red"][B]no carrier[/B][/color]
    # pciconf -lvcb


    Code:
    kldstat
    Id Refs Address    Size     Name
     1   49 0xc0400000 d01484   kernel
     2    1 0xc1102000 a63c     if_re.ko
     3    1 0xc110d000 1acb4    snd_hda.ko
     4    2 0xc1128000 62018    sound.ko
     5    1 0xc118b000 5a90     acpi_video.ko
     6    2 0xc1191000 f590     [B]if_ndis.ko[/B]
     7    3 0xc11a1000 1e030    [B]ndis.ko[/B]
     8    1 0xc11c0000 362e0    [B]if_bwi.ko[/B]
     9    1 0xc11f7000 1afc78   [B]bcmwl5_sys.ko[/B]
    10    1 0xc6271000 27000    linux.ko
    11    1 0xc643d000 9000     i915.ko
    12    1 0xc6446000 14000    drm.ko
    
    In rc.conf
    Code:
    ifconfig_bwi0="WPA DHCP"
    ifconfig_ndis0="WPA DHCP"
    loader.conf
    Code:
    if_ndis_load="YES"
    if_bwi_load="YES"
    if_re_load="YES"
    snd_hda_load="YES"
    bcmwl5_sys_load="YES"
    acpi_video_load="YES"
     
  14. paradox

    paradox New Member

    Messages:
    97
    Likes Received:
    0
  15. everypot

    everypot New Member

    Messages:
    202
    Likes Received:
    0
  16. everypot

    everypot New Member

    Messages:
    202
    Likes Received:
    0
    I tried
    Code:
    wpa_supplicant -B -c /etc/wpa_supplicant.conf -i ndis0
    ioctl[SIOCG80211, op 98, len 32]: Invalid argument        
    Failed to initialize driver interface
    ELOOP: remaining socket: sock=4 eloop_data=0x28406140 user_data=0x2840d040 handler=0x8069f40
    
    
    Code:
    ctrl_interface=/var/run/wpa_supplicant
    ctrl_interface_group=wheel  
    #eapol_version=1            
    #ap_scan=1                  
    network={                   
            scan_ssid=1         
            ssid="myid"      
            proto=WPA           
            key_mgmt=WPA-PSK    
            pairwise=CCMP TKIP  
            psk="mypassword"  
            priority=2      
    }                       
    
     
  17. paradox

    paradox New Member

    Messages:
    97
    Likes Received:
    0
    Code:
    wpa_supplicant -Dndis -c /etc/wpa_supplicant.conf -i ndis0
    Code:
    paradox@hosting[10:44:02]~> wpa_supplicant
    
    usage:
      wpa_supplicant [-BddhKLqqstuvwW] [-P<pid file>] [-g<global ctrl>] \
            -i<ifname> -c<config file> [-C<ctrl>] [-D<driver>] [-p<driver_param>] \
            [-b<br_ifname>] [-f<debug file>] \
            [-N -i<ifname> -c<conf> [-C<ctrl>] [-D<driver>] \
            [-p<driver_param>] [-b<br_ifname>] ...]
    
    drivers:
      bsd = BSD 802.11 support (Atheros, etc.)
      ndis = Windows NDIS driver
      wired = wpa_supplicant wired Ethernet driver
    options:
      -b = optional bridge interface name
      -B = run daemon in the background
      -c = Configuration file
      -C = ctrl_interface parameter (only used if -c is not)
      -i = interface name
      -d = increase debugging verbosity (-dd even more)
      -D = driver name
      -g = global ctrl_interface
      -K = include keys (passwords, etc.) in debug output
      -t = include timestamp in debug messages
      -h = show this help text
      -L = show license (GPL and BSD)
      -p = driver parameters
      -P = PID file
      -q = decrease debugging verbosity (-qq even less)
      -s = log output to syslog instead of stdout
      -v = show version
      -w = wait for interface to be added, if needed
      -W = wait for a control interface monitor before starting
      -N = start describing new interface
    example:
      wpa_supplicant -Dbsd -iwlan0 -c/etc/wpa_supplicant.conf
    
     
  18. everypot

    everypot New Member

    Messages:
    202
    Likes Received:
    0
    I rebooted and looks like it's closer to success.Not yet, cannot ping http://www.google.com (but later, I got it work! see the end of this post~~):

    Code:
    ifconfig                                                                    
    [B]ndis0[/B]: 
    flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST>metric 0 mtu 2290     
    ether   00:21:00:f7:46:35                    
    media: IEEE 802.11 Wireless Ethernet autoselect mode 11g    
    status: [B]associated[/B]
    [B]wlan0[/B]: 
    flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
    ether 00:21:00:f7:46:35
    media: IEEE 802.11 Wireless Ethernet OFDM/54Mbps mode 11g
    status: associated
    ssid myid channel 6 (2437 Mhz 11g) bssid 00:18:e7:30:72:5c
    country US authmode WPA privacy OFF txpower 0 bmiss 7 mcastrate 6
    mgmtrate 6 scanvalid 60 protmode CTS roaming MANUAL bintval 0
    
    Cannot bring ndis0 up:
    Code:
    # ifconfig ndis0 up scan              
    ifconfig: unable to get scan results
    wlan0 can:
    Code:
    #ifconfig wlan0 up scan
    SSID/MESH ID    BSSID            CHAN RATE   S:N     INT CAPS
    07FX10069425    00:12:0e:71:0f:9a    6   54M -83:-96  100 EP
    myid            00:18:e7:30:72:5c    6   54M -46:-96  100 EPS
    Mikeys WiFi...  00:18:f8:a7:06:1f    6   54M -55:-96  100 EPS
    ........
    My /etc/rc.conf:

    Code:
    ifconfig_bwi0="WPA DHCP"
    ifconfig_ndis0="WPA DHCP"
    ifconfig_wlan0="WPA DHCP"
    wpa_supplicant_enable="YES"
    wlans_ndis0="wlan0"
    all are required to get ndis0 and wlan0 "status: associate".

    At this point, I cannot ping http://www.google.com.
    Then I did something magic
    Code:
    # dhclient wlan0
    After that, I'm writing this post by wireless!!!
    One last question: anyone know how to run dhclient wlan0 at boot time?
     
  19. grocha

    grocha New Member

    Messages:
    9
    Likes Received:
    0
    As I understand this line
    Code:
    ifconfig_wlan0="WPA DHCP"
    in /etc/rc.conf shoul'd do that. At least it does for me ;)
     
  20. paradox

    paradox New Member

    Messages:
    97
    Likes Received:
    0
    try to look at
    Code:
    ps ax|grep dhclient
    before run from console
    Code:
    # dhclient wlan0
     
  21. everypot

    everypot New Member

    Messages:
    202
    Likes Received:
    0
    Code:
    ps ax|grep dhclient
     1383   0  S+     0:00.01 grep dhclient
     
  22. everypot

    everypot New Member

    Messages:
    202
    Likes Received:
    0
    If I comment that off, I will get (ifconfig) "status: no carrier" for both ndis0 and wlan0. And wouldn't be able to get the network working. And dhclient wlan0/ndis0 will give "no link... give up". Also, I notice that at boot time there are messages like "failed to start wpa_supplicant:... Op 98.. invalid argument...".

    Enable "ifconfig_wlan0="WPA DHCP" solved the problem, only takes longer to boot:"waiting 30s for the default route interface.....ndis0:link state change to UP ................"
     
  23. paradox

    paradox New Member

    Messages:
    97
    Likes Received:
    0
    Code:
    wpa_supplicant_enable="YES"
    wlans_ndis0="wlan0"
    ifconfig_wlan0="WPA DHCP"
    should be enough

    remove another unused line
     
  24. everypot

    everypot New Member

    Messages:
    202
    Likes Received:
    0
    Yes. You are right. I just tested it. Still need to use "dhclient wlan0" to bring the network up. But the error message at boot time"waiting 30s for the default route interface.....ndis0:link state change to UP ................" disappeared!

    Great. Thank you for all the help! And hope the information can be useful to other people.
     
  25. Seeker

    Seeker New Member

    Messages:
    856
    Likes Received:
    0
    So..., what is a current status / solution for
    Code:
    BCM94321KFBG Broadcom 4321AGN 802.11a/b/g/draft-n Wi-Fi Solution
    I really need that driver for FreeBSD 7.2 ;)