cfg80211: pass wiphy to cfg80211_ref_bss/put_bss
This prepares for using the spinlock instead of krefs which is needed in the next patch to track the refs of combined BSSes correctly. Acked-by: Bing Zhao <bzhao@marvell.com> [mwifiex] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
@@ -58,7 +58,7 @@ void cfg80211_send_rx_assoc(struct net_device *dev, struct cfg80211_bss *bss,
|
||||
*/
|
||||
if (status_code != WLAN_STATUS_SUCCESS && wdev->conn &&
|
||||
cfg80211_sme_failed_reassoc(wdev)) {
|
||||
cfg80211_put_bss(bss);
|
||||
cfg80211_put_bss(wiphy, bss);
|
||||
goto out;
|
||||
}
|
||||
|
||||
@@ -70,7 +70,7 @@ void cfg80211_send_rx_assoc(struct net_device *dev, struct cfg80211_bss *bss,
|
||||
* do not call connect_result() now because the
|
||||
* sme will schedule work that does it later.
|
||||
*/
|
||||
cfg80211_put_bss(bss);
|
||||
cfg80211_put_bss(wiphy, bss);
|
||||
goto out;
|
||||
}
|
||||
|
||||
@@ -108,7 +108,7 @@ void __cfg80211_send_deauth(struct net_device *dev,
|
||||
if (wdev->current_bss &&
|
||||
ether_addr_equal(wdev->current_bss->pub.bssid, bssid)) {
|
||||
cfg80211_unhold_bss(wdev->current_bss);
|
||||
cfg80211_put_bss(&wdev->current_bss->pub);
|
||||
cfg80211_put_bss(wiphy, &wdev->current_bss->pub);
|
||||
wdev->current_bss = NULL;
|
||||
was_current = true;
|
||||
}
|
||||
@@ -164,7 +164,7 @@ void __cfg80211_send_disassoc(struct net_device *dev,
|
||||
ether_addr_equal(wdev->current_bss->pub.bssid, bssid)) {
|
||||
cfg80211_sme_disassoc(dev, wdev->current_bss);
|
||||
cfg80211_unhold_bss(wdev->current_bss);
|
||||
cfg80211_put_bss(&wdev->current_bss->pub);
|
||||
cfg80211_put_bss(wiphy, &wdev->current_bss->pub);
|
||||
wdev->current_bss = NULL;
|
||||
} else
|
||||
WARN_ON(1);
|
||||
@@ -324,7 +324,7 @@ int __cfg80211_mlme_auth(struct cfg80211_registered_device *rdev,
|
||||
err = rdev_auth(rdev, dev, &req);
|
||||
|
||||
out:
|
||||
cfg80211_put_bss(req.bss);
|
||||
cfg80211_put_bss(&rdev->wiphy, req.bss);
|
||||
return err;
|
||||
}
|
||||
|
||||
@@ -432,7 +432,7 @@ out:
|
||||
if (err) {
|
||||
if (was_connected)
|
||||
wdev->sme_state = CFG80211_SME_CONNECTED;
|
||||
cfg80211_put_bss(req.bss);
|
||||
cfg80211_put_bss(&rdev->wiphy, req.bss);
|
||||
}
|
||||
|
||||
return err;
|
||||
@@ -572,7 +572,7 @@ void cfg80211_mlme_down(struct cfg80211_registered_device *rdev,
|
||||
|
||||
if (wdev->current_bss) {
|
||||
cfg80211_unhold_bss(wdev->current_bss);
|
||||
cfg80211_put_bss(&wdev->current_bss->pub);
|
||||
cfg80211_put_bss(&rdev->wiphy, &wdev->current_bss->pub);
|
||||
wdev->current_bss = NULL;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user