From owner-freebsd-wireless@FreeBSD.ORG Sun Feb 26 06:11:12 2012 Return-Path: Delivered-To: freebsd-wireless@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AC58F106566C for ; Sun, 26 Feb 2012 06:11:12 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-ww0-f50.google.com (mail-ww0-f50.google.com [74.125.82.50]) by mx1.freebsd.org (Postfix) with ESMTP id 3D93F8FC15 for ; Sun, 26 Feb 2012 06:11:11 +0000 (UTC) Received: by wgbds12 with SMTP id ds12so89989wgb.31 for ; Sat, 25 Feb 2012 22:11:11 -0800 (PST) Received-SPF: pass (google.com: domain of adrian.chadd@gmail.com designates 10.180.95.105 as permitted sender) client-ip=10.180.95.105; Authentication-Results: mr.google.com; spf=pass (google.com: domain of adrian.chadd@gmail.com designates 10.180.95.105 as permitted sender) smtp.mail=adrian.chadd@gmail.com; dkim=pass header.i=adrian.chadd@gmail.com Received: from mr.google.com ([10.180.95.105]) by 10.180.95.105 with SMTP id dj9mr17722825wib.18.1330236671223 (num_hops = 1); Sat, 25 Feb 2012 22:11:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:sender:date:x-google-sender-auth:message-id:subject :from:to:content-type; bh=CEH2oxIFBi6tz6klHq0/ugqPi4L9x4x9JKpuHeeARZk=; b=bXkYrnG+xXDoh190axP3ZtSr6zwySzOZ/e/bb5gUSCm9n7p5qqZujr2HZjmKF45swG nUkxAXMm+TFCGk0q112+WDXli36EODlr0PU/LvYgFzqfIFkvOkIF4M/nnRbC+1uELWMl 0vP58gBxoC8V7u4yhz8W2AOm/WDoVyZafbJBc= MIME-Version: 1.0 Received: by 10.180.95.105 with SMTP id dj9mr14125770wib.18.1330236671162; Sat, 25 Feb 2012 22:11:11 -0800 (PST) Sender: adrian.chadd@gmail.com Received: by 10.216.154.199 with HTTP; Sat, 25 Feb 2012 22:11:11 -0800 (PST) Date: Sat, 25 Feb 2012 22:11:11 -0800 X-Google-Sender-Auth: I7tUxaEwDPT4SgKqsnnBhSCaZKY Message-ID: From: Adrian Chadd To: freebsd-wireless@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Subject: [ath] please test -HEAD: trying to find/fix the rate control and bgscan races X-BeenThere: freebsd-wireless@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Discussions of 802.11 stack, tools device driver development." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 26 Feb 2012 06:11:12 -0000 Hi all, In my "make ALL the old NICs work" work, I found that this AR5211 NIC would panic almost instantly after the first set of background scans. What was happening was an invalid rix was being passed. What really was happening was: * the nic would come up in 11a mode and establish a high throughput rate - eg, 36/54megabit rate; * the best rix in the sample rate module would be high, say 5; * then the operating mode would change (eg for scanning) and a frame would be tx'ed with the operating mode being 11b; * .. and it would pick best_rix, which would then happily return 5 * .. and that's outside of what the current rate map is, which for 11b is a few entries smaller than 11a. Similar weird things have happened before for 11bg/11a NICs as well as the 11n NICs. But this crashed frequently rather than having "weird stuff" happen. So I've committed some stuff to -HEAD which prints out warnings in case a rate control lookup is done with the current rate table not matching what ath_rate_sample was setup for. here's an example of what I saw: wlan0: Ethernet address: 00:03:7f:11:a3:f3 wlan0: link state changed to UP ar5416PerCalibrationN: NF calibration didn't finish; delaying CCA ath0: bad series0 hwrate 0x1b, tries 1 ts_status 0x0 ath0: bad series0 hwrate 0x1b, tries 1 ts_status 0x0 ath0: bad series0 hwrate 0x1b, tries 1 ts_status 0x0 wlan0: link state changed to DOWN wlan0: link state changed to UP ath0: bad series0 hwrate 0x1b, tries 1 ts_status 0x0 ath0: bad series0 hwrate 0x1b, tries 1 ts_status 0x0 ath0: bad series0 hwrate 0x1b, tries 1 ts_status 0x0 [100548] ath0: ath_rate_findrate: currates != sc_currates! [100548] ath0: ath_rate_findrate: currates != sc_currates! ath0: bad series0 hwrate 0x1b, tries 1 ts_status 0x0 ath0: bad series0 hwrate 0x1b, tries 1 ts_status 0x0 [100279] ath0: ath_rate_findrate: currates != sc_currates! ath0: bad series0 hwrate 0x1b, tries 1 ts_status 0x0 [100279] ath0: ath_rate_findrate: currates != sc_currates! I'd really appreciate it if other atheros NIC users would try out -HEAD and let me know if they see the same kind of issue. If you do then please email the list with some information and we'll see if we can track it down. Also as you can see above (this is happening on the AR9280 in 11ng mode), I get "bad series0 hwrate" messages. I need to investigate this a little closer. That's the 1mbit CCK rate - I should print out what the current operating mode is, as I bet that is occuring when we're in an 11a mode. 11ng includes the CCK rates. Thanks, Adrian