From 8f2c9c1b16bf6ed0903b29c49d56fa0109a390e4 Mon Sep 17 00:00:00 2001 From: Joel Becker Date: Fri, 1 Feb 2008 12:16:57 -0800 Subject: ocfs2: Create the lock status block union. Wrap the lock status block (lksb) in a union. Later we will add a union element for the fs/dlm lksb. Create accessors for the status and lvb fields. Other than a debugging function, dlmglue.c does not directly reference the o2dlm locking path anymore. Signed-off-by: Joel Becker Signed-off-by: Mark Fasheh --- fs/ocfs2/stackglue.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'fs/ocfs2/stackglue.h') diff --git a/fs/ocfs2/stackglue.h b/fs/ocfs2/stackglue.h index 8ebcfba62c7..3c91e241892 100644 --- a/fs/ocfs2/stackglue.h +++ b/fs/ocfs2/stackglue.h @@ -40,18 +40,25 @@ struct ocfs2_locking_protocol { void (*lp_unlock_ast)(void *astarg, int error); }; +union ocfs2_dlm_lksb { + struct dlm_lockstatus lksb_o2dlm; +}; + int ocfs2_dlm_lock(struct dlm_ctxt *dlm, int mode, - struct dlm_lockstatus *lksb, + union ocfs2_dlm_lksb *lksb, u32 flags, void *name, unsigned int namelen, void *astarg); int ocfs2_dlm_unlock(struct dlm_ctxt *dlm, - struct dlm_lockstatus *lksb, + union ocfs2_dlm_lksb *lksb, u32 flags, void *astarg); +int ocfs2_dlm_lock_status(union ocfs2_dlm_lksb *lksb); +void *ocfs2_dlm_lvb(union ocfs2_dlm_lksb *lksb); + void o2cb_get_stack(struct ocfs2_locking_protocol *proto); void o2cb_put_stack(void); -- cgit v1.2.3