LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices



Reply
 
Search this Thread
Old 03-15-2012, 08:32 PM   #1
Rod3775
Member
 
Registered: May 2008
Location: Washington State
Distribution: Slackware-14.1
Posts: 34
Blog Entries: 8

Rep: Reputation: 0
wpa_supplicant dropouts with Ralink 2870 USB wireless dongle


I am using the freebie MSI 3070 wireless USB dongle that comes with the Intel DP67BG motherboard. It works, but every 1/2 to 1 hour fails to reauthenticate with my AP using WPA2. wpa_supplicant then loops forever probing for the AP. If I set the debug level way up and generate tons of debug output, it fails much less frequently, sometimes not at all, suggesting a timing issue. I've written a monitor to watch wpa_supplicant and kill and restart it when this happens. It associates on the first try after a restart. I am using the nl80211 backend for wpa_supplicant, and the rt2800usb driver from my slackware64-13.37 distribution. One thing I notice is that while the kernel output (printk) from rt2800usb timestamps its probes 200ms apart, if I look at the actual radio traffic with airodump-ng, the probes are coming out one right after another, 5ms apart, with no traffic in between. The probe response doesn't get in until probe requests stop going out and the AP has a chance to say something. Then there are several, but by then the driver has given up. I know there is a tx queue in the mac802.11 stack, and I'm guessing the queue is not getting run after each probe is queued up so they all go out at once. For what its worth, the wireless dongle is the only device on this particular USB bus.

I have a laptop on the same wireless network with a Broadcom wireless chip (b43 driver), and it works flawlessly. But the laptop is old and slow, and the Intel motherboard has a Core5 64 bit processor that is tons faster (not to mention quad core) and I have a feeling the speed differential is related to the problem...

I've got a usbmon trace of the traffic to the dongle, but trying to interpret it and find the mac802.11 frames is like trying to learn Mandarin, and I haven't been able to decipher the trace. I'd like to get the probes better spaced as they go out on the radio, but I don;t know how to do that. Any ideas?
 
Old 03-16-2012, 01:45 PM   #2
H_TeXMeX_H
Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269
I would try updating to the latest kernel and/or wifi drivers. Maybe it's a bug and they have fixed it. You didn't post what kernel you are using.
 
Old 03-17-2012, 01:29 PM   #3
Rod3775
Member
 
Registered: May 2008
Location: Washington State
Distribution: Slackware-14.1
Posts: 34
Blog Entries: 8

Original Poster
Rep: Reputation: 0
using current kernel/drivers

Slackware64-13.37 uses the 2.6.37 kernel. This IS the latest w/o stepping outside the distribution. New info: I ran Wireshark against wlan0 and got no useful info - the management frames (which is where the problem is) are not captured there. I ran in monitor mode, and, as advertised, authentication is broken by monitor mode. So no joy there. I ran a usb monitor capture and have the requisite data in usb packet format. But Wireshark won't break out the MAC frames embedded in that, so some coding will be required. I note that there is some code in the driver (rt2x00usb) to force ("kick") the tx queue to be sent - bulk USB transfers do not have latency guarantees, and it isn't clear if the "kick" code is used for management frames anyway. I also note some comments in the mac80211 core code that various aspects of duration control are not implemented. At this point I'm not sure if that is relevant to this problem or not. Need advice from those who understand the 80211 stack better than I do.
 
Old 04-16-2012, 12:52 PM   #4
Rod3775
Member
 
Registered: May 2008
Location: Washington State
Distribution: Slackware-14.1
Posts: 34
Blog Entries: 8

Original Poster
Rep: Reputation: 0
[SOLVED] Ralink dropouts fixed by compat-wireless

I downloaded and compiled the compat-wireless-2.6 package for the rt2800 driver (+mac80211 and friends) and the dropouts have disappeared. I used the 2012-04-14 version. Be advised that the entire package WILL NOT compile against the 2.6.37 kernel sources used by Slackware64-13.37. There is a reference to a nonexistent power management routine in the wl12xx driver that breaks the full compile. All the others work and can be compiled individually with some pain. FYI: the problem in the rt2800 driver in the Slackware distro is timing related. Using the same wireless hardware and the same kernel source on an old Pentium IV uniprocessor works much better - occasional dropouts but nothing serious. Its only the fast 4 core 64 bit processor that fails. But the compat-wireless package cures that well enough that wpa-supplicant and/or the wireless stack doesn't hang like it did before. It simply reauths/reassocs without retries, like it is supposed to.

Whew!
 
Old 05-03-2012, 12:04 PM   #5
Rod3775
Member
 
Registered: May 2008
Location: Washington State
Distribution: Slackware-14.1
Posts: 34
Blog Entries: 8

Original Poster
Rep: Reputation: 0
FYI: the b43 driver in compat-wireless will not load on slackware-13.37 (32 bit). Fortunately, the distro version works fine. I had to revert after building compat-wireless on my laptop to test my USB dongle. The built-in wireless then no longer worked. The compat-wireless version compiled, but needed symbols not in the 2.6.37 kernel in order to modprobe successfully.
 
  


Reply

Tags
64bit, slackware 13.37, usb, wireless, wpasupplicant


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Installing Ralink 2870 USB in Fedora 11 petenaylor Linux - Wireless Networking 4 09-25-2010 05:37 PM
How could i cross compile ralink RT 2870 USB drivers with codesourcery tool chain? majji.hari Linux - Hardware 2 05-10-2010 11:30 AM
[SOLVED] Cannot connect in Ubuntu 10.04 with Ralink 2870 MrLove247 Linux - Wireless Networking 1 05-07-2010 04:06 PM
Ralink 2870 with recent Slackware-current alexiy Slackware 1 03-13-2010 04:55 AM
USB Wifi adapter D-Link DWA-125 (Ralink 2870) friendly distro? janimalia Linux - Wireless Networking 3 01-25-2010 03:30 PM


All times are GMT -5. The time now is 04:30 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration