aboutsummaryrefslogtreecommitdiff
path: root/net/batman-adv/originator.c
diff options
context:
space:
mode:
authorGravatar Simon Wunderlich <simon@open-mesh.com> 2013-11-13 19:14:50 +0100
committerGravatar Antonio Quartulli <antonio@meshcoding.com> 2014-01-12 14:41:15 +0100
commitf3b3d9018975ffb2680b7c1d37122f9d80301587 (patch)
tree7bba5d71de0bfae806d91653ef8262f396bc08b3 /net/batman-adv/originator.c
parentbatman-adv: consider outgoing interface in OGM sending (diff)
downloadlinux-f3b3d9018975ffb2680b7c1d37122f9d80301587.tar.gz
linux-f3b3d9018975ffb2680b7c1d37122f9d80301587.tar.bz2
linux-f3b3d9018975ffb2680b7c1d37122f9d80301587.zip
batman-adv: add bonding again
With the new interface alternating, the first hop may send packets in a round robin fashion to it's neighbors because it has multiple valid routes built by the multi interface optimization. This patch enables the feature if bonding is selected. Note that unlike the bonding implemented before, this version is much simpler and may even enable multi path routing to a certain degree. Signed-off-by: Simon Wunderlich <simon@open-mesh.com> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
Diffstat (limited to 'net/batman-adv/originator.c')
-rw-r--r--net/batman-adv/originator.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/net/batman-adv/originator.c b/net/batman-adv/originator.c
index b8ef41600166..bd887809f08e 100644
--- a/net/batman-adv/originator.c
+++ b/net/batman-adv/originator.c
@@ -701,6 +701,10 @@ batadv_purge_orig_ifinfo(struct batadv_priv *bat_priv,
hlist_del_rcu(&orig_ifinfo->list);
batadv_orig_ifinfo_free_ref(orig_ifinfo);
+ if (orig_node->last_bonding_candidate == orig_ifinfo) {
+ orig_node->last_bonding_candidate = NULL;
+ batadv_orig_ifinfo_free_ref(orig_ifinfo);
+ }
}
spin_unlock_bh(&orig_node->neigh_list_lock);