/net/wireless/ |
D | wext-sme.c | 19 struct wireless_dev *wdev) in cfg80211_mgd_wext_connect() argument 26 ASSERT_WDEV_LOCK(wdev); in cfg80211_mgd_wext_connect() 28 if (!netif_running(wdev->netdev)) in cfg80211_mgd_wext_connect() 31 wdev->wext.connect.ie = wdev->wext.ie; in cfg80211_mgd_wext_connect() 32 wdev->wext.connect.ie_len = wdev->wext.ie_len; in cfg80211_mgd_wext_connect() 35 wdev->wext.connect.bg_scan_period = -1; in cfg80211_mgd_wext_connect() 37 if (wdev->wext.keys) { in cfg80211_mgd_wext_connect() 38 wdev->wext.keys->def = wdev->wext.default_key; in cfg80211_mgd_wext_connect() 39 if (wdev->wext.default_key != -1) in cfg80211_mgd_wext_connect() 40 wdev->wext.connect.privacy = true; in cfg80211_mgd_wext_connect() [all …]
|
D | ibss.c | 22 struct wireless_dev *wdev = dev->ieee80211_ptr; in __cfg80211_ibss_joined() local 28 if (WARN_ON(wdev->iftype != NL80211_IFTYPE_ADHOC)) in __cfg80211_ibss_joined() 31 if (!wdev->u.ibss.ssid_len) in __cfg80211_ibss_joined() 34 bss = cfg80211_get_bss(wdev->wiphy, channel, bssid, NULL, 0, in __cfg80211_ibss_joined() 40 if (wdev->u.ibss.current_bss) { in __cfg80211_ibss_joined() 41 cfg80211_unhold_bss(wdev->u.ibss.current_bss); in __cfg80211_ibss_joined() 42 cfg80211_put_bss(wdev->wiphy, &wdev->u.ibss.current_bss->pub); in __cfg80211_ibss_joined() 46 wdev->u.ibss.current_bss = bss_from_pub(bss); in __cfg80211_ibss_joined() 48 cfg80211_upload_connect_keys(wdev); in __cfg80211_ibss_joined() 50 nl80211_send_ibss_bssid(wiphy_to_rdev(wdev->wiphy), dev, bssid, in __cfg80211_ibss_joined() [all …]
|
D | sme.c | 54 static void cfg80211_sme_free(struct wireless_dev *wdev) in cfg80211_sme_free() argument 56 if (!wdev->conn) in cfg80211_sme_free() 59 kfree(wdev->conn->ie); in cfg80211_sme_free() 60 kfree(wdev->conn); in cfg80211_sme_free() 61 wdev->conn = NULL; in cfg80211_sme_free() 64 static int cfg80211_conn_scan(struct wireless_dev *wdev) in cfg80211_conn_scan() argument 66 struct cfg80211_registered_device *rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_conn_scan() 70 ASSERT_WDEV_LOCK(wdev); in cfg80211_conn_scan() 75 if (wdev->conn->params.channel) in cfg80211_conn_scan() 78 n_channels = ieee80211_get_num_supported_channels(wdev->wiphy); in cfg80211_conn_scan() [all …]
|
D | wext-compat.c | 39 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_wext_siwmode() local 45 rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_wext_siwmode() 61 if (type == wdev->iftype) in cfg80211_wext_siwmode() 66 wiphy_lock(wdev->wiphy); in cfg80211_wext_siwmode() 68 wiphy_unlock(wdev->wiphy); in cfg80211_wext_siwmode() 78 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_wext_giwmode() local 80 if (!wdev) in cfg80211_wext_giwmode() 83 switch (wdev->iftype) { in cfg80211_wext_giwmode() 116 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_wext_giwrange() local 121 if (!wdev) in cfg80211_wext_giwrange() [all …]
|
D | mlme.c | 27 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_rx_assoc_resp() local 28 struct wiphy *wiphy = wdev->wiphy; in cfg80211_rx_assoc_resp() 81 if (cfg80211_sme_rx_assoc_resp(wdev, cr.status)) { in cfg80211_rx_assoc_resp() 100 static void cfg80211_process_auth(struct wireless_dev *wdev, in cfg80211_process_auth() argument 103 struct cfg80211_registered_device *rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_process_auth() 105 nl80211_send_rx_auth(rdev, wdev->netdev, buf, len, GFP_KERNEL); in cfg80211_process_auth() 106 cfg80211_sme_rx_auth(wdev, buf, len); in cfg80211_process_auth() 109 static void cfg80211_process_deauth(struct wireless_dev *wdev, in cfg80211_process_deauth() argument 113 struct cfg80211_registered_device *rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_process_deauth() 117 bool from_ap = !ether_addr_equal(mgmt->sa, wdev->netdev->dev_addr); in cfg80211_process_deauth() [all …]
|
D | core.c | 159 struct wireless_dev *wdev; in cfg80211_switch_netns() local 165 list_for_each_entry(wdev, &rdev->wiphy.wdev_list, list) { in cfg80211_switch_netns() 166 if (!wdev->netdev) in cfg80211_switch_netns() 168 wdev->netdev->features &= ~NETIF_F_NETNS_LOCAL; in cfg80211_switch_netns() 169 err = dev_change_net_namespace(wdev->netdev, net, "wlan%d"); in cfg80211_switch_netns() 172 wdev->netdev->features |= NETIF_F_NETNS_LOCAL; in cfg80211_switch_netns() 179 list_for_each_entry_continue_reverse(wdev, in cfg80211_switch_netns() 182 if (!wdev->netdev) in cfg80211_switch_netns() 184 wdev->netdev->features &= ~NETIF_F_NETNS_LOCAL; in cfg80211_switch_netns() 185 err = dev_change_net_namespace(wdev->netdev, net, in cfg80211_switch_netns() [all …]
|
D | core.h | 224 void cfg80211_init_wdev(struct wireless_dev *wdev); 226 struct wireless_dev *wdev); 228 static inline void wdev_lock(struct wireless_dev *wdev) in wdev_lock() argument 229 __acquires(wdev) in wdev_lock() 231 lockdep_assert_held(&wdev->wiphy->mtx); in wdev_lock() 232 mutex_lock(&wdev->mtx); in wdev_lock() 233 __acquire(wdev->mtx); in wdev_lock() 236 static inline void wdev_unlock(struct wireless_dev *wdev) in wdev_unlock() argument 237 __releases(wdev) in wdev_unlock() 239 lockdep_assert_held(&wdev->wiphy->mtx); in wdev_unlock() [all …]
|
D | mesh.c | 107 struct wireless_dev *wdev = dev->ieee80211_ptr; in __cfg80211_join_mesh() local 112 ASSERT_WDEV_LOCK(wdev); in __cfg80211_join_mesh() 121 if (wdev->u.mesh.id_len) in __cfg80211_join_mesh() 132 setup->chandef = wdev->u.mesh.preset_chandef; in __cfg80211_join_mesh() 213 memcpy(wdev->u.mesh.id, setup->mesh_id, setup->mesh_id_len); in __cfg80211_join_mesh() 214 wdev->u.mesh.id_len = setup->mesh_id_len; in __cfg80211_join_mesh() 215 wdev->u.mesh.chandef = setup->chandef; in __cfg80211_join_mesh() 216 wdev->u.mesh.beacon_interval = setup->beacon_interval; in __cfg80211_join_mesh() 223 struct wireless_dev *wdev, in cfg80211_set_mesh_channel() argument 239 if (!netif_running(wdev->netdev)) in cfg80211_set_mesh_channel() [all …]
|
D | ocb.c | 22 struct wireless_dev *wdev = dev->ieee80211_ptr; in __cfg80211_join_ocb() local 25 ASSERT_WDEV_LOCK(wdev); in __cfg80211_join_ocb() 38 wdev->u.ocb.chandef = setup->chandef; in __cfg80211_join_ocb() 47 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_join_ocb() local 50 wdev_lock(wdev); in cfg80211_join_ocb() 52 wdev_unlock(wdev); in cfg80211_join_ocb() 60 struct wireless_dev *wdev = dev->ieee80211_ptr; in __cfg80211_leave_ocb() local 63 ASSERT_WDEV_LOCK(wdev); in __cfg80211_leave_ocb() 71 if (!wdev->u.ocb.chandef.chan) in __cfg80211_leave_ocb() 76 memset(&wdev->u.ocb.chandef, 0, sizeof(wdev->u.ocb.chandef)); in __cfg80211_leave_ocb() [all …]
|
D | pmsr.c | 264 struct wireless_dev *wdev = info->user_ptr[1]; in nl80211_pmsr_start() local 313 memcpy(req->mac_addr, wdev_address(wdev), ETH_ALEN); in nl80211_pmsr_start() 328 err = rdev_start_pmsr(rdev, wdev, req); in nl80211_pmsr_start() 332 list_add_tail(&req->list, &wdev->pmsr_list); in nl80211_pmsr_start() 341 void cfg80211_pmsr_complete(struct wireless_dev *wdev, in cfg80211_pmsr_complete() argument 345 struct cfg80211_registered_device *rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_pmsr_complete() 350 trace_cfg80211_pmsr_complete(wdev->wiphy, wdev, req->cookie); in cfg80211_pmsr_complete() 362 nla_put_u64_64bit(msg, NL80211_ATTR_WDEV, wdev_id(wdev), in cfg80211_pmsr_complete() 371 genlmsg_unicast(wiphy_net(wdev->wiphy), msg, req->nl_portid); in cfg80211_pmsr_complete() 376 spin_lock_bh(&wdev->pmsr_lock); in cfg80211_pmsr_complete() [all …]
|
D | ap.c | 18 struct wireless_dev *wdev = dev->ieee80211_ptr; in ___cfg80211_stop_ap() local 21 ASSERT_WDEV_LOCK(wdev); in ___cfg80211_stop_ap() 30 if (!wdev->links[link_id].ap.beacon_interval) in ___cfg80211_stop_ap() 35 wdev->conn_owner_nlportid = 0; in ___cfg80211_stop_ap() 36 wdev->links[link_id].ap.beacon_interval = 0; in ___cfg80211_stop_ap() 37 memset(&wdev->links[link_id].ap.chandef, 0, in ___cfg80211_stop_ap() 38 sizeof(wdev->links[link_id].ap.chandef)); in ___cfg80211_stop_ap() 39 wdev->u.ap.ssid_len = 0; in ___cfg80211_stop_ap() 42 nl80211_send_ap_stopped(wdev, link_id); in ___cfg80211_stop_ap() 80 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_stop_ap() local [all …]
|
D | chan.c | 520 struct wireless_dev *wdev, in cfg80211_dfs_permissive_check_wdev() argument 525 for_each_valid_link(wdev, link_id) { in cfg80211_dfs_permissive_check_wdev() 531 if (wdev->iftype != NL80211_IFTYPE_STATION || in cfg80211_dfs_permissive_check_wdev() 532 !wdev->links[link_id].client.current_bss) in cfg80211_dfs_permissive_check_wdev() 536 wdev->links[link_id].client.current_bss->pub.channel; in cfg80211_dfs_permissive_check_wdev() 545 ret = rdev_get_channel(rdev, wdev, link_id, &chandef); in cfg80211_dfs_permissive_check_wdev() 563 struct wireless_dev *wdev; in cfg80211_dfs_permissive_chan() local 580 list_for_each_entry(wdev, &rdev->wiphy.wdev_list, list) { in cfg80211_dfs_permissive_chan() 582 wdev, chan); in cfg80211_dfs_permissive_chan() 788 bool cfg80211_beaconing_iface_active(struct wireless_dev *wdev) in cfg80211_beaconing_iface_active() argument [all …]
|
D | nl80211.c | 88 struct wireless_dev *wdev; in __cfg80211_wdev_from_attrs() local 92 list_for_each_entry(wdev, &rdev->wiphy.wdev_list, list) { in __cfg80211_wdev_from_attrs() 93 if (have_ifidx && wdev->netdev && in __cfg80211_wdev_from_attrs() 94 wdev->netdev->ifindex == ifidx) { in __cfg80211_wdev_from_attrs() 95 result = wdev; in __cfg80211_wdev_from_attrs() 98 if (have_wdev_id && wdev->identifier == (u32)wdev_id) { in __cfg80211_wdev_from_attrs() 99 result = wdev; in __cfg80211_wdev_from_attrs() 110 struct wireless_dev *wdev; in __cfg80211_wdev_from_attrs() local 118 list_for_each_entry(wdev, &rdev->wiphy.wdev_list, list) { in __cfg80211_wdev_from_attrs() 119 if (have_ifidx && wdev->netdev && in __cfg80211_wdev_from_attrs() [all …]
|
D | rdev-ops.h | 58 struct wireless_dev *wdev) in rdev_del_virtual_intf() argument 61 trace_rdev_del_virtual_intf(&rdev->wiphy, wdev); in rdev_del_virtual_intf() 62 ret = rdev->ops->del_virtual_intf(&rdev->wiphy, wdev); in rdev_del_virtual_intf() 472 struct wireless_dev *wdev) in rdev_abort_scan() argument 474 trace_rdev_abort_scan(&rdev->wiphy, wdev); in rdev_abort_scan() 475 rdev->ops->abort_scan(&rdev->wiphy, wdev); in rdev_abort_scan() 593 struct wireless_dev *wdev, in rdev_set_tx_power() argument 597 trace_rdev_set_tx_power(&rdev->wiphy, wdev, type, mbm); in rdev_set_tx_power() 598 ret = rdev->ops->set_tx_power(&rdev->wiphy, wdev, type, mbm); in rdev_set_tx_power() 604 struct wireless_dev *wdev, int *dbm) in rdev_get_tx_power() argument [all …]
|
D | util.c | 1007 void cfg80211_upload_connect_keys(struct wireless_dev *wdev) in cfg80211_upload_connect_keys() argument 1009 struct cfg80211_registered_device *rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_upload_connect_keys() 1010 struct net_device *dev = wdev->netdev; in cfg80211_upload_connect_keys() 1013 if (!wdev->connect_keys) in cfg80211_upload_connect_keys() 1017 if (!wdev->connect_keys->params[i].cipher) in cfg80211_upload_connect_keys() 1020 &wdev->connect_keys->params[i])) { in cfg80211_upload_connect_keys() 1024 if (wdev->connect_keys->def == i && in cfg80211_upload_connect_keys() 1031 kfree_sensitive(wdev->connect_keys); in cfg80211_upload_connect_keys() 1032 wdev->connect_keys = NULL; in cfg80211_upload_connect_keys() 1035 void cfg80211_process_wdev_events(struct wireless_dev *wdev) in cfg80211_process_wdev_events() argument [all …]
|
D | nl80211.h | 19 static inline u64 wdev_id(struct wireless_dev *wdev) in wdev_id() argument 21 return (u64)wdev->identifier | in wdev_id() 22 ((u64)wiphy_to_rdev(wdev->wiphy)->wiphy_idx << 32); in wdev_id() 34 struct wireless_dev *wdev, 37 struct wireless_dev *wdev); 39 struct wireless_dev *wdev, bool aborted); 108 struct wireless_dev *wdev, u32 nlpid, 117 void nl80211_send_ap_stopped(struct wireless_dev *wdev, unsigned int link_id);
|
D | ethtool.c | 9 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_get_drvinfo() local 10 struct device *pdev = wiphy_dev(wdev->wiphy); in cfg80211_get_drvinfo() 20 if (wdev->wiphy->fw_version[0]) in cfg80211_get_drvinfo() 21 strscpy(info->fw_version, wdev->wiphy->fw_version, in cfg80211_get_drvinfo() 26 strscpy(info->bus_info, dev_name(wiphy_dev(wdev->wiphy)), in cfg80211_get_drvinfo()
|
D | trace.h | 30 #define WDEV_ASSIGN (__entry->id) = (!IS_ERR_OR_NULL(wdev) \ 31 ? wdev->identifier : 0) 375 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 376 TP_ARGS(wiphy, wdev), 389 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev, u64 cookie), 390 TP_ARGS(wiphy, wdev, cookie), 407 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 408 TP_ARGS(wiphy, wdev) 412 TP_PROTO(struct wiphy *wiphy, struct wireless_dev *wdev), 413 TP_ARGS(wiphy, wdev) [all …]
|
D | reg.c | 2361 static bool reg_wdev_chan_valid(struct wiphy *wiphy, struct wireless_dev *wdev) in reg_wdev_chan_valid() argument 2369 wdev_lock(wdev); in reg_wdev_chan_valid() 2370 iftype = wdev->iftype; in reg_wdev_chan_valid() 2373 if (!wdev->netdev || !netif_running(wdev->netdev)) in reg_wdev_chan_valid() 2376 for (link = 0; link < ARRAY_SIZE(wdev->links); link++) { in reg_wdev_chan_valid() 2379 if (!wdev->valid_links && link > 0) in reg_wdev_chan_valid() 2381 if (wdev->valid_links && !(wdev->valid_links & BIT(link))) in reg_wdev_chan_valid() 2386 if (!wdev->links[link].ap.beacon_interval) in reg_wdev_chan_valid() 2388 chandef = wdev->links[link].ap.chandef; in reg_wdev_chan_valid() 2391 if (!wdev->u.mesh.beacon_interval) in reg_wdev_chan_valid() [all …]
|
D | sysfs.c | 88 struct wireless_dev *wdev; in cfg80211_leave_all() local 90 list_for_each_entry(wdev, &rdev->wiphy.wdev_list, list) in cfg80211_leave_all() 91 cfg80211_leave(rdev, wdev); in cfg80211_leave_all()
|
/net/ieee802154/6lowpan/ |
D | core.c | 96 return lowpan_802154_dev(dev)->wdev->ifindex; in lowpan_get_iflink() 136 struct net_device *wdev; in lowpan_newlink() local 146 wdev = dev_get_by_index(dev_net(ldev), nla_get_u32(tb[IFLA_LINK])); in lowpan_newlink() 147 if (!wdev) in lowpan_newlink() 149 if (wdev->type != ARPHRD_IEEE802154) { in lowpan_newlink() 150 dev_put(wdev); in lowpan_newlink() 154 if (wdev->ieee802154_ptr->lowpan_dev) { in lowpan_newlink() 155 dev_put(wdev); in lowpan_newlink() 159 lowpan_802154_dev(ldev)->wdev = wdev; in lowpan_newlink() 161 __dev_addr_set(ldev, wdev->dev_addr, IEEE802154_ADDR_LEN); in lowpan_newlink() [all …]
|
D | tx.c | 37 struct wpan_dev *wpan_dev = lowpan_802154_dev(ldev)->wdev->ieee802154_ptr; in lowpan_header_create() 104 struct net_device *wdev = lowpan_802154_dev(skb->dev)->wdev; in lowpan_alloc_frag() local 108 frag = alloc_skb(wdev->needed_headroom + wdev->needed_tailroom + size, in lowpan_alloc_frag() 112 frag->dev = wdev; in lowpan_alloc_frag() 114 skb_reserve(frag, wdev->needed_headroom); in lowpan_alloc_frag() 121 rc = wpan_dev_hard_header(frag, wdev, in lowpan_alloc_frag() 227 struct wpan_dev *wpan_dev = lowpan_802154_dev(ldev)->wdev->ieee802154_ptr; in lowpan_header() 246 return wpan_dev_hard_header(skb, lowpan_802154_dev(ldev)->wdev, in lowpan_header() 296 skb->dev = lowpan_802154_dev(ldev)->wdev; in lowpan_xmit()
|
/net/mac80211/ |
D | iface.c | 388 sdata->wdev.use_4addr && in ieee80211_check_concurrent_iface() 459 err = ieee80211_do_open(&sdata->wdev, true); in ieee80211_open() 566 if (sdata->wdev.cac_started) { in ieee80211_do_stop() 749 dev_close(non_tx_sdata->wdev.netdev); in ieee80211_stop_mbssid() 755 dev_close(tx_sdata->wdev.netdev); in ieee80211_stop_mbssid() 916 if (sdata->wdev.use_4addr) in ieee80211_netdev_fill_forward_path() 928 if (sdata->wdev.wiphy->flags & WIPHY_FLAG_SUPPORTS_TDLS) { in ieee80211_netdev_fill_forward_path() 1036 if (sdata->wdev.use_4addr && in ieee80211_set_vif_encap_ops() 1156 sdata->wdev.iftype = NL80211_IFTYPE_MONITOR; in ieee80211_add_virtual_monitor() 1157 mutex_init(&sdata->wdev.mtx); in ieee80211_add_virtual_monitor() [all …]
|
D | offchannel.c | 175 cfg80211_mgmt_tx_status(&roc->sdata->wdev, roc->mgmt_tx_cookie, in ieee80211_roc_notify_destroy() 182 cfg80211_remain_on_channel_expired(&roc->sdata->wdev, in ieee80211_roc_notify_destroy() 186 cfg80211_tx_mgmt_expired(&roc->sdata->wdev, in ieee80211_roc_notify_destroy() 253 cfg80211_ready_on_channel(&roc->sdata->wdev, roc->cookie, in ieee80211_handle_roc_started() 672 int ieee80211_remain_on_channel(struct wiphy *wiphy, struct wireless_dev *wdev, in ieee80211_remain_on_channel() argument 676 struct ieee80211_sub_if_data *sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_remain_on_channel() 758 struct wireless_dev *wdev, u64 cookie) in ieee80211_cancel_remain_on_channel() argument 760 struct ieee80211_sub_if_data *sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_cancel_remain_on_channel() 766 int ieee80211_mgmt_tx(struct wiphy *wiphy, struct wireless_dev *wdev, in ieee80211_mgmt_tx() argument 769 struct ieee80211_sub_if_data *sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_mgmt_tx() [all …]
|
D | cfg.c | 179 struct wireless_dev *wdev; in ieee80211_add_iface() local 183 err = ieee80211_if_add(local, name, name_assign_type, &wdev, type, params); in ieee80211_add_iface() 187 sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_add_iface() 197 return wdev; in ieee80211_add_iface() 200 static int ieee80211_del_iface(struct wiphy *wiphy, struct wireless_dev *wdev) in ieee80211_del_iface() argument 202 ieee80211_if_remove(IEEE80211_WDEV_TO_SUB_IF(wdev)); in ieee80211_del_iface() 259 struct wireless_dev *wdev) in ieee80211_start_p2p_device() argument 261 struct ieee80211_sub_if_data *sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_start_p2p_device() 270 return ieee80211_do_open(wdev, true); in ieee80211_start_p2p_device() 274 struct wireless_dev *wdev) in ieee80211_stop_p2p_device() argument [all …]
|