From patchwork Fri Aug 7 10:34:49 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kalle Valo X-Patchwork-Id: 39873 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n77AZ6rp004639 for ; Fri, 7 Aug 2009 10:35:06 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757434AbZHGKfD (ORCPT ); Fri, 7 Aug 2009 06:35:03 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1757432AbZHGKfD (ORCPT ); Fri, 7 Aug 2009 06:35:03 -0400 Received: from smtp.nokia.com ([192.100.122.230]:45756 "EHLO mgw-mx03.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757344AbZHGKfB (ORCPT ); Fri, 7 Aug 2009 06:35:01 -0400 Received: from vaebh105.NOE.Nokia.com (vaebh105.europe.nokia.com [10.160.244.31]) by mgw-mx03.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id n77AYXcV018034; Fri, 7 Aug 2009 13:34:48 +0300 Received: from vaebh104.NOE.Nokia.com ([10.160.244.30]) by vaebh105.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Fri, 7 Aug 2009 13:34:54 +0300 Received: from mgw-da02.ext.nokia.com ([147.243.128.26]) by vaebh104.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Fri, 7 Aug 2009 13:34:53 +0300 Received: from [127.0.1.1] (essapo-nirac25361.europe.nokia.com [10.162.253.61]) by mgw-da02.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id n77AYj1Q009982; Fri, 7 Aug 2009 13:34:46 +0300 From: Kalle Valo Subject: [PATCH 17/23] wl1251: fix channel setting in wl1251_op_config() To: linville@tuxdriver.com Cc: linux-wireless@vger.kernel.org Date: Fri, 07 Aug 2009 13:34:49 +0300 Message-ID: <20090807103448.31717.69202.stgit@tikku> In-Reply-To: <20090807102732.31717.84006.stgit@tikku> References: <20090807102732.31717.84006.stgit@tikku> User-Agent: StGIT/0.14.2 MIME-Version: 1.0 X-OriginalArrivalTime: 07 Aug 2009 10:34:53.0464 (UTC) FILETIME=[B32E1180:01CA174A] X-Nokia-AV: Clean Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org From: Kalle Valo There is a bug in wl1251_op_config(). It was calling join with previous channel. Fix it by setting assigning wl->channel before calling join command. Signed-off-by: Kalle Valo Reviewed-by: Vidhya Govindan --- drivers/net/wireless/wl12xx/wl1251_main.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/net/wireless/wl12xx/wl1251_main.c b/drivers/net/wireless/wl12xx/wl1251_main.c index e575b78..568b640 100644 --- a/drivers/net/wireless/wl12xx/wl1251_main.c +++ b/drivers/net/wireless/wl12xx/wl1251_main.c @@ -593,12 +593,12 @@ static int wl1251_op_config(struct ieee80211_hw *hw, u32 changed) goto out; if (channel != wl->channel) { + wl->channel = channel; + ret = wl1251_join(wl, wl->bss_type, wl->channel, wl->beacon_int, wl->dtim_period); if (ret < 0) goto out_sleep; - - wl->channel = channel; } ret = wl1251_build_null_data(wl);