Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 45eec341 authored by Changli Gao's avatar Changli Gao Committed by Patrick McHardy
Browse files

netfilter: nf_conntrack: remove an atomic bit operation



As this ct won't be seen by the others, we don't need to set the
IPS_CONFIRMED_BIT in atomic way.

Signed-off-by: default avatarChangli Gao <xiaosuo@gmail.com>
Cc: Tim Gardner <tim.gardner@canonical.com>
Cc: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
parent a7c2f4d7
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -486,7 +486,7 @@ __nf_conntrack_confirm(struct sk_buff *skb)
	ct->timeout.expires += jiffies;
	ct->timeout.expires += jiffies;
	add_timer(&ct->timeout);
	add_timer(&ct->timeout);
	atomic_inc(&ct->ct_general.use);
	atomic_inc(&ct->ct_general.use);
	set_bit(IPS_CONFIRMED_BIT, &ct->status);
	ct->status |= IPS_CONFIRMED;


	/* Since the lookup is lockless, hash insertion must be done after
	/* Since the lookup is lockless, hash insertion must be done after
	 * starting the timer and setting the CONFIRMED bit. The RCU barriers
	 * starting the timer and setting the CONFIRMED bit. The RCU barriers