From patchwork Sat Sep 26 12:42:53 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Berg X-Patchwork-Id: 50230 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 n8QCh0LQ025570 for ; Sat, 26 Sep 2009 12:43:00 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752367AbZIZMmx (ORCPT ); Sat, 26 Sep 2009 08:42:53 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752353AbZIZMmx (ORCPT ); Sat, 26 Sep 2009 08:42:53 -0400 Received: from xc.sipsolutions.net ([83.246.72.84]:54046 "EHLO sipsolutions.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752246AbZIZMmw (ORCPT ); Sat, 26 Sep 2009 08:42:52 -0400 Received: by sipsolutions.net with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1MrWc3-00038t-BR; Sat, 26 Sep 2009 14:42:55 +0200 Subject: [PATCH] cfg80211: always get BSS From: Johannes Berg To: John Linville Cc: Hin-Tak Leung , linux-wireless Date: Sat, 26 Sep 2009 14:42:53 +0200 Message-Id: <1253968973.5122.14.camel@johannes.local> Mime-Version: 1.0 X-Mailer: Evolution 2.28.0 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Multiple problems were reported due to interaction between wpa_supplicant and the wext compat code in cfg80211, which appear to be due to it not getting any bss pointer here when wpa_supplicant sets all parameters -- do that now. We should still get the bss after doing an extra scan, but that appears to increase the time we need for connecting enough to sometimes cause timeouts. Signed-off-by: Johannes Berg Tested-by: Hin-Tak Leung , --- net/wireless/sme.c | 5 ++--- 1 file changed, 2 insertions(+), 3 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 --- wireless-testing.orig/net/wireless/sme.c 2009-09-26 14:35:34.000000000 +0200 +++ wireless-testing/net/wireless/sme.c 2009-09-26 14:35:37.000000000 +0200 @@ -762,9 +762,8 @@ int __cfg80211_connect(struct cfg80211_r wdev->conn->params.ssid = wdev->ssid; wdev->conn->params.ssid_len = connect->ssid_len; - /* don't care about result -- but fill bssid & channel */ - if (!wdev->conn->params.bssid || !wdev->conn->params.channel) - bss = cfg80211_get_conn_bss(wdev); + /* see if we have the bss already */ + bss = cfg80211_get_conn_bss(wdev); wdev->sme_state = CFG80211_SME_CONNECTING; wdev->connect_keys = connkeys;