]> git.ipfire.org Git - thirdparty/iw.git/commitdiff
iw: mesh: add mesh_param "mesh_nolearn" to skip path discovery
authorLinus Lüssing <ll@simonwunderlich.de>
Wed, 17 Jun 2020 07:30:34 +0000 (09:30 +0200)
committerJohannes Berg <johannes.berg@intel.com>
Thu, 30 Jul 2020 11:35:35 +0000 (13:35 +0200)
Currently, before being able to forward a packet between two 802.11s
nodes, both a PLINK handshake is performed upon receiving a beacon and
then later a PREQ/PREP exchange for path discovery is performed on
demand upon receiving a data frame to forward.

When running a mesh protocol on top of an 802.11s interface, like
batman-adv, we do not need the multi-hop mesh routing capabilities of
802.11s and usually set mesh_fwding=0. However, even with mesh_fwding=0
the PREQ/PREP path discovery is still performed on demand. Even though
in this scenario the next hop PREQ/PREP will determine is always the
direct 11s neighbor node.

The new mesh_nolearn parameter allows to skip the PREQ/PREP exchange in
this scenario, leading to a reduced delay, reduced packet buffering and
simplifies HWMP in general.

mesh_nolearn is still rather conservative in that if the packet destination
is not a direct 11s neighbor, it will fall back to PREQ/PREP path
discovery.

For normal, multi-hop 802.11s mesh routing it is usually not advisable
to enable mesh_nolearn as a transmission to a direct but distant neighbor
might be worse than reaching that same node via a more robust /
higher throughput etc. multi-hop path.

Cc: Sven Eckelmann <sven@narfation.org>
Cc: Simon Wunderlich <sw@simonwunderlich.de>
Signed-off-by: Linus Lüssing <ll@simonwunderlich.de>
Link: https://lore.kernel.org/r/20200617073034.26149-2-linus.luessing@c0d3.blue
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
mesh.c

diff --git a/mesh.c b/mesh.c
index 0650d0cf5ccc93f01542f68b007a11c0bd832f02..48bbc3fdbde97fd4cdef109335ea813171b31ef7 100644 (file)
--- a/mesh.c
+++ b/mesh.c
@@ -264,6 +264,8 @@ static const struct mesh_param_descr _mesh_param_descrs[] =
        _my_nla_put_u16, _parse_u16, _print_u16_in_TUs},
        {"mesh_plink_timeout", NL80211_MESHCONF_PLINK_TIMEOUT,
        _my_nla_put_u32, _parse_u32, _print_u32_in_seconds},
+       {"mesh_nolearn", NL80211_MESHCONF_NOLEARN,
+       _my_nla_put_u8, _parse_u8_as_bool, _print_u8},
 };
 
 static void print_all_mesh_param_descr(void)