Lines Matching refs:pub
123 ies = (void *)rcu_access_pointer(bss->pub.beacon_ies); in bss_free()
124 if (ies && !bss->pub.hidden_beacon_bss) in bss_free()
126 ies = (void *)rcu_access_pointer(bss->pub.proberesp_ies); in bss_free()
147 if (bss->pub.hidden_beacon_bss) in bss_ref_get()
148 bss_from_pub(bss->pub.hidden_beacon_bss)->refcount++; in bss_ref_get()
150 if (bss->pub.transmitted_bss) in bss_ref_get()
151 bss_from_pub(bss->pub.transmitted_bss)->refcount++; in bss_ref_get()
159 if (bss->pub.hidden_beacon_bss) { in bss_ref_put()
161 hbss = container_of(bss->pub.hidden_beacon_bss, in bss_ref_put()
163 pub); in bss_ref_put()
169 if (bss->pub.transmitted_bss) { in bss_ref_put()
172 tbss = container_of(bss->pub.transmitted_bss, in bss_ref_put()
174 pub); in bss_ref_put()
195 if (!bss->pub.hidden_beacon_bss) in __cfg80211_unlink_bss()
205 list_del_init(&bss->pub.nontrans_list); in __cfg80211_unlink_bss()
475 !bss->pub.hidden_beacon_bss) in cfg80211_bss_expire_oldest()
760 struct cfg80211_bss *res = &intbss->pub; in cfg80211_scan_6ghz()
1448 if (!cfg80211_bss_type_match(bss->pub.capability, in cfg80211_get_bss()
1449 bss->pub.channel->band, bss_type)) in cfg80211_get_bss()
1452 bss_privacy = (bss->pub.capability & WLAN_CAPABILITY_PRIVACY); in cfg80211_get_bss()
1456 if (channel && bss->pub.channel != channel) in cfg80211_get_bss()
1458 if (!is_valid_ether_addr(bss->pub.bssid)) in cfg80211_get_bss()
1464 if (is_bss(&bss->pub, bssid, ssid, ssid_len)) { in cfg80211_get_bss()
1474 trace_cfg80211_return_bss(&res->pub); in cfg80211_get_bss()
1475 return &res->pub; in cfg80211_get_bss()
1491 cmp = cmp_bss(&bss->pub, &tbss->pub, BSS_CMP_REGULAR); in rb_insert_bss()
1519 r = cmp_bss(&res->pub, &bss->pub, mode); in rb_find_bss()
1542 ies = rcu_access_pointer(new->pub.beacon_ies); in cfg80211_combine_bsses()
1570 if (!ether_addr_equal(bss->pub.bssid, new->pub.bssid)) in cfg80211_combine_bsses()
1572 if (bss->pub.channel != new->pub.channel) in cfg80211_combine_bsses()
1574 if (bss->pub.scan_width != new->pub.scan_width) in cfg80211_combine_bsses()
1576 if (rcu_access_pointer(bss->pub.beacon_ies)) in cfg80211_combine_bsses()
1578 ies = rcu_access_pointer(bss->pub.ies); in cfg80211_combine_bsses()
1586 if (WARN_ON_ONCE(bss->pub.hidden_beacon_bss)) in cfg80211_combine_bsses()
1592 bss->pub.hidden_beacon_bss = &new->pub; in cfg80211_combine_bsses()
1594 rcu_assign_pointer(bss->pub.beacon_ies, in cfg80211_combine_bsses()
1595 new->pub.beacon_ies); in cfg80211_combine_bsses()
1621 ies = rcu_access_pointer(bss->pub.beacon_ies); in cfg80211_update_hidden_bsses()
1624 rcu_assign_pointer(bss->pub.beacon_ies, new_ies); in cfg80211_update_hidden_bsses()
1637 if (rcu_access_pointer(new->pub.proberesp_ies)) { in cfg80211_update_known_bss()
1640 old = rcu_access_pointer(known->pub.proberesp_ies); in cfg80211_update_known_bss()
1642 rcu_assign_pointer(known->pub.proberesp_ies, in cfg80211_update_known_bss()
1643 new->pub.proberesp_ies); in cfg80211_update_known_bss()
1645 rcu_assign_pointer(known->pub.ies, in cfg80211_update_known_bss()
1646 new->pub.proberesp_ies); in cfg80211_update_known_bss()
1649 } else if (rcu_access_pointer(new->pub.beacon_ies)) { in cfg80211_update_known_bss()
1652 if (known->pub.hidden_beacon_bss && in cfg80211_update_known_bss()
1665 f = rcu_access_pointer(new->pub.beacon_ies); in cfg80211_update_known_bss()
1670 old = rcu_access_pointer(known->pub.beacon_ies); in cfg80211_update_known_bss()
1672 rcu_assign_pointer(known->pub.beacon_ies, new->pub.beacon_ies); in cfg80211_update_known_bss()
1675 if (old == rcu_access_pointer(known->pub.ies)) in cfg80211_update_known_bss()
1676 rcu_assign_pointer(known->pub.ies, new->pub.beacon_ies); in cfg80211_update_known_bss()
1679 rcu_access_pointer(new->pub.beacon_ies), in cfg80211_update_known_bss()
1686 known->pub.beacon_interval = new->pub.beacon_interval; in cfg80211_update_known_bss()
1692 known->pub.signal = new->pub.signal; in cfg80211_update_known_bss()
1693 known->pub.capability = new->pub.capability; in cfg80211_update_known_bss()
1697 known->pub.chains = new->pub.chains; in cfg80211_update_known_bss()
1698 memcpy(known->pub.chain_signal, new->pub.chain_signal, in cfg80211_update_known_bss()
1701 known->pub.max_bssid_indicator = new->pub.max_bssid_indicator; in cfg80211_update_known_bss()
1702 known->pub.bssid_index = new->pub.bssid_index; in cfg80211_update_known_bss()
1715 if (WARN_ON(!tmp->pub.channel)) in cfg80211_bss_update()
1722 if (WARN_ON(!rcu_access_pointer(tmp->pub.ies))) { in cfg80211_bss_update()
1745 ies = (void *)rcu_dereference(tmp->pub.beacon_ies); in cfg80211_bss_update()
1748 ies = (void *)rcu_dereference(tmp->pub.proberesp_ies); in cfg80211_bss_update()
1756 INIT_LIST_HEAD(&new->pub.nontrans_list); in cfg80211_bss_update()
1758 new->pub.transmitted_bss = NULL; in cfg80211_bss_update()
1760 if (rcu_access_pointer(tmp->pub.proberesp_ies)) { in cfg80211_bss_update()
1766 new->pub.hidden_beacon_bss = &hidden->pub; in cfg80211_bss_update()
1770 rcu_assign_pointer(new->pub.beacon_ies, in cfg80211_bss_update()
1771 hidden->pub.beacon_ies); in cfg80211_bss_update()
1793 if (tmp->pub.transmitted_bss) { in cfg80211_bss_update()
1795 container_of(tmp->pub.transmitted_bss, in cfg80211_bss_update()
1797 pub); in cfg80211_bss_update()
1799 new->pub.transmitted_bss = tmp->pub.transmitted_bss; in cfg80211_bss_update()
1971 memcpy(tmp.pub.bssid, bssid, ETH_ALEN); in cfg80211_inform_single_bss_data()
1972 tmp.pub.channel = channel; in cfg80211_inform_single_bss_data()
1973 tmp.pub.scan_width = data->scan_width; in cfg80211_inform_single_bss_data()
1974 tmp.pub.signal = data->signal; in cfg80211_inform_single_bss_data()
1975 tmp.pub.beacon_interval = beacon_interval; in cfg80211_inform_single_bss_data()
1976 tmp.pub.capability = capability; in cfg80211_inform_single_bss_data()
1982 tmp.pub.transmitted_bss = non_tx_data->tx_bss; in cfg80211_inform_single_bss_data()
1984 tmp.pub.bssid_index = non_tx_data->bssid_index; in cfg80211_inform_single_bss_data()
1985 tmp.pub.max_bssid_indicator = non_tx_data->max_bssid_indicator; in cfg80211_inform_single_bss_data()
2011 rcu_assign_pointer(tmp.pub.beacon_ies, ies); in cfg80211_inform_single_bss_data()
2014 rcu_assign_pointer(tmp.pub.proberesp_ies, ies); in cfg80211_inform_single_bss_data()
2017 rcu_assign_pointer(tmp.pub.ies, ies); in cfg80211_inform_single_bss_data()
2025 bss_type = res->pub.capability & WLAN_CAPABILITY_DMG_TYPE_MASK; in cfg80211_inform_single_bss_data()
2030 if (res->pub.capability & WLAN_CAPABILITY_ESS) in cfg80211_inform_single_bss_data()
2040 &res->pub)) { in cfg80211_inform_single_bss_data()
2052 trace_cfg80211_return_bss(&res->pub); in cfg80211_inform_single_bss_data()
2054 return &res->pub; in cfg80211_inform_single_bss_data()
2481 rcu_assign_pointer(tmp.pub.proberesp_ies, ies); in cfg80211_inform_single_bss_frame_data()
2483 rcu_assign_pointer(tmp.pub.beacon_ies, ies); in cfg80211_inform_single_bss_frame_data()
2484 rcu_assign_pointer(tmp.pub.ies, ies); in cfg80211_inform_single_bss_frame_data()
2486 memcpy(tmp.pub.bssid, bssid, ETH_ALEN); in cfg80211_inform_single_bss_frame_data()
2487 tmp.pub.beacon_interval = beacon_int; in cfg80211_inform_single_bss_frame_data()
2488 tmp.pub.capability = capability; in cfg80211_inform_single_bss_frame_data()
2489 tmp.pub.channel = channel; in cfg80211_inform_single_bss_frame_data()
2490 tmp.pub.scan_width = data->scan_width; in cfg80211_inform_single_bss_frame_data()
2491 tmp.pub.signal = data->signal; in cfg80211_inform_single_bss_frame_data()
2494 tmp.pub.chains = data->chains; in cfg80211_inform_single_bss_frame_data()
2495 memcpy(tmp.pub.chain_signal, data->chain_signal, IEEE80211_MAX_CHAINS); in cfg80211_inform_single_bss_frame_data()
2505 bss_type = res->pub.capability & WLAN_CAPABILITY_DMG_TYPE_MASK; in cfg80211_inform_single_bss_frame_data()
2510 if (res->pub.capability & WLAN_CAPABILITY_ESS) in cfg80211_inform_single_bss_frame_data()
2514 trace_cfg80211_return_bss(&res->pub); in cfg80211_inform_single_bss_frame_data()
2516 return &res->pub; in cfg80211_inform_single_bss_frame_data()
2575 void cfg80211_ref_bss(struct wiphy *wiphy, struct cfg80211_bss *pub) in cfg80211_ref_bss() argument
2580 if (!pub) in cfg80211_ref_bss()
2583 bss = container_of(pub, struct cfg80211_internal_bss, pub); in cfg80211_ref_bss()
2591 void cfg80211_put_bss(struct wiphy *wiphy, struct cfg80211_bss *pub) in cfg80211_put_bss() argument
2596 if (!pub) in cfg80211_put_bss()
2599 bss = container_of(pub, struct cfg80211_internal_bss, pub); in cfg80211_put_bss()
2607 void cfg80211_unlink_bss(struct wiphy *wiphy, struct cfg80211_bss *pub) in cfg80211_unlink_bss() argument
2613 if (WARN_ON(!pub)) in cfg80211_unlink_bss()
2616 bss = container_of(pub, struct cfg80211_internal_bss, pub); in cfg80211_unlink_bss()
2623 &pub->nontrans_list, in cfg80211_unlink_bss()
2626 struct cfg80211_internal_bss, pub); in cfg80211_unlink_bss()
2651 if (!chandef || cfg80211_is_sub_chan(chandef, bss->pub.channel, in cfg80211_bss_iter()
2653 iter(wiphy, &bss->pub, iter_data); in cfg80211_bss_iter()
2678 if (cbss->pub.channel == chan) in cfg80211_update_assoc_bss_entry()
2682 if (cbss->pub.transmitted_bss) in cfg80211_update_assoc_bss_entry()
2683 cbss = container_of(cbss->pub.transmitted_bss, in cfg80211_update_assoc_bss_entry()
2685 pub); in cfg80211_update_assoc_bss_entry()
2687 cbss->pub.channel = chan; in cfg80211_update_assoc_bss_entry()
2690 if (!cfg80211_bss_type_match(bss->pub.capability, in cfg80211_update_assoc_bss_entry()
2691 bss->pub.channel->band, in cfg80211_update_assoc_bss_entry()
2698 if (!cmp_bss(&bss->pub, &cbss->pub, BSS_CMP_REGULAR)) { in cfg80211_update_assoc_bss_entry()
2707 new->pub.proberesp_ies = NULL; in cfg80211_update_assoc_bss_entry()
2708 new->pub.beacon_ies = NULL; in cfg80211_update_assoc_bss_entry()
2712 &new->pub.nontrans_list, in cfg80211_update_assoc_bss_entry()
2715 struct cfg80211_internal_bss, pub); in cfg80211_update_assoc_bss_entry()
2730 &cbss->pub.nontrans_list, in cfg80211_update_assoc_bss_entry()
2733 struct cfg80211_internal_bss, pub); in cfg80211_update_assoc_bss_entry()
2734 bss->pub.channel = chan; in cfg80211_update_assoc_bss_entry()
2962 memcpy(iwe.u.ap_addr.sa_data, bss->pub.bssid, ETH_ALEN); in ieee80211_bss()
2970 iwe.u.freq.m = ieee80211_frequency_to_channel(bss->pub.channel->center_freq); in ieee80211_bss()
2979 iwe.u.freq.m = bss->pub.channel->center_freq; in ieee80211_bss()
2994 sig = bss->pub.signal / 100; in ieee80211_bss()
3005 iwe.u.qual.level = bss->pub.signal; in ieee80211_bss()
3007 iwe.u.qual.qual = bss->pub.signal; in ieee80211_bss()
3022 if (bss->pub.capability & WLAN_CAPABILITY_PRIVACY) in ieee80211_bss()
3033 ies = rcu_dereference(bss->pub.ies); in ieee80211_bss()
3163 if (bss->pub.capability & (WLAN_CAPABILITY_ESS | WLAN_CAPABILITY_IBSS) || in ieee80211_bss()
3169 else if (bss->pub.capability & WLAN_CAPABILITY_ESS) in ieee80211_bss()