From patchwork Fri Mar 20 01:32:34 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Pat Fruth X-Patchwork-Id: 452413 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from arrakis.dune.hu (arrakis.dune.hu [78.24.191.176]) (using TLSv1.1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 764E3140134 for ; Fri, 20 Mar 2015 12:32:56 +1100 (AEDT) Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 185A92815A3; Fri, 20 Mar 2015 02:32:15 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on arrakis.dune.hu X-Spam-Level: X-Spam-Status: No, score=-1.5 required=5.0 tests=BAYES_00, T_RP_MATCHES_RCVD autolearn=unavailable version=3.3.2 Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id E81BA281573 for ; Fri, 20 Mar 2015 02:32:08 +0100 (CET) X-policyd-weight: using cached result; rate: -7.6 Received: from patfruth.com (patfruth.com [70.57.37.193]) by arrakis.dune.hu (Postfix) with ESMTPS for ; Fri, 20 Mar 2015 02:32:08 +0100 (CET) Received: by patfruth.com (Postfix, from userid 1001) id CEEDA394; Thu, 19 Mar 2015 19:32:54 -0600 (MDT) Received: from [192.168.1.53] (patfruth.com [70.57.37.193]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: pat) by patfruth.com (Postfix) with ESMTPSA id 3B9C21DB; Thu, 19 Mar 2015 19:32:53 -0600 (MDT) Mime-Version: 1.0 (Mac OS X Mail 8.2 \(2070.6\)) From: Pat Fruth In-Reply-To: <1426737950.2754.30.camel@pluto.fritz.box> Date: Thu, 19 Mar 2015 19:32:34 -0600 Message-Id: References: <1426737950.2754.30.camel@pluto.fritz.box> To: Ian Kent X-Mailer: Apple Mail (2.2070.6) Cc: openwrt-devel@lists.openwrt.org Subject: Re: [OpenWrt-Devel] [PATCH v2] [package] mwlwifi: generate TX_STATUS event on transmitting auth, associate, and reallocate responses X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: openwrt-devel-bounces@lists.openwrt.org Sender: "openwrt-devel" > On Mar 18, 2015, at 10:05 PM, Ian Kent wrote: > > On Wed, 2015-03-18 at 21:40 -0600, Pat Fruth wrote: >> This patch addresses an issue specific to Apple devices experiencing a wireless disconnect when trying to associate with either 2.4Ghz or 5Ghz wifi of a Linksys WRT1900AC router. >> Apple devices (MacBooks running Mac OS X 10.10.x Yosemite in particular, but there may be others), appear to re-auth/re-associate within approximately 25 seconds of initially associating. >> Evidence of this can be seen by the presence of an entry similar to the following in the Apple system logs; >> MM/DD/YY HH:MM:SS.sss AM kernel[0]: wl0: Roamed or switched channel, reason #8, bssid xx:xx:xx:xx:xx:xx >> The Marvell wifi driver doesn’t generate a NL80211_CMD_FRAME_TX_STATUS event on transmitting a response to auth and/or reassociate requests. Thus, the respective callback handler functions (in hostapd’s ieee802_11.c) never get driven, ultimately leading to the problem. >> The patch causes a TX_STATUS event to be generated for auth and reassociate request’s responses, in addition to associate request’s responses. >> >> Signed-off-by: Pat Fruth >> --- >> .../mwlwifi/patches/002_TX-STATUS-for-reassoc-auth.patch | 14 ++++++++++++++ >> 1 file changed, 14 insertions(+) >> create mode 100644 package/kernel/mwlwifi/patches/002_TX-STATUS-for-reassoc-auth.patch >> >> diff --git a/package/kernel/mwlwifi/patches/002_TX-STATUS-for-reassoc-auth.patch b/package/kernel/mwlwifi/patches/002_TX-STATUS-for-reassoc-auth.patch >> new file mode 100644 >> index 0000000..5f0d7fb >> --- /dev/null >> +++ b/package/kernel/mwlwifi/patches/002_TX-STATUS-for-reassoc-auth.patch >> @@ -0,0 +1,14 @@ >> +--- a/mwl_tx.c >> ++++ b/mwl_tx.c >> +@@ -395,7 +395,10 @@ void mwl_tx_done(unsigned long data) >> + >> + tr = (struct mwl_dma_data *)done_skb->data; >> + >> +- if (ieee80211_is_assoc_resp(tr->wh.frame_control)) { >> ++ // if (ieee80211_is_assoc_resp(tr->wh.frame_control)) { >> ++ if (ieee80211_is_assoc_resp(tr->wh.frame_control) || >> ++ ieee80211_is_reassoc_resp(tr->wh.frame_control) || >> ++ ieee80211_is_auth(tr->wh.frame_control)) { >> + >> + /* Remove H/W dma header >> + */ > > I don't think there's anything to be gained by commenting out the > original line. It only adds extra noise and the change that's been made > is evident from the log. > > Ian > Thanks Ian. Fair enough. Here’s the patch, this time without the commented line of code. Signed-off-by: Pat Fruth --- .../mwlwifi/patches/002_TX-STATUS-for-reassoc-auth.patch | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 package/kernel/mwlwifi/patches/002_TX-STATUS-for-reassoc-auth.patch -- 1.9.1 diff --git a/package/kernel/mwlwifi/patches/002_TX-STATUS-for-reassoc-auth.patch b/package/kernel/mwlwifi/patches/002_TX-STATUS-for-reassoc-auth.patch new file mode 100644 index 0000000..f454cc5 --- /dev/null +++ b/package/kernel/mwlwifi/patches/002_TX-STATUS-for-reassoc-auth.patch @@ -0,0 +1,13 @@ +--- a/mwl_tx.c ++++ b/mwl_tx.c +@@ -395,7 +395,9 @@ void mwl_tx_done(unsigned long data) + + tr = (struct mwl_dma_data *)done_skb->data; + +- if (ieee80211_is_assoc_resp(tr->wh.frame_control)) { ++ if (ieee80211_is_assoc_resp(tr->wh.frame_control) || ++ ieee80211_is_reassoc_resp(tr->wh.frame_control) || ++ ieee80211_is_auth(tr->wh.frame_control)) { + + /* Remove H/W dma header + */