summaryrefslogtreecommitdiff
path: root/fs/dlm
diff options
context:
space:
mode:
authorDavid Teigland <teigland@redhat.com>2006-11-10 14:16:27 -0600
committerSteven Whitehouse <swhiteho@redhat.com>2006-11-30 10:35:27 -0500
commit6f90a8b1b87f97144911790390d56f695b59db9b (patch)
tree1a6a4d972984554535aec02880af159f45128668 /fs/dlm
parent4b77f2c93d052adca8cc8690b9b5e7f8798f4ddd (diff)
downloadlinux-3.10-6f90a8b1b87f97144911790390d56f695b59db9b.tar.gz
linux-3.10-6f90a8b1b87f97144911790390d56f695b59db9b.tar.bz2
linux-3.10-6f90a8b1b87f97144911790390d56f695b59db9b.zip
[DLM] clear sbflags on lock master
RH BZ 211622 The ALTMODE flag can be set in the lock master's copy of the lock but never cleared, so ALTMODE will also be returned in a subsequent conversion of the lock when it shouldn't be. This results in lock_dlm incorrectly switching to the alternate lock mode when returning the result to gfs which then asserts when it sees the wrong lock state. The fix is to propagate the cleared sbflags value to the master node when the lock is requested. QA's d_rwrandirectlarge test triggers this bug very quickly. Signed-off-by: David Teigland <teigland@redhat.com> Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Diffstat (limited to 'fs/dlm')
-rw-r--r--fs/dlm/lock.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/dlm/lock.c b/fs/dlm/lock.c
index 6088a16926b..30878defaeb 100644
--- a/fs/dlm/lock.c
+++ b/fs/dlm/lock.c
@@ -2372,6 +2372,7 @@ static int send_lookup_reply(struct dlm_ls *ls, struct dlm_message *ms_in,
static void receive_flags(struct dlm_lkb *lkb, struct dlm_message *ms)
{
lkb->lkb_exflags = ms->m_exflags;
+ lkb->lkb_sbflags = ms->m_sbflags;
lkb->lkb_flags = (lkb->lkb_flags & 0xFFFF0000) |
(ms->m_flags & 0x0000FFFF);
}