From patchwork Tue May 3 23:15:55 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Javier Cardona X-Patchwork-Id: 751982 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p43NGUFK027255 for ; Tue, 3 May 2011 23:16:30 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755445Ab1ECXQE (ORCPT ); Tue, 3 May 2011 19:16:04 -0400 Received: from mail-pv0-f174.google.com ([74.125.83.174]:55348 "EHLO mail-pv0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754238Ab1ECXQC (ORCPT ); Tue, 3 May 2011 19:16:02 -0400 Received: by pvg12 with SMTP id 12so247068pvg.19 for ; Tue, 03 May 2011 16:16:02 -0700 (PDT) Received: by 10.68.32.226 with SMTP id m2mr544194pbi.444.1304464561798; Tue, 03 May 2011 16:16:01 -0700 (PDT) Received: from localhost.localdomain (99-8-184-170.lightspeed.snfcca.sbcglobal.net [99.8.184.170]) by mx.google.com with ESMTPS id i9sm325505pbd.38.2011.05.03.16.16.00 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 03 May 2011 16:16:00 -0700 (PDT) From: Javier Cardona To: "John W. Linville" Cc: Javier Cardona , devel@lists.open80211s.org, linux-wireless@vger.kernel.org, greearb@candelatech.com, ath9k-devel@venema.h4ckr.net Subject: [PATCH] ath9k: fix beaconing for mesh interfaces Date: Tue, 3 May 2011 16:15:55 -0700 Message-Id: <1304464555-2931-1-git-send-email-javier@cozybit.com> X-Mailer: git-send-email 1.7.1 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Tue, 03 May 2011 23:16:31 +0000 (UTC) Mesh beaconing on ath9k was broken by this commit: commit 4801416c76a3a355076d6d371c00270dfe332e1c Author: Ben Greear Date: Sat Jan 15 19:13:48 2011 +0000 This patch assigns the right opmode when the device is used in mesh mode. Reported-by: Fabrice Deyber fabricedeyber@agilemesh.com Signed-off-by: Javier Cardona --- drivers/net/wireless/ath/ath9k/main.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c index c3dbf26..8fa07aa 100644 --- a/drivers/net/wireless/ath/ath9k/main.c +++ b/drivers/net/wireless/ath/ath9k/main.c @@ -1384,7 +1384,9 @@ static void ath9k_calculate_summary_state(struct ieee80211_hw *hw, ath9k_hw_set_tsfadjust(ah, 0); sc->sc_flags &= ~SC_OP_TSF_RESET; - if (iter_data.nwds + iter_data.nmeshes) + if (iter_data.nmeshes) + ah->opmode = NL80211_IFTYPE_MESH_POINT; + else if (iter_data.nwds) ah->opmode = NL80211_IFTYPE_AP; else if (iter_data.nadhocs) ah->opmode = NL80211_IFTYPE_ADHOC;