Unverified Commit 66263229 authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!5058 net: fix possible store tearing in neigh_periodic_work()

parents a300fa02 17688897
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -935,7 +935,9 @@ static void neigh_periodic_work(struct work_struct *work)
			    (state == NUD_FAILED ||
			     !time_in_range_open(jiffies, n->used,
						 n->used + NEIGH_VAR(n->parms, GC_STALETIME)))) {
				*np = n->next;
				rcu_assign_pointer(*np,
					rcu_dereference_protected(n->next,
						lockdep_is_held(&tbl->lock)));
				neigh_mark_dead(n);
				write_unlock(&n->lock);
				neigh_cleanup_and_release(n);