From owner-freebsd-bugs@FreeBSD.ORG Tue Jun 26 07:30:13 2012 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id DFAA71065672 for ; Tue, 26 Jun 2012 07:30:13 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 9E64F8FC16 for ; Tue, 26 Jun 2012 07:30:13 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id q5Q7UDAl022582 for ; Tue, 26 Jun 2012 07:30:13 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q5Q7UDLp022580; Tue, 26 Jun 2012 07:30:13 GMT (envelope-from gnats) Resent-Date: Tue, 26 Jun 2012 07:30:13 GMT Resent-Message-Id: <201206260730.q5Q7UDLp022580@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Adrian Chadd Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2E623106566B for ; Tue, 26 Jun 2012 07:27:21 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id 19F2D8FC08 for ; Tue, 26 Jun 2012 07:27:21 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.4/8.14.4) with ESMTP id q5Q7RKQJ044028 for ; Tue, 26 Jun 2012 07:27:20 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.4/8.14.4/Submit) id q5Q7RKZm044027; Tue, 26 Jun 2012 07:27:20 GMT (envelope-from nobody) Message-Id: <201206260727.q5Q7RKZm044027@red.freebsd.org> Date: Tue, 26 Jun 2012 07:27:20 GMT From: Adrian Chadd To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: kern/169432: [ath] BAR TX hang when aggregation session is reset during a reassociation X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Jun 2012 07:30:14 -0000 >Number: 169432 >Category: kern >Synopsis: [ath] BAR TX hang when aggregation session is reset during a reassociation >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Jun 26 07:30:13 UTC 2012 >Closed-Date: >Last-Modified: >Originator: Adrian Chadd >Release: 9.0-STABLE with -HEAD net80211/ath >Organization: >Environment: >Description: When doing some iperf testing from a FreeBSD 802.11n station -> FreeBSD 802.11n AP, I noticed the AP would get wedged. When I flushed the interface, the STA node was showing as 'BAR wait' - ie, it was paused due to a pending BAR TX. Enabling "wlandebug +11n" showed that the AP would start sending BAR frames and would get about 20 or 30 of them in (with failed retries), then stop sending them. The hardware was reporting a TX failure, but something was disabling it. After much printf debugging on the AP, I finally figured it out. Here's what was going on. * The STA was going deaf, so all TX to it was failing; * The AP would start sending BAR TX frames; * The STA would hit a beacon miss and rescan, and reassociate to the AP; * The reassociation request was going via ieee80211_ht_node_init(); * .. and that called ieee80211_ht_node_cleanup() to reset the existing state; * .. which reset the TX/RX aggregation state, stopped the timer. . and unfortunately, my ath_addba_stop() routine wasn't undoing a BAR suspended pause. >How-To-Repeat: >Fix: The fix is to check if the node is currently undergoing bar_wait and if so, unpause it. The trick however is handling the tiny race condition where this occurs between the bar TX being in flight and having completed TX. >Release-Note: >Audit-Trail: >Unformatted: