aboutsummaryrefslogtreecommitdiffstats
path: root/net/wireless/scan.c
diff options
context:
space:
mode:
authorBen Greear <greearb@candelatech.com>2013-06-19 17:06:27 -0400
committerJohannes Berg <johannes.berg@intel.com>2013-06-24 09:54:45 -0400
commit0e3a39b5620bc84f25ffb0592b05b0350e8b0520 (patch)
tree0b54e4bf90ff44b7e726393b50b6ba750ba4a936 /net/wireless/scan.c
parent6f390908e58113b9199424749c32a05181ff69d9 (diff)
wireless: add comments about bss refcounting
Should help the next person that tries to understand the bss refcounting logic. Signed-off-by: Ben Greear <greearb@candelatech.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless/scan.c')
-rw-r--r--net/wireless/scan.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/net/wireless/scan.c b/net/wireless/scan.c
index dd01b58fa78c..ae8c186b50d6 100644
--- a/net/wireless/scan.c
+++ b/net/wireless/scan.c
@@ -523,6 +523,7 @@ static int cmp_bss(struct cfg80211_bss *a,
523 } 523 }
524} 524}
525 525
526/* Returned bss is reference counted and must be cleaned up appropriately. */
526struct cfg80211_bss *cfg80211_get_bss(struct wiphy *wiphy, 527struct cfg80211_bss *cfg80211_get_bss(struct wiphy *wiphy,
527 struct ieee80211_channel *channel, 528 struct ieee80211_channel *channel,
528 const u8 *bssid, 529 const u8 *bssid,
@@ -678,6 +679,7 @@ static bool cfg80211_combine_bsses(struct cfg80211_registered_device *dev,
678 return true; 679 return true;
679} 680}
680 681
682/* Returned bss is reference counted and must be cleaned up appropriately. */
681static struct cfg80211_internal_bss * 683static struct cfg80211_internal_bss *
682cfg80211_bss_update(struct cfg80211_registered_device *dev, 684cfg80211_bss_update(struct cfg80211_registered_device *dev,
683 struct cfg80211_internal_bss *tmp) 685 struct cfg80211_internal_bss *tmp)
@@ -866,6 +868,7 @@ cfg80211_get_bss_channel(struct wiphy *wiphy, const u8 *ie, size_t ielen,
866 return channel; 868 return channel;
867} 869}
868 870
871/* Returned bss is reference counted and must be cleaned up appropriately. */
869struct cfg80211_bss* 872struct cfg80211_bss*
870cfg80211_inform_bss(struct wiphy *wiphy, 873cfg80211_inform_bss(struct wiphy *wiphy,
871 struct ieee80211_channel *channel, 874 struct ieee80211_channel *channel,
@@ -923,6 +926,7 @@ cfg80211_inform_bss(struct wiphy *wiphy,
923} 926}
924EXPORT_SYMBOL(cfg80211_inform_bss); 927EXPORT_SYMBOL(cfg80211_inform_bss);
925 928
929/* Returned bss is reference counted and must be cleaned up appropriately. */
926struct cfg80211_bss * 930struct cfg80211_bss *
927cfg80211_inform_bss_frame(struct wiphy *wiphy, 931cfg80211_inform_bss_frame(struct wiphy *wiphy,
928 struct ieee80211_channel *channel, 932 struct ieee80211_channel *channel,