1b43a About bwn on FreeBSD 8.1R amd64 - The FreeBSD Forums
The FreeBSD Forums  

Go Back   The FreeBSD Forums > Desktop Usage > Mobile Computing

Mobile Computing This forum discusses issues related to running FreeBSD on notebooks, laptops, and other mobile equipment.

Reply
 
Thread Tools Display Modes
  #1  
Old February 16th, 2011, 08:01
alphachi alphachi is offline
Junior Member
 
Join Date: Mar 2009
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
Default About bwn on FreeBSD 8.1R amd64

OS: FreeBSD 8.1R amd64
Adapter: BCM4309
Crypto: WPA2-PSK

I have installed bwn-firmware-kmod and enabled if_bwn and bwn_v4_ucode on /boot/loader.conf.
When the system starts every time, the console shows:
Code:
bwn0: need multicast update callback
Code:
bwn0: RX decryption attempted (old 0 keyidx 0x1)
Although I can connect the AP, many packets lost when ping AP.
I have tried bwn_v4_lp_ucode instead of bwn_v4_ucode. It can't be used.

Thanks!
Reply With Quote
  #2  
Old February 16th, 2011, 08:36
bschmidt bschmidt is offline
Member
 
Join Date: Oct 2009
Location: Schwandorf, Germany
Posts: 298
Thanks: 0
Thanked 39 Times in 28 Posts
Default

The bwn(4) manpages mentions some loader tunables, did you try those? Especially the usedma one?
Reply With Quote
  #3  
Old February 16th, 2011, 09:10
alphachi alphachi is offline
Junior Member
 
Join Date: Mar 2009
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
Default

When I set usedma from 1 to 0 and restart, the first error was same and the second error turned to
Code:
bwn0: RX decryption attempted (old 0 keyidx 0x2)
Still lost packets...
Reply With Quote
  #4  
Old February 16th, 2011, 11:02
bschmidt bschmidt is offline
Member
 
Join Date: Oct 2009
Location: Schwandorf, Germany
Posts: 298
Thanks: 0
Thanked 39 Times in 28 Posts
Default

Quote:
Originally Posted by alphachi View Post
When I set usedma from 1 to 0 and restart, the first error was same and the second error turned to
Code:
bwn0: RX decryption attempted (old 0 keyidx 0x2)
Still lost packets...
The message about the multicast update is just a warning, you can safely ignore that. I have no clue what the other message is supposed to mean though, keyidx is just the index into the key table (the group and unicast keys), but what's wrong about trying to decrypt a packet? hmm..

*looking at the code*

Seems like the hardware is trying to tell us that it tried 50 times to decrypt frames but failed. Does that happen with other kinds of encryption too? for example WPA1-TKIP?
Reply With Quote
  #5  
Old February 16th, 2011, 11:10
bschmidt bschmidt is offline
Member
 
Join Date: Oct 2009
Location: Schwandorf, Germany
Posts: 298
Thanks: 0
Thanked 39 Times in 28 Posts
Default

Also the output of # wlandebug +crypto might be helpful.
Reply With Quote
  #6  
Old February 16th, 2011, 18:37
richardpl richardpl is offline
Member
 
Join Date: Nov 2008
Location: Croatia
Posts: 841
Thanks: 6
Thanked 68 Times in 67 Posts
Default

Quote:
Originally Posted by alphachi
Although I can connect the AP, many packets lost when ping AP.
Use ucastrate & mcastrate command with ifconfig(8). Set it to something low like 2-10.
Reply With Quote
  #7  
Old February 17th, 2011, 10:11
alphachi alphachi is offline
Junior Member
 
Join Date: Mar 2009
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by bschmidt View Post
The message about the multicast update is just a warning, you can safely ignore that. I have no clue what the other message is supposed to mean though, keyidx is just the index into the key table (the group and unicast keys), but what's wrong about trying to decrypt a packet? hmm..

*looking at the code*

Seems like the hardware is trying to tell us that it tried 50 times to decrypt frames but failed. Does that happen with other kinds of encryption too? for example WPA1-TKIP?
When using no-crypto wifi (ifconfig_wlan0="inet xxx netmask xxx ssid xxx"), no errors. I think the problem is the WPA2-PSK support for bwn.

Last edited by DutchDaemon; February 17th, 2011 at 19:34.
Reply With Quote
  #8  
