|
@@ -1001,6 +1001,7 @@ static int ieee80211_change_station(struct wiphy *wiphy,
|
|
struct ieee80211_local *local = wiphy_priv(wiphy);
|
|
struct ieee80211_local *local = wiphy_priv(wiphy);
|
|
struct sta_info *sta;
|
|
struct sta_info *sta;
|
|
struct ieee80211_sub_if_data *vlansdata;
|
|
struct ieee80211_sub_if_data *vlansdata;
|
|
|
|
+ int err;
|
|
|
|
|
|
mutex_lock(&local->sta_mtx);
|
|
mutex_lock(&local->sta_mtx);
|
|
|
|
|
|
@@ -1040,7 +1041,11 @@ static int ieee80211_change_station(struct wiphy *wiphy,
|
|
ieee80211_send_layer2_update(sta);
|
|
ieee80211_send_layer2_update(sta);
|
|
}
|
|
}
|
|
|
|
|
|
- sta_apply_parameters(local, sta, params);
|
|
|
|
|
|
+ err = sta_apply_parameters(local, sta, params);
|
|
|
|
+ if (err) {
|
|
|
|
+ mutex_unlock(&local->sta_mtx);
|
|
|
|
+ return err;
|
|
|
|
+ }
|
|
|
|
|
|
if (test_sta_flag(sta, WLAN_STA_TDLS_PEER) && params->supported_rates)
|
|
if (test_sta_flag(sta, WLAN_STA_TDLS_PEER) && params->supported_rates)
|
|
rate_control_rate_init(sta);
|
|
rate_control_rate_init(sta);
|