X-Git-Url: http://git.liburcu.org/?p=urcu.git;a=blobdiff_plain;f=urcu-static.h;h=d46613196f5d471b21e584a85c0eaa7f60154e18;hp=0708df7c344038682595a39b3eb0fe977200d859;hb=9d7e3f89772f08cca26d727f47d44ecd47c94401;hpb=78ff941908d1c336106c06649c0892015cc98e18 diff --git a/urcu-static.h b/urcu-static.h index 0708df7..d466131 100644 --- a/urcu-static.h +++ b/urcu-static.h @@ -136,12 +136,12 @@ static inline void debug_yield_init(void) #endif #ifdef RCU_MB -static inline void reader_barrier() +static inline void smp_mb_light() { smp_mb(); } #else -static inline void reader_barrier() +static inline void smp_mb_light() { barrier(); } @@ -216,9 +216,9 @@ static inline void _rcu_read_lock(void) _STORE_SHARED(rcu_reader.ctr, _LOAD_SHARED(rcu_gp_ctr)); /* * Set active readers count for outermost nesting level before - * accessing the pointer. See force_mb_all_readers(). + * accessing the pointer. See smp_mb_heavy(). */ - reader_barrier(); + smp_mb_light(); } else { _STORE_SHARED(rcu_reader.ctr, tmp + RCU_GP_COUNT); } @@ -231,13 +231,13 @@ static inline void _rcu_read_unlock(void) tmp = rcu_reader.ctr; /* * Finish using rcu before decrementing the pointer. - * See force_mb_all_readers(). + * See smp_mb_heavy(). */ if (likely((tmp & RCU_GP_CTR_NEST_MASK) == RCU_GP_COUNT)) { - reader_barrier(); + smp_mb_light(); _STORE_SHARED(rcu_reader.ctr, rcu_reader.ctr - RCU_GP_COUNT); /* write rcu_reader.ctr before read futex */ - reader_barrier(); + smp_mb_light(); wake_up_gp(); } else { _STORE_SHARED(rcu_reader.ctr, rcu_reader.ctr - RCU_GP_COUNT);