* Paul E. McKenney <paulmck@xxxxxxxxxxxxxxxxxx> wrote: > On Thu, Jan 16, 2014 at 04:08:28PM -0800, Tim Chen wrote: > > This patch corrects the way memory barriers are used in the MCS lock > > with smp_load_acquire and smp_store_release fucnction. > > It removes ones that are not needed. > > > > Note that using the smp_load_acquire/smp_store_release pair is not > > sufficient to form a full memory barrier across > > cpus for many architectures (except x86) for mcs_unlock and mcs_lock. > > For applications that absolutely need a full barrier across multiple cpus > > with mcs_unlock and mcs_lock pair, smp_mb__after_unlock_lock() should be > > used after mcs_lock if a full memory barrier needs to be guaranteed. > > > > From: Waiman Long <Waiman.Long@xxxxxx> > > Suggested-by: Michel Lespinasse <walken@xxxxxxxxxx> > > Signed-off-by: Waiman Long <Waiman.Long@xxxxxx> > > Signed-off-by: Jason Low <jason.low2@xxxxxx> > > Signed-off-by: Tim Chen <tim.c.chen@xxxxxxxxxxxxxxx> > > And this fixes my gripes in the first patch in this series, good! So I'd really suggest doing fixes first in the series, code movement second. That will make it much easier to backport the fix to -stable, should the need arise. Thanks, Ingo -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>