Lines Matching refs:nlmode
233 int is_ap_interface(enum nl80211_iftype nlmode) in is_ap_interface() argument
235 return nlmode == NL80211_IFTYPE_AP || in is_ap_interface()
236 nlmode == NL80211_IFTYPE_P2P_GO; in is_ap_interface()
240 int is_sta_interface(enum nl80211_iftype nlmode) in is_sta_interface() argument
242 return nlmode == NL80211_IFTYPE_STATION || in is_sta_interface()
243 nlmode == NL80211_IFTYPE_P2P_CLIENT; in is_sta_interface()
247 static int is_p2p_net_interface(enum nl80211_iftype nlmode) in is_p2p_net_interface() argument
249 return nlmode == NL80211_IFTYPE_P2P_CLIENT || in is_p2p_net_interface()
250 nlmode == NL80211_IFTYPE_P2P_GO; in is_p2p_net_interface()
268 static int is_mesh_interface(enum nl80211_iftype nlmode) in is_mesh_interface() argument
270 return nlmode == NL80211_IFTYPE_MESH_POINT; in is_mesh_interface()
523 enum nl80211_iftype nlmode; member
541 info->nlmode = nla_get_u32(tb[NL80211_ATTR_IFTYPE]); in netdev_info_handler()
572 .nlmode = NL80211_IFTYPE_UNSPECIFIED, in nl80211_get_ifmode()
580 return data.nlmode; in nl80211_get_ifmode()
1298 unsigned int freq = drv->nlmode == NL80211_IFTYPE_ADHOC ? in nl80211_get_assoc_freq()
1661 if (drv->nlmode == NL80211_IFTYPE_P2P_DEVICE) in wpa_driver_nl80211_rfkill_blocked()
1676 if (is_p2p_net_interface(drv->nlmode)) in wpa_driver_nl80211_rfkill_unblocked()
1683 if (drv->nlmode == NL80211_IFTYPE_P2P_DEVICE) in wpa_driver_nl80211_rfkill_unblocked()
1790 if (drv->nlmode == NL80211_IFTYPE_P2P_DEVICE) { in wpa_driver_nl80211_drv_init_rfkill()
2000 if (drv->nlmode == NL80211_IFTYPE_ADHOC) { in nl80211_mgmt_subscribe_non_ap()
2329 enum nl80211_iftype nlmode; in i802_set_iface_flags() local
2331 nlmode = nl80211_get_ifmode(bss); in i802_set_iface_flags()
2332 if (nlmode != NL80211_IFTYPE_P2P_DEVICE) { in i802_set_iface_flags()
2403 enum nl80211_iftype nlmode; in wpa_driver_nl80211_finish_drv_init() local
2441 nlmode = NL80211_IFTYPE_AP; in wpa_driver_nl80211_finish_drv_init()
2444 nlmode = nl80211_get_ifmode(bss); in wpa_driver_nl80211_finish_drv_init()
2446 nlmode = NL80211_IFTYPE_STATION; in wpa_driver_nl80211_finish_drv_init()
2448 if (wpa_driver_nl80211_set_mode(bss, nlmode) < 0) { in wpa_driver_nl80211_finish_drv_init()
2453 if (nlmode == NL80211_IFTYPE_P2P_DEVICE) in wpa_driver_nl80211_finish_drv_init()
2466 if (is_p2p_net_interface(nlmode)) in wpa_driver_nl80211_finish_drv_init()
2470 if (nlmode == NL80211_IFTYPE_P2P_DEVICE) in wpa_driver_nl80211_finish_drv_init()
2475 if (nlmode != NL80211_IFTYPE_P2P_DEVICE) in wpa_driver_nl80211_finish_drv_init()
2481 if (!drv->hostapd && nlmode != NL80211_IFTYPE_P2P_DEVICE) in wpa_driver_nl80211_finish_drv_init()
2485 if (nlmode != NL80211_IFTYPE_P2P_DEVICE) { in wpa_driver_nl80211_finish_drv_init()
2563 if (is_ap_interface(drv->nlmode)) in wpa_driver_nl80211_deinit()
2603 if (drv->nlmode != NL80211_IFTYPE_P2P_DEVICE) { in wpa_driver_nl80211_deinit()
2768 if (drv->nlmode == NL80211_IFTYPE_P2P_DEVICE) in wpa_driver_nl80211_set_key()
2855 if (is_ap_interface(drv->nlmode) && addr && in wpa_driver_nl80211_set_key()
3043 if (drv->nlmode == NL80211_IFTYPE_ADHOC) { in wpa_driver_nl80211_deauthenticate()
3113 if (is_p2p_net_interface(drv->nlmode) || !drv->disabled_11b_rates) in nl80211_unmask_11b_rates()
3135 enum nl80211_iftype nlmode; in wpa_driver_nl80211_authenticate() local
3152 nlmode = params->p2p ? in wpa_driver_nl80211_authenticate()
3154 if (drv->nlmode != nlmode && in wpa_driver_nl80211_authenticate()
3155 wpa_driver_nl80211_set_mode(bss, nlmode) < 0) in wpa_driver_nl80211_authenticate()
3359 if (freq == 0 && drv->nlmode == NL80211_IFTYPE_ADHOC) { in wpa_driver_nl80211_send_frame()
3420 fc, fc2str(fc), drv->nlmode); in wpa_driver_nl80211_send_mlme()
3422 if ((is_sta_interface(drv->nlmode) || in wpa_driver_nl80211_send_mlme()
3423 drv->nlmode == NL80211_IFTYPE_P2P_DEVICE) && in wpa_driver_nl80211_send_mlme()
3441 if (drv->device_ap_sme && is_ap_interface(drv->nlmode)) { in wpa_driver_nl80211_send_mlme()
4017 if (is_mesh_interface(drv->nlmode) && params->ht_opmode != -1) { in wpa_driver_nl80211_set_ap()
4260 if (is_ap_interface(drv->nlmode) && in wpa_driver_nl80211_sta_add()
4348 if (!is_mesh_interface(drv->nlmode)) { in wpa_driver_nl80211_sta_add()
4878 enum nl80211_iftype nlmode, old_mode; in wpa_driver_nl80211_ap() local
4883 nlmode = NL80211_IFTYPE_P2P_GO; in wpa_driver_nl80211_ap()
4885 nlmode = NL80211_IFTYPE_AP; in wpa_driver_nl80211_ap()
4887 old_mode = drv->nlmode; in wpa_driver_nl80211_ap()
4888 if (wpa_driver_nl80211_set_mode(drv->first_bss, nlmode)) { in wpa_driver_nl80211_ap()
4895 if (old_mode != nlmode) in wpa_driver_nl80211_ap()
5395 enum nl80211_iftype nlmode = params->p2p ? in wpa_driver_nl80211_associate()
5398 if (wpa_driver_nl80211_set_mode(priv, nlmode) < 0) in wpa_driver_nl80211_associate()
5476 enum nl80211_iftype nlmode, in wpa_driver_nl80211_set_mode_impl() argument
5482 int was_ap = is_ap_interface(drv->nlmode); in wpa_driver_nl80211_set_mode_impl()
5489 mode_switch_res = nl80211_set_mode(drv, drv->ifindex, nlmode); in wpa_driver_nl80211_set_mode_impl()
5490 if (mode_switch_res && nlmode == nl80211_get_ifmode(bss)) in wpa_driver_nl80211_set_mode_impl()
5494 drv->nlmode = nlmode; in wpa_driver_nl80211_set_mode_impl()
5502 if (nlmode == drv->nlmode) { in wpa_driver_nl80211_set_mode_impl()
5539 mode_switch_res = nl80211_set_mode(drv, drv->ifindex, nlmode); in wpa_driver_nl80211_set_mode_impl()
5553 drv->nlmode = nlmode; in wpa_driver_nl80211_set_mode_impl()
5568 "from %d failed", nlmode, drv->nlmode); in wpa_driver_nl80211_set_mode_impl()
5572 if (is_p2p_net_interface(nlmode)) { in wpa_driver_nl80211_set_mode_impl()
5584 if (is_ap_interface(nlmode)) { in wpa_driver_nl80211_set_mode_impl()
5596 if (is_mesh_interface(nlmode) && in wpa_driver_nl80211_set_mode_impl()
5600 if (!bss->in_deinit && !is_ap_interface(nlmode) && in wpa_driver_nl80211_set_mode_impl()
5601 !is_mesh_interface(nlmode) && in wpa_driver_nl80211_set_mode_impl()
5611 enum nl80211_iftype nlmode) in wpa_driver_nl80211_set_mode() argument
5613 return wpa_driver_nl80211_set_mode_impl(bss, nlmode, NULL); in wpa_driver_nl80211_set_mode()
6048 if (is_mesh_interface(drv->nlmode)) in i802_sta_deauth()
6075 if (is_mesh_interface(drv->nlmode)) in i802_sta_disassoc()
6555 enum nl80211_iftype nlmode; in wpa_driver_nl80211_if_add() local
6563 nlmode = wpa_driver_nl80211_if_type(type); in wpa_driver_nl80211_if_add()
6564 if (nlmode == NL80211_IFTYPE_P2P_DEVICE) { in wpa_driver_nl80211_if_add()
6568 ifidx = nl80211_create_iface(drv, ifname, nlmode, addr, in wpa_driver_nl80211_if_add()
6585 ifidx = nl80211_create_iface(drv, ifname, nlmode, addr, in wpa_driver_nl80211_if_add()
6596 if (nlmode == NL80211_IFTYPE_P2P_DEVICE) in wpa_driver_nl80211_if_add()
6690 nlmode == NL80211_IFTYPE_AP_VLAN || in wpa_driver_nl80211_if_add()
6691 nlmode == NL80211_IFTYPE_WDS || in wpa_driver_nl80211_if_add()
6692 nlmode == NL80211_IFTYPE_MONITOR)) in wpa_driver_nl80211_if_add()
6892 if (is_ap_interface(drv->nlmode) && in wpa_driver_nl80211_send_action()
7027 is_ap_interface(drv->nlmode) && !bss->in_deinit && in wpa_driver_nl80211_probe_req_report()
7128 if (!is_ap_interface(drv->nlmode)) in wpa_driver_nl80211_deinit_ap()
7137 if (drv->nlmode == NL80211_IFTYPE_P2P_GO && bss->if_dynamic) in wpa_driver_nl80211_deinit_ap()
7148 if (!is_ap_interface(drv->nlmode)) in wpa_driver_nl80211_stop_ap()
7160 if (drv->nlmode != NL80211_IFTYPE_P2P_CLIENT) in wpa_driver_nl80211_deinit_p2p_cli()
7177 enum nl80211_iftype nlmode = nl80211_get_ifmode(bss); in wpa_driver_nl80211_resume() local
7182 if (is_p2p_net_interface(nlmode)) in wpa_driver_nl80211_resume()
7257 if (drv->nlmode != NL80211_IFTYPE_ADHOC && in nl80211_signal_poll()
7258 drv->nlmode != NL80211_IFTYPE_MESH_POINT) in nl80211_signal_poll()
8095 if (drv->nlmode != NL80211_IFTYPE_P2P_DEVICE) in wpa_driver_nl80211_get_macaddr()
8327 if ((drv->nlmode != NL80211_IFTYPE_AP) && in nl80211_switch_channel()
8328 (drv->nlmode != NL80211_IFTYPE_P2P_GO)) in nl80211_switch_channel()
8442 if (!is_sta_interface(drv->nlmode)) in nl80211_add_ts()
8472 if (!is_sta_interface(drv->nlmode)) in nl80211_del_ts()
9758 enum nl80211_iftype nlmode; in nl80211_get_ext_capab() local
9764 nlmode = wpa_driver_nl80211_if_type(type); in nl80211_get_ext_capab()
9773 if (nlmode == drv->iface_ext_capa[i].iftype) { in nl80211_get_ext_capab()