Skip to content

Commit 174dd22

Browse files
paulmckrcuFrederic Weisbecker
authored andcommitted
srcu: Remove smp_mb() from srcu_read_unlock_lite()
The srcu_read_unlock_lite() function invokes __srcu_read_unlock() instead of __srcu_read_unlock_lite(), which means that it is doing an unnecessary smp_mb(). This is harmless other than the performance degradation. This commit therefore switches to __srcu_read_unlock_lite(). Reported-by: Neeraj Upadhyay <[email protected]> Closes: https://lore.kernel.org/all/[email protected]/ Fixes: c0f08d6 ("srcu: Add srcu_read_lock_lite() and srcu_read_unlock_lite()") Signed-off-by: Paul E. McKenney <[email protected]> Cc: Frederic Weisbecker <[email protected]> Reviewed-by: Neeraj Upadhyay <[email protected]> Signed-off-by: Frederic Weisbecker <[email protected]>
1 parent 768b1f8 commit 174dd22

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/linux/srcu.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -372,7 +372,7 @@ static inline void srcu_read_unlock_lite(struct srcu_struct *ssp, int idx)
372372
WARN_ON_ONCE(idx & ~0x1);
373373
srcu_check_read_flavor(ssp, SRCU_READ_FLAVOR_LITE);
374374
srcu_lock_release(&ssp->dep_map);
375-
__srcu_read_unlock(ssp, idx);
375+
__srcu_read_unlock_lite(ssp, idx);
376376
}
377377

378378
/**

0 commit comments

Comments
 (0)