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

Commit 0f3d042e authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller
Browse files

netfilter: use likely() in xt_info_rdlock_bh()

parent ec581f6a
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -472,7 +472,7 @@ static inline void xt_info_rdlock_bh(void)

	local_bh_disable();
	lock = &__get_cpu_var(xt_info_locks);
	if (!lock->readers++)
	if (likely(!lock->readers++))
		spin_lock(&lock->lock);
}

@@ -480,7 +480,7 @@ static inline void xt_info_rdunlock_bh(void)
{
	struct xt_info_lock *lock = &__get_cpu_var(xt_info_locks);

	if (!--lock->readers)
	if (likely(!--lock->readers))
		spin_unlock(&lock->lock);
	local_bh_enable();
}