Old February 17th, 2011, 10:40
alphachi alphachi is offline
Junior Member
 
Join Date: Mar 2009
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by richardpl View Post
Use ucastrate & mcastrate command with ifconfig(8). Set it to something low like 2-10.
Still lost packets...
Reply With Quote
  #9  
Old February 17th, 2011, 10:47
alphachi alphachi is offline
Junior Member
 
Join Date: Mar 2009
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by bschmidt View Post
Also the output of # wlandebug +crypto might be helpful.
When I use this command and input /etc/rc.d/netif start the output is:

Code:
wlan0: [00:1d:0f:6a:63:30] AES-CCM replay detected <rsc 0, csc 0, keyix 0 rxkeyix 65535>
wlan0: ieee80211_crypto_newkey: cipher 3 flags 0x6 keyix 1
wlan0: ieee80211_crypto_newkey: no h/w support for cipher AES-CCM, falling back to s/w
wlan0: ieee80211_crypto_setkey: AES-CCM keyix 1 flags 0x136 mac ff:ff:ff:ff:ff:ff rsc 0 tsc 0 len 16
wlan0: [00:1d:0f:6a:63:30] AES-CCM replay detected <rsc 0, csc 0, keyix 1 rxkeyix 65535>
bwn0: need multicast update callback
bwn0: need multicast update callback
bwn0: need multicast update callback
bwn0: need multicast update callback
wlan0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
wlan0: _ieee80211_crypto_delkey: AES-CCM keyix 1 flags 0x136 rsc 100 tsc 0 len 16
wlan0: _ieee80211_crypto_delkey: AES-CCM keyix 2 flags 0x136 rsc 316 tsc 0 len 16
wlan0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
Feb 17 17:29:10 Ferrari wpa_supplicant[436]: Failed to disable WPA in the driver.
wlan0: _ieee80211_crypto_delkey: AES-CCM keyix 0 flags 0x133 rsc 18 tsc 22 len 16
wlan0: link state changed to DOWN
wlan0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
wlan0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
wlan0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
wlan0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
bwn0: need multicast update callback
ifa_add_loopback_route: insertion failed
bwn0: firmware version (rev 410 patch 2160 date 0x751a time 0x7c0a)
bwn0: need multicast update callback
Feb 17 17:29:11 Ferrari wpa_supplicant[1774]: Failed to disable WPA in the driver.
wlan0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
wlan0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
wlan0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
wlan0: _ieee80211_crypto_delkey: NONE keyix 65535 flags 0x3 rsc 0 tsc 0 len 0
bwn0: firmware version (rev 410 patch 2160 date 0x751a time 0x7c0a)
wlan0: ieee80211_new_state_locked: pending INIT -> SCAN transition lost

Last edited by DutchDaemon; February 17th, 2011 at 19:35.
Reply With Quote
  #10  
Old February 17th, 2011, 11:19
bschmidt bschmidt is offline
Member
 
Join Date: Oct 2009
Location: Schwandorf, Germany
Posts: 298
Thanks: 0
Thanked 39 Times in 28 Posts
Default

Same with other types of encryption? WPA1-TKIP maybe?

Quote:
Code:
wlan0: [00:1d:0f:6a:63:30] AES-CCM replay detected <rsc 0, csc 0, keyix 1 rxkeyix 65535>
That is suspicious.. smells like the hardware itself tries to decrypt the frame and net80211 tries again, hmm..

Last edited by DutchDaemon; February 17th, 2011 at 19:35.
Reply With Quote
  #11  
Old February 17th, 2011, 14:34
kpedersen kpedersen is offline
Member
 
Join Date: Apr 2009
Posts: 679
Thanks: 9
Thanked 102 Times in 74 Posts
Default

I have experienced exactly the same with my bwn card.

Though it works, it does seem to lose packets. Proof of this is when I attempt a ping to the router, sometimes only 20% of the packets succeed and I am only 3m from the AP.

Linux's broadcom-wl driver seems to avoid this problem. I have not tried a windows driver and NDIS.
Reply With Quote
  #12  
Old February 17th, 2011, 14:57
alphachi alphachi is offline
Junior Member
 
Join Date: Mar 2009
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by bschmidt View Post
Same with other types of encryption? WPA1-TKIP maybe?



That is suspicious.. smells like the hardware itself tries to decrypt the frame and net80211 tries again, hmm..
I have tried all crypto options:
WEP
WPA TKIP/AES
WPA2 TKIP/AES
Still wrong...
Reply With Quote
  #13  
