Home
last modified time | relevance | path

Searched refs:wdev (Results 1 – 25 of 45) sorted by relevance

12

/net/wireless/
Dwext-sme.c19 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 …]
Dibss.c22 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 if (!(wdev->wiphy->flags & WIPHY_FLAG_HAS_STATIC_WEP)) in __cfg80211_ibss_joined()
49 cfg80211_upload_connect_keys(wdev); in __cfg80211_ibss_joined()
[all …]
Dsme.c54 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 …]
Dwext-compat.c38 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_wext_siwmode() local
44 rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_wext_siwmode()
60 if (type == wdev->iftype) in cfg80211_wext_siwmode()
65 wiphy_lock(wdev->wiphy); in cfg80211_wext_siwmode()
67 wiphy_unlock(wdev->wiphy); in cfg80211_wext_siwmode()
76 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_wext_giwmode() local
78 if (!wdev) in cfg80211_wext_giwmode()
81 switch (wdev->iftype) { in cfg80211_wext_giwmode()
113 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_wext_giwrange() local
118 if (!wdev) in cfg80211_wext_giwrange()
[all …]
Dmlme.c27 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_rx_assoc_resp() local
28 struct wiphy *wiphy = wdev->wiphy; in cfg80211_rx_assoc_resp()
77 if (cfg80211_sme_rx_assoc_resp(wdev, cr.status)) { in cfg80211_rx_assoc_resp()
96 static void cfg80211_process_auth(struct wireless_dev *wdev, in cfg80211_process_auth() argument
99 struct cfg80211_registered_device *rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_process_auth()
101 nl80211_send_rx_auth(rdev, wdev->netdev, buf, len, GFP_KERNEL); in cfg80211_process_auth()
102 cfg80211_sme_rx_auth(wdev, buf, len); in cfg80211_process_auth()
105 static void cfg80211_process_deauth(struct wireless_dev *wdev, in cfg80211_process_deauth() argument
109 struct cfg80211_registered_device *rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_process_deauth()
113 bool from_ap = !ether_addr_equal(mgmt->sa, wdev->netdev->dev_addr); in cfg80211_process_deauth()
[all …]
Dcore.c158 struct wireless_dev *wdev; in cfg80211_switch_netns() local
164 list_for_each_entry(wdev, &rdev->wiphy.wdev_list, list) { in cfg80211_switch_netns()
165 if (!wdev->netdev) in cfg80211_switch_netns()
167 wdev->netdev->features &= ~NETIF_F_NETNS_LOCAL; in cfg80211_switch_netns()
168 err = dev_change_net_namespace(wdev->netdev, net, "wlan%d"); in cfg80211_switch_netns()
171 wdev->netdev->features |= NETIF_F_NETNS_LOCAL; in cfg80211_switch_netns()
178 list_for_each_entry_continue_reverse(wdev, in cfg80211_switch_netns()
181 if (!wdev->netdev) in cfg80211_switch_netns()
183 wdev->netdev->features &= ~NETIF_F_NETNS_LOCAL; in cfg80211_switch_netns()
184 err = dev_change_net_namespace(wdev->netdev, net, in cfg80211_switch_netns()
[all …]
Dcore.h218 void cfg80211_init_wdev(struct wireless_dev *wdev);
220 struct wireless_dev *wdev);
222 static inline void wdev_lock(struct wireless_dev *wdev) in wdev_lock() argument
223 __acquires(wdev) in wdev_lock()
225 mutex_lock(&wdev->mtx); in wdev_lock()
226 __acquire(wdev->mtx); in wdev_lock()
229 static inline void wdev_unlock(struct wireless_dev *wdev) in wdev_unlock() argument
230 __releases(wdev) in wdev_unlock()
232 __release(wdev->mtx); in wdev_unlock()
233 mutex_unlock(&wdev->mtx); in wdev_unlock()
[all …]
Dmesh.c107 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()
216 memcpy(wdev->u.mesh.id, setup->mesh_id, setup->mesh_id_len); in __cfg80211_join_mesh()
217 wdev->u.mesh.id_len = setup->mesh_id_len; in __cfg80211_join_mesh()
218 wdev->u.mesh.chandef = setup->chandef; in __cfg80211_join_mesh()
219 wdev->u.mesh.beacon_interval = setup->beacon_interval; in __cfg80211_join_mesh()
226 struct wireless_dev *wdev, in cfg80211_set_mesh_channel() argument
242 if (!netif_running(wdev->netdev)) in cfg80211_set_mesh_channel()
[all …]
Docb.c22 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()
73 memset(&wdev->u.ocb.chandef, 0, sizeof(wdev->u.ocb.chandef)); in __cfg80211_leave_ocb()
81 struct wireless_dev *wdev = dev->ieee80211_ptr; in cfg80211_leave_ocb() local
[all …]
Dpmsr.c266 struct wireless_dev *wdev = info->user_ptr[1]; in nl80211_pmsr_start() local
314 memcpy(req->mac_addr, wdev_address(wdev), ETH_ALEN); in nl80211_pmsr_start()
331 err = rdev_start_pmsr(rdev, wdev, req); in nl80211_pmsr_start()
335 list_add_tail(&req->list, &wdev->pmsr_list); in nl80211_pmsr_start()
344 void cfg80211_pmsr_complete(struct wireless_dev *wdev, in cfg80211_pmsr_complete() argument
348 struct cfg80211_registered_device *rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_pmsr_complete()
353 trace_cfg80211_pmsr_complete(wdev->wiphy, wdev, req->cookie); in cfg80211_pmsr_complete()
365 nla_put_u64_64bit(msg, NL80211_ATTR_WDEV, wdev_id(wdev), in cfg80211_pmsr_complete()
374 genlmsg_unicast(wiphy_net(wdev->wiphy), msg, req->nl_portid); in cfg80211_pmsr_complete()
379 spin_lock_bh(&wdev->pmsr_lock); in cfg80211_pmsr_complete()
[all …]
Dap.c18 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 …]
Drdev-ops.h58 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()
456 struct wireless_dev *wdev) in rdev_abort_scan() argument
458 trace_rdev_abort_scan(&rdev->wiphy, wdev); in rdev_abort_scan()
459 rdev->ops->abort_scan(&rdev->wiphy, wdev); in rdev_abort_scan()
577 struct wireless_dev *wdev, in rdev_set_tx_power() argument
581 trace_rdev_set_tx_power(&rdev->wiphy, wdev, type, mbm); in rdev_set_tx_power()
582 ret = rdev->ops->set_tx_power(&rdev->wiphy, wdev, type, mbm); in rdev_set_tx_power()
588 struct wireless_dev *wdev, int *dbm) in rdev_get_tx_power() argument
[all …]
Dnl80211.c88 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 …]
Dchan.c712 bool cfg80211_beaconing_iface_active(struct wireless_dev *wdev) in cfg80211_beaconing_iface_active() argument
716 ASSERT_WDEV_LOCK(wdev); in cfg80211_beaconing_iface_active()
718 switch (wdev->iftype) { in cfg80211_beaconing_iface_active()
721 for_each_valid_link(wdev, link) { in cfg80211_beaconing_iface_active()
722 if (wdev->links[link].ap.beacon_interval) in cfg80211_beaconing_iface_active()
727 if (wdev->u.ibss.ssid_len) in cfg80211_beaconing_iface_active()
731 if (wdev->u.mesh.id_len) in cfg80211_beaconing_iface_active()
752 bool cfg80211_wdev_on_sub_chan(struct wireless_dev *wdev, in cfg80211_wdev_on_sub_chan() argument
758 switch (wdev->iftype) { in cfg80211_wdev_on_sub_chan()
761 for_each_valid_link(wdev, link) { in cfg80211_wdev_on_sub_chan()
[all …]
Dutil.c924 void cfg80211_upload_connect_keys(struct wireless_dev *wdev) in cfg80211_upload_connect_keys() argument
926 struct cfg80211_registered_device *rdev = wiphy_to_rdev(wdev->wiphy); in cfg80211_upload_connect_keys()
927 struct net_device *dev = wdev->netdev; in cfg80211_upload_connect_keys()
930 if (!wdev->connect_keys) in cfg80211_upload_connect_keys()
934 if (!wdev->connect_keys->params[i].cipher) in cfg80211_upload_connect_keys()
937 &wdev->connect_keys->params[i])) { in cfg80211_upload_connect_keys()
941 if (wdev->connect_keys->def == i && in cfg80211_upload_connect_keys()
948 kfree_sensitive(wdev->connect_keys); in cfg80211_upload_connect_keys()
949 wdev->connect_keys = NULL; in cfg80211_upload_connect_keys()
952 void cfg80211_process_wdev_events(struct wireless_dev *wdev) in cfg80211_process_wdev_events() argument
[all …]
Dnl80211.h19 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);
Dethtool.c9 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 strlcpy(info->fw_version, wdev->wiphy->fw_version, in cfg80211_get_drvinfo()
26 strlcpy(info->bus_info, dev_name(wiphy_dev(wdev->wiphy)), in cfg80211_get_drvinfo()
Dtrace.h30 #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 …]
Dreg.c2373 static bool reg_wdev_chan_valid(struct wiphy *wiphy, struct wireless_dev *wdev) in reg_wdev_chan_valid() argument
2381 wdev_lock(wdev); in reg_wdev_chan_valid()
2382 iftype = wdev->iftype; in reg_wdev_chan_valid()
2385 if (!wdev->netdev || !netif_running(wdev->netdev)) in reg_wdev_chan_valid()
2388 for (link = 0; link < ARRAY_SIZE(wdev->links); link++) { in reg_wdev_chan_valid()
2391 if (!wdev->valid_links && link > 0) in reg_wdev_chan_valid()
2393 if (!(wdev->valid_links & BIT(link))) in reg_wdev_chan_valid()
2398 if (!wdev->links[link].ap.beacon_interval) in reg_wdev_chan_valid()
2400 chandef = wdev->links[link].ap.chandef; in reg_wdev_chan_valid()
2403 if (!wdev->u.mesh.beacon_interval) in reg_wdev_chan_valid()
[all …]
Dsysfs.c88 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/
Dcore.c95 return lowpan_802154_dev(dev)->wdev->ifindex; in lowpan_get_iflink()
135 struct net_device *wdev; in lowpan_newlink() local
145 wdev = dev_get_by_index(dev_net(ldev), nla_get_u32(tb[IFLA_LINK])); in lowpan_newlink()
146 if (!wdev) in lowpan_newlink()
148 if (wdev->type != ARPHRD_IEEE802154) { in lowpan_newlink()
149 dev_put(wdev); in lowpan_newlink()
153 if (wdev->ieee802154_ptr->lowpan_dev) { in lowpan_newlink()
154 dev_put(wdev); in lowpan_newlink()
158 lowpan_802154_dev(ldev)->wdev = wdev; in lowpan_newlink()
160 memcpy(ldev->dev_addr, wdev->dev_addr, IEEE802154_ADDR_LEN); in lowpan_newlink()
[all …]
Dtx.c37 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/
Doffchannel.c173 cfg80211_mgmt_tx_status(&roc->sdata->wdev, roc->mgmt_tx_cookie, in ieee80211_roc_notify_destroy()
180 cfg80211_remain_on_channel_expired(&roc->sdata->wdev, in ieee80211_roc_notify_destroy()
184 cfg80211_tx_mgmt_expired(&roc->sdata->wdev, in ieee80211_roc_notify_destroy()
251 cfg80211_ready_on_channel(&roc->sdata->wdev, roc->cookie, in ieee80211_handle_roc_started()
670 int ieee80211_remain_on_channel(struct wiphy *wiphy, struct wireless_dev *wdev, in ieee80211_remain_on_channel() argument
674 struct ieee80211_sub_if_data *sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_remain_on_channel()
756 struct wireless_dev *wdev, u64 cookie) in ieee80211_cancel_remain_on_channel() argument
758 struct ieee80211_sub_if_data *sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_cancel_remain_on_channel()
764 int ieee80211_mgmt_tx(struct wiphy *wiphy, struct wireless_dev *wdev, in ieee80211_mgmt_tx() argument
767 struct ieee80211_sub_if_data *sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_mgmt_tx()
[all …]
Dcfg.c122 struct wireless_dev *wdev; in ieee80211_add_iface() local
126 err = ieee80211_if_add(local, name, name_assign_type, &wdev, type, params); in ieee80211_add_iface()
130 sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_add_iface()
140 return wdev; in ieee80211_add_iface()
143 static int ieee80211_del_iface(struct wiphy *wiphy, struct wireless_dev *wdev) in ieee80211_del_iface() argument
145 ieee80211_if_remove(IEEE80211_WDEV_TO_SUB_IF(wdev)); in ieee80211_del_iface()
198 struct wireless_dev *wdev) in ieee80211_start_p2p_device() argument
200 struct ieee80211_sub_if_data *sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_start_p2p_device()
209 return ieee80211_do_open(wdev, true); in ieee80211_start_p2p_device()
213 struct wireless_dev *wdev) in ieee80211_stop_p2p_device() argument
[all …]
Diface.c362 err = ieee80211_do_open(&sdata->wdev, true); in ieee80211_open()
469 if (sdata->wdev.cac_started) { in ieee80211_do_stop()
844 if (sdata->wdev.use_4addr && in ieee80211_set_vif_encap_ops()
949 sdata->wdev.iftype = NL80211_IFTYPE_MONITOR; in ieee80211_add_virtual_monitor()
1033 int ieee80211_do_open(struct wireless_dev *wdev, bool coming_up) in ieee80211_do_open() argument
1035 struct ieee80211_sub_if_data *sdata = IEEE80211_WDEV_TO_SUB_IF(wdev); in ieee80211_do_open()
1036 struct net_device *dev = wdev->netdev; in ieee80211_do_open()
1555 sdata->wdev.iftype = type; in ieee80211_setup_sdata()
1720 err = ieee80211_do_open(&sdata->wdev, false); in ieee80211_runtime_change_iftype()
1902 struct wireless_dev *wdev; in ieee80211_if_add() local
[all …]

12