hostapd: refresh patches
[openwrt/openwrt.git] / package / network / services / hostapd / patches / 710-vlan_no_bridge.patch
1 --- a/src/ap/ap_config.h
2 +++ b/src/ap/ap_config.h
3 @@ -115,6 +115,7 @@ struct hostapd_ssid {
4 #define DYNAMIC_VLAN_OPTIONAL 1
5 #define DYNAMIC_VLAN_REQUIRED 2
6 int dynamic_vlan;
7 + int vlan_no_bridge;
8 #define DYNAMIC_VLAN_NAMING_WITHOUT_DEVICE 0
9 #define DYNAMIC_VLAN_NAMING_WITH_DEVICE 1
10 #define DYNAMIC_VLAN_NAMING_END 2
11 --- a/src/ap/vlan_full.c
12 +++ b/src/ap/vlan_full.c
13 @@ -475,6 +475,9 @@ void vlan_newlink(const char *ifname, st
14 if (!vlan)
15 return;
16
17 + if (hapd->conf->ssid.vlan_no_bridge)
18 + goto out;
19 +
20 vlan->configured = 1;
21
22 notempty = vlan->vlan_desc.notempty;
23 @@ -506,6 +509,7 @@ void vlan_newlink(const char *ifname, st
24 ifname, br_name, tagged[i], hapd);
25 }
26
27 +out:
28 ifconfig_up(ifname);
29 }
30
31 --- a/hostapd/config_file.c
32 +++ b/hostapd/config_file.c
33 @@ -3381,6 +3381,8 @@ static int hostapd_config_fill(struct ho
34 #ifndef CONFIG_NO_VLAN
35 } else if (os_strcmp(buf, "dynamic_vlan") == 0) {
36 bss->ssid.dynamic_vlan = atoi(pos);
37 + } else if (os_strcmp(buf, "vlan_no_bridge") == 0) {
38 + bss->ssid.vlan_no_bridge = atoi(pos);
39 } else if (os_strcmp(buf, "per_sta_vif") == 0) {
40 bss->ssid.per_sta_vif = atoi(pos);
41 } else if (os_strcmp(buf, "vlan_file") == 0) {