Old February 17th, 2011, 16:57
alphachi alphachi is offline
Junior Member
 
Join Date: Mar 2009
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by kpedersen View Post
I have experienced exactly the same with my bwn card.

Though it works, it does seem to lose packets. Proof of this is when I attempt a ping to the router, sometimes only 20% of the packets succeed and I am only 3m from the AP.

Linux's broadcom-wl driver seems to avoid this problem. I have not tried a windows driver and NDIS.
I have tried Windows driver and NDIS, "fatal error" to system hang.

I found Broadcom 802.11 Linux STA driver:
http://www.broadcom.com/support/802.11/linux_sta.php
Can I use it on FreeBSD? If possible, how to do?
Reply With Quote
  #14  
Old February 25th, 2011, 14:38
richardpl richardpl is offline
Member
 
Join Date: Nov 2008
Location: Croatia
Posts: 841
Thanks: 6
Thanked 68 Times in 67 Posts
Default

FreeBSD 8.1 amd64 have broken NDIS, try 8.2 instead.
Reply With Quote
  #15  
Old April 11th, 2011, 05:30
yurigor yurigor is offline
Junior Member
 
Join Date: Sep 2009
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by richardpl View Post
FreeBSD 8.1 amd64 have broken NDIS, try 8.2 instead.
I'm trying 8.2 now: FreeBSD 8.2-RELEASE amd64 accessing AP with WPA-PSK encryption enabled. AP is 2m away from notebook [Dell Vostro 3500 with Broadcom BCM4312 (as siba reports)], directly visible.

Loaded modules: if_bwn.ko siba_bwn.ko wlan.ko wlan_amrr.ko wlan_wep.ko wlan_ccmp.ko wlan_tkip.ko bwn_v4_lp_ucode.ko. Within first 1-2 mins after boot I get
Code:
bwn0: RX decryption attempted (old 0 keyidx 0x2)
errors at tty0. Pinging AP gives 20% to 50% packet loss out of 1000 packages.

Loading Ubuntu LiveCD at the same conditions and installing offered 802.11 Linux STA driver gives 0% packet loss.
__________________
http://ittomsk.ru - IT-outsourcing in Tomsk, Russia.

Last edited by DutchDaemon; April 11th, 2011 at 11:48.
Reply With Quote
  #16  
Old April 12th, 2011, 11:15
yurigor yurigor is offline
Junior Member
 
Join Date: Sep 2009
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Filed a PR kern/156327: [bwn] bwn driver causes 20%-50% packet loss
__________________
http://ittomsk.ru - IT-outsourcing in Tomsk, Russia.
Reply With Quote
  #17  
Old July 14th, 2012, 13:32
blaize blaize is offline
Junior Member
 
Join Date: May 2012
Posts: 21
Thanks: 2
Thanked 3 Times in 3 Posts
Default

Hello,
I had the same issue, about 50% of packet loss with bwn on Broadcom BCM4312.
This is an old chip, you have to load the LP micro code (bwn_v4_lp_ucode).
Then, when you create virtual interface with ifconfig, it put you default mode on 802.11n.
But, this card doesn't not support 802.11n. You just have to switch back on 802.11b and all work good with 0% packet loss.

Quote:
ifconfig wlan create wlandev bwn0 mode 11b
Sorry if my english is bad. Hope that help you !
Reply With Quote
The Following User Says Thank You to blaize For This Useful Post:
pierre (March 13th, 2013)
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
FreeBSD does not boot on AMD64 penna Mobile Computing 2 August 4th, 2010 00:47
RTL8191SE and FreeBSD 8.0 amd64 Nightweaver System Hardware 0 February 25th, 2010 21:54
FreeBSD 8.0 - amd64 - ZFS solskogen General 3 February 6th, 2010 09:56
FreeBSD amd64 Ofloo Installing & Upgrading 9 May 19th, 2009 06:35
FreeBSD-SA-08:07.amd64 admin News & Announcements 0 September 5th, 2008 03:21


All times are GMT +1. The time now is 18:26.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2013, vBulletin Solutions, Inc.
The mark FreeBSD is a registered trademark of The FreeBSD Foundation and is used by The FreeBSD Project with the permission of The FreeBSD Foundation.
Web protection and acceleration provided by CloudFlare
0