Repository : ssh://git@open-mesh.org/batman-adv
On branch : next
commit de6db08fd0a6a0f9a1a213b3e11b6b26acde46a0 Merge: 41d1e61 ead9389 Author: Marek Lindner mareklindner@neomailbox.ch Date: Wed Feb 10 18:48:34 2016 +0800
Merge branch 'maint' into next
de6db08fd0a6a0f9a1a213b3e11b6b26acde46a0 net/batman-adv/gateway_client.c | 7 ++++--- net/batman-adv/translation-table.c | 6 ++++-- 2 files changed, 8 insertions(+), 5 deletions(-)
diff --cc net/batman-adv/gateway_client.c index 346d5f7,c9b8b48..c59aff5 --- a/net/batman-adv/gateway_client.c +++ b/net/batman-adv/gateway_client.c @@@ -544,11 -527,12 +544,12 @@@ void batadv_gw_node_update(struct batad * gets dereferenced. */ spin_lock_bh(&bat_priv->gw.list_lock); - hlist_del_init_rcu(&gw_node->list); + if (!hlist_unhashed(&gw_node->list)) { + hlist_del_init_rcu(&gw_node->list); - batadv_gw_node_free_ref(gw_node); ++ batadv_gw_node_put(gw_node); + } spin_unlock_bh(&bat_priv->gw.list_lock);
- batadv_gw_node_put(gw_node); - curr_gw = batadv_gw_get_selected_gw_node(bat_priv); if (gw_node == curr_gw) batadv_gw_reselect(bat_priv); diff --cc net/batman-adv/translation-table.c index 2fd5b28,7301a92..0b43e86 --- a/net/batman-adv/translation-table.c +++ b/net/batman-adv/translation-table.c @@@ -346,12 -311,14 +346,14 @@@ static void batadv_tt_global_size_mod(s
if (atomic_add_return(v, &vlan->tt.num_entries) == 0) { spin_lock_bh(&orig_node->vlan_list_lock); - hlist_del_init_rcu(&vlan->list); + if (!hlist_unhashed(&vlan->list)) { + hlist_del_init_rcu(&vlan->list); - batadv_orig_node_vlan_free_ref(vlan); ++ batadv_orig_node_vlan_put(vlan); + } spin_unlock_bh(&orig_node->vlan_list_lock); - batadv_orig_node_vlan_put(vlan); }
- batadv_orig_node_vlan_free_ref(vlan); + batadv_orig_node_vlan_put(vlan); }
/**