|
@@ -241,7 +241,8 @@ static void softif_neigh_vid_select(struct bat_priv *bat_priv,
|
|
if (new_neigh && !atomic_inc_not_zero(&new_neigh->refcount))
|
|
if (new_neigh && !atomic_inc_not_zero(&new_neigh->refcount))
|
|
new_neigh = NULL;
|
|
new_neigh = NULL;
|
|
|
|
|
|
- curr_neigh = softif_neigh_vid->softif_neigh;
|
|
|
|
|
|
+ curr_neigh = rcu_dereference_protected(softif_neigh_vid->softif_neigh,
|
|
|
|
+ 1);
|
|
rcu_assign_pointer(softif_neigh_vid->softif_neigh, new_neigh);
|
|
rcu_assign_pointer(softif_neigh_vid->softif_neigh, new_neigh);
|
|
|
|
|
|
if ((curr_neigh) && (!new_neigh))
|
|
if ((curr_neigh) && (!new_neigh))
|