aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/linux/netfilter/x_tables.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/netfilter/x_tables.h b/include/linux/netfilter/x_tables.h
index 1b2e43502ef7..c9efe039dc57 100644
--- a/include/linux/netfilter/x_tables.h
+++ b/include/linux/netfilter/x_tables.h
@@ -472,7 +472,7 @@ static inline void xt_info_rdlock_bh(void)
472 472
473 local_bh_disable(); 473 local_bh_disable();
474 lock = &__get_cpu_var(xt_info_locks); 474 lock = &__get_cpu_var(xt_info_locks);
475 if (!lock->readers++) 475 if (likely(!lock->readers++))
476 spin_lock(&lock->lock); 476 spin_lock(&lock->lock);
477} 477}
478 478
@@ -480,7 +480,7 @@ static inline void xt_info_rdunlock_bh(void)
480{ 480{
481 struct xt_info_lock *lock = &__get_cpu_var(xt_info_locks); 481 struct xt_info_lock *lock = &__get_cpu_var(xt_info_locks);
482 482
483 if (!--lock->readers) 483 if (likely(!--lock->readers))
484 spin_unlock(&lock->lock); 484 spin_unlock(&lock->lock);
485 local_bh_enable(); 485 local_bh_enable();
486} 486}