diff options
author | Andy Kling <andreas.kling@peiker-cee.de> | 2019-02-20 10:08:27 +0100 |
---|---|---|
committer | Lubomir Rintel <lkundrak@v3.sk> | 2019-07-15 15:16:34 +0000 |
commit | b434521d68c959e64faf9467c38f413e8a9d99db (patch) | |
tree | b610e565cb13ded7b24fd61a512738044505d8a3 | |
parent | bbaa17d54b8f81bc511481d78ac5e7e6f9d3c909 (diff) | |
download | NetworkManager-b434521d68c959e64faf9467c38f413e8a9d99db.tar.gz |
wifi/ap: detect mesh mode
mark ap if supplicant reports bss property "Mode = 'mesh'".
bss mode mesh is available since hostap_2_6-729-g213eb1885
check mesh connections are compatible with detected mode.
-rw-r--r-- | src/devices/wifi/nm-wifi-ap.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/devices/wifi/nm-wifi-ap.c b/src/devices/wifi/nm-wifi-ap.c index e6e79649d7..e08fb4768c 100644 --- a/src/devices/wifi/nm-wifi-ap.c +++ b/src/devices/wifi/nm-wifi-ap.c @@ -815,6 +815,8 @@ nm_wifi_ap_update_from_properties (NMWifiAP *ap, changed |= nm_wifi_ap_set_mode (ap, NM_802_11_MODE_INFRA); else if (!g_strcmp0 (s, "ad-hoc")) changed |= nm_wifi_ap_set_mode (ap, NM_802_11_MODE_ADHOC); + else if (!g_strcmp0 (s, "mesh")) + changed |= nm_wifi_ap_set_mode (ap, NM_802_11_MODE_MESH); } if (g_variant_lookup (properties, "Signal", "n", &i16)) @@ -1007,7 +1009,9 @@ nm_wifi_ap_to_string (const NMWifiAP *self, ? '#' : (priv->fake ? 'f' - : 'a'))), + : (priv->mode == NM_802_11_MODE_MESH + ? 'm' + : 'a')))), chan, priv->strength, priv->flags & NM_802_11_AP_FLAGS_PRIVACY ? 'P' : '_', @@ -1072,6 +1076,8 @@ nm_wifi_ap_check_compatible (NMWifiAP *self, if ( !strcmp (mode, "ap") && (priv->mode != NM_802_11_MODE_INFRA || priv->hotspot != TRUE)) return FALSE; + if (!strcmp (mode, "mesh") && (priv->mode != NM_802_11_MODE_MESH)) + return FALSE; } band = nm_setting_wireless_get_band (s_wireless); |