aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/mlme.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/mac80211/mlme.c')
-rw-r--r--net/mac80211/mlme.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
index 0f45d02e0ba7..fa927c6aa14b 100644
--- a/net/mac80211/mlme.c
+++ b/net/mac80211/mlme.c
@@ -3012,7 +3012,7 @@ static int ieee80211_prep_connection(struct ieee80211_sub_if_data *sdata,
3012 struct ieee80211_local *local = sdata->local; 3012 struct ieee80211_local *local = sdata->local;
3013 struct ieee80211_if_managed *ifmgd = &sdata->u.mgd; 3013 struct ieee80211_if_managed *ifmgd = &sdata->u.mgd;
3014 struct ieee80211_bss *bss = (void *)cbss->priv; 3014 struct ieee80211_bss *bss = (void *)cbss->priv;
3015 struct sta_info *sta; 3015 struct sta_info *sta = NULL;
3016 bool have_sta = false; 3016 bool have_sta = false;
3017 int err; 3017 int err;
3018 int ht_cfreq; 3018 int ht_cfreq;
@@ -3102,7 +3102,7 @@ static int ieee80211_prep_connection(struct ieee80211_sub_if_data *sdata,
3102 local->oper_channel = cbss->channel; 3102 local->oper_channel = cbss->channel;
3103 ieee80211_hw_config(local, 0); 3103 ieee80211_hw_config(local, 0);
3104 3104
3105 if (!have_sta) { 3105 if (sta) {
3106 u32 rates = 0, basic_rates = 0; 3106 u32 rates = 0, basic_rates = 0;
3107 bool have_higher_than_11mbit; 3107 bool have_higher_than_11mbit;
3108 int min_rate = INT_MAX, min_rate_index = -1; 3108 int min_rate = INT_MAX, min_rate_index = -1;