• Home
  • Raw
  • Download

Lines Matching refs:hapd

22 static int vlan_if_add(struct hostapd_data *hapd, struct hostapd_vlan *vlan,  in vlan_if_add()  argument
28 if (!hapd->conf->ssid.wep.key[i]) in vlan_if_add()
37 ret = hostapd_vlan_if_add(hapd, vlan->ifname); in vlan_if_add()
48 if (hapd->wpa_auth) in vlan_if_add()
49 ret = wpa_auth_ensure_group(hapd->wpa_auth, vlan->vlan_id); in vlan_if_add()
56 if (wpa_auth_release_group(hapd->wpa_auth, vlan->vlan_id)) in vlan_if_add()
60 if (hostapd_vlan_if_remove(hapd, vlan->ifname)) in vlan_if_add()
67 int vlan_if_remove(struct hostapd_data *hapd, struct hostapd_vlan *vlan) in vlan_if_remove() argument
71 ret = wpa_auth_release_group(hapd->wpa_auth, vlan->vlan_id); in vlan_if_remove()
77 return hostapd_vlan_if_remove(hapd, vlan->ifname); in vlan_if_remove()
81 static int vlan_dynamic_add(struct hostapd_data *hapd, in vlan_dynamic_add() argument
86 if (vlan_if_add(hapd, vlan, 1)) { in vlan_dynamic_add()
93 vlan_newlink(vlan->ifname, hapd); in vlan_dynamic_add()
104 static void vlan_dynamic_remove(struct hostapd_data *hapd, in vlan_dynamic_remove() argument
115 vlan_dellink(vlan->ifname, hapd); in vlan_dynamic_remove()
118 vlan_if_remove(hapd, vlan)) { in vlan_dynamic_remove()
130 int vlan_init(struct hostapd_data *hapd) in vlan_init() argument
133 hapd->full_dynamic_vlan = full_dynamic_vlan_init(hapd); in vlan_init()
136 if ((hapd->conf->ssid.dynamic_vlan != DYNAMIC_VLAN_DISABLED || in vlan_init()
137 hapd->conf->ssid.per_sta_vif) && in vlan_init()
138 !hapd->conf->vlan) { in vlan_init()
150 hapd->conf->iface); in vlan_init()
151 vlan->next = hapd->conf->vlan; in vlan_init()
152 hapd->conf->vlan = vlan; in vlan_init()
155 if (vlan_dynamic_add(hapd, hapd->conf->vlan)) in vlan_init()
162 void vlan_deinit(struct hostapd_data *hapd) in vlan_deinit() argument
164 vlan_dynamic_remove(hapd, hapd->conf->vlan); in vlan_deinit()
167 full_dynamic_vlan_deinit(hapd->full_dynamic_vlan); in vlan_deinit()
168 hapd->full_dynamic_vlan = NULL; in vlan_deinit()
173 struct hostapd_vlan * vlan_add_dynamic(struct hostapd_data *hapd, in vlan_add_dynamic() argument
204 n->next = hapd->conf->vlan; in vlan_add_dynamic()
205 hapd->conf->vlan = n; in vlan_add_dynamic()
208 if (vlan_if_add(hapd, n, 0)) { in vlan_add_dynamic()
209 hapd->conf->vlan = n->next; in vlan_add_dynamic()
218 int vlan_remove_dynamic(struct hostapd_data *hapd, int vlan_id) in vlan_remove_dynamic() argument
226 __func__, hapd->conf->iface, vlan_id); in vlan_remove_dynamic()
228 vlan = hapd->conf->vlan; in vlan_remove_dynamic()
241 vlan_if_remove(hapd, vlan); in vlan_remove_dynamic()
243 vlan_dellink(vlan->ifname, hapd); in vlan_remove_dynamic()