summaryrefslogtreecommitdiffstats
path: root/fs/gfs2/lock_dlm.c
diff options
context:
space:
mode:
authorSteven Whitehouse <swhiteho@redhat.com>2010-11-30 16:49:31 +0100
committerSteven Whitehouse <swhiteho@redhat.com>2010-11-30 16:49:31 +0100
commit47a25380e37f44db7202093ca92e4af569c34f55 (patch)
treedb3e6dba3859c5562b9a86f6d4059519fa7a1c52 /fs/gfs2/lock_dlm.c
parentGFS2: Fix uninitialised error value in previous patch (diff)
downloadlinux-47a25380e37f44db7202093ca92e4af569c34f55.tar.xz
linux-47a25380e37f44db7202093ca92e4af569c34f55.zip
GFS2: Merge glock state fields into a bitfield
We can only merge the fields into a bitfield if the locking rules for them are the same. In this case gl_spin covers all of the fields (write side) but a couple of them are used with GLF_LOCK as the read side lock, which should be ok since we know that the field in question won't be changing at the time. The gl_req setting has to be done earlier (in glock.c) in order to place it under gl_spin. The gl_reply setting also has to be brought under gl_spin in order to comply with the new rules. This saves 4*sizeof(unsigned int) per glock. Signed-off-by: Steven Whitehouse <swhiteho@redhat.com> Cc: Bob Peterson <rpeterso@redhat.com>
Diffstat (limited to 'fs/gfs2/lock_dlm.c')
-rw-r--r--fs/gfs2/lock_dlm.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/fs/gfs2/lock_dlm.c b/fs/gfs2/lock_dlm.c
index f40ce34c803e..6e493aee28f8 100644
--- a/fs/gfs2/lock_dlm.c
+++ b/fs/gfs2/lock_dlm.c
@@ -153,7 +153,6 @@ static int gdlm_lock(struct gfs2_glock *gl, unsigned int req_state,
int req;
u32 lkf;
- gl->gl_req = req_state;
req = make_mode(req_state);
lkf = make_flags(gl->gl_lksb.sb_lkid, flags, req);