From: Steven Whitehouse Date: Thu, 5 Sep 2013 10:02:10 +0100 Subject: [Cluster-devel] [PATCH 4/6] GFS2: Remove unnecessary memory barrier In-Reply-To: <1378371732-3947-1-git-send-email-swhiteho@redhat.com> References: <1378371732-3947-1-git-send-email-swhiteho@redhat.com> Message-ID: <1378371732-3947-5-git-send-email-swhiteho@redhat.com> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit From: Bob Peterson Function test_and_clear_bit implies a memory barrier, so subsequent memory barriers are unnecessary. Signed-off-by: Bob Peterson Signed-off-by: Steven Whitehouse diff --git a/fs/gfs2/glock.c b/fs/gfs2/glock.c index ce7078d..722329c 100644 --- a/fs/gfs2/glock.c +++ b/fs/gfs2/glock.c @@ -1411,7 +1411,6 @@ __acquires(&lru_lock) if (demote_ok(gl)) handle_callback(gl, LM_ST_UNLOCKED, 0, false); WARN_ON(!test_and_clear_bit(GLF_LOCK, &gl->gl_flags)); - smp_mb__after_clear_bit(); if (queue_delayed_work(glock_workqueue, &gl->gl_work, 0) == 0) gfs2_glock_put_nolock(gl); spin_unlock(&gl->gl_spin); -- 1.7.4