summaryrefslogtreecommitdiffstats
path: root/fs/gfs2/locking/dlm/lock_dlm.h
diff options
context:
space:
mode:
authorSteven Whitehouse2008-05-21 18:21:42 +0200
committerSteven Whitehouse2008-06-27 10:39:25 +0200
commitf3c9d38a26be32abf9b8897e9e0afc7166c712dd (patch)
tree01b892d0d01720a396589c1f537dd0997128a060 /fs/gfs2/locking/dlm/lock_dlm.h
parent[GFS2] Clean up the glock core (diff)
downloadkernel-qcow2-linux-f3c9d38a26be32abf9b8897e9e0afc7166c712dd.tar.gz
kernel-qcow2-linux-f3c9d38a26be32abf9b8897e9e0afc7166c712dd.tar.xz
kernel-qcow2-linux-f3c9d38a26be32abf9b8897e9e0afc7166c712dd.zip
[GFS2] Fix ordering bug in lock_dlm
This looks like a lot of change, but in fact its not. Mostly its things moving from one file to another. The change is just that instead of queuing lock completions and callbacks from the DLM we now pass them directly to GFS2. This gives us a net loss of two list heads per glock (a fair saving in memory) plus a reduction in the latency of delivering the messages to GFS2, plus we now have one thread fewer as well. There was a bug where callbacks and completions could be delivered in the wrong order due to this unnecessary queuing which is fixed by this patch. Signed-off-by: Steven Whitehouse <swhiteho@redhat.com> Cc: Bob Peterson <rpeterso@redhat.com>
Diffstat (limited to 'fs/gfs2/locking/dlm/lock_dlm.h')
-rw-r--r--fs/gfs2/locking/dlm/lock_dlm.h12
1 files changed, 1 insertions, 11 deletions
diff --git a/fs/gfs2/locking/dlm/lock_dlm.h b/fs/gfs2/locking/dlm/lock_dlm.h
index a243cf69c54e..ad944c64eab1 100644
--- a/fs/gfs2/locking/dlm/lock_dlm.h
+++ b/fs/gfs2/locking/dlm/lock_dlm.h
@@ -72,15 +72,12 @@ struct gdlm_ls {
int recover_jid_done;
int recover_jid_status;
spinlock_t async_lock;
- struct list_head complete;
- struct list_head blocking;
struct list_head delayed;
struct list_head submit;
struct list_head all_locks;
u32 all_locks_count;
wait_queue_head_t wait_control;
- struct task_struct *thread1;
- struct task_struct *thread2;
+ struct task_struct *thread;
wait_queue_head_t thread_wait;
unsigned long drop_time;
int drop_locks_count;
@@ -117,10 +114,6 @@ struct gdlm_lock {
u32 lkf; /* dlm flags DLM_LKF_ */
unsigned long flags; /* lock_dlm flags LFL_ */
- int bast_mode; /* protected by async_lock */
-
- struct list_head clist; /* complete */
- struct list_head blist; /* blocking */
struct list_head delay_list; /* delayed */
struct list_head all_list; /* all locks for the fs */
struct gdlm_lock *hold_null; /* NL lock for hold_lvb */
@@ -159,11 +152,8 @@ void gdlm_release_threads(struct gdlm_ls *);
/* lock.c */
-s16 gdlm_make_lmstate(s16);
-void gdlm_queue_delayed(struct gdlm_lock *);
void gdlm_submit_delayed(struct gdlm_ls *);
int gdlm_release_all_locks(struct gdlm_ls *);
-void gdlm_delete_lp(struct gdlm_lock *);
unsigned int gdlm_do_lock(struct gdlm_lock *);
int gdlm_get_lock(void *, struct lm_lockname *, void **);