mac80211: compute chanctx refcount on-the-fly
It doesn't make much sense to store refcount in the chanctx structure. One still needs to hold chanctx_mtx to get the value safely. Besides, refcount isn't on performance critical paths. This will make implementing chanctx reservation refcounting a little easier. Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:

committed by
Johannes Berg

parent
2b32713d72
commit
c0166da9fe
@@ -695,7 +695,6 @@ struct ieee80211_chanctx {
|
||||
struct list_head reserved_vifs;
|
||||
|
||||
enum ieee80211_chanctx_mode mode;
|
||||
int refcount;
|
||||
bool driver_present;
|
||||
|
||||
struct ieee80211_chanctx_conf conf;
|
||||
@@ -1803,6 +1802,8 @@ void ieee80211_vif_release_channel(struct ieee80211_sub_if_data *sdata);
|
||||
void ieee80211_vif_vlan_copy_chanctx(struct ieee80211_sub_if_data *sdata);
|
||||
void ieee80211_vif_copy_chanctx_to_vlans(struct ieee80211_sub_if_data *sdata,
|
||||
bool clear);
|
||||
int ieee80211_chanctx_refcount(struct ieee80211_local *local,
|
||||
struct ieee80211_chanctx *ctx);
|
||||
|
||||
void ieee80211_recalc_smps_chanctx(struct ieee80211_local *local,
|
||||
struct ieee80211_chanctx *chanctx);
|
||||
|
Reference in New Issue
Block a user