From 7431cd7e8dd0e46e9b12bd6a1ac1286f4b420371 Mon Sep 17 00:00:00 2001 From: Joel Becker Date: Fri, 1 Feb 2008 12:15:37 -0800 Subject: ocfs2: Use -errno instead of dlm_status for ocfs2_dlm_lock/unlock() API. Change the ocfs2_dlm_lock/unlock() functions to return -errno values. This is the first step towards elminiating dlm_status in fs/ocfs2/dlmglue.c. The change also passes -errno values to ->unlock_ast(). [ Fix a return code in dlmglue.c and change the error translation table into an array of ints. --Mark ] Signed-off-by: Joel Becker Signed-off-by: Mark Fasheh --- fs/ocfs2/stackglue.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'fs/ocfs2/stackglue.h') diff --git a/fs/ocfs2/stackglue.h b/fs/ocfs2/stackglue.h index 986d059ed1e..8ebcfba62c7 100644 --- a/fs/ocfs2/stackglue.h +++ b/fs/ocfs2/stackglue.h @@ -37,17 +37,17 @@ struct ocfs2_locking_protocol { void (*lp_lock_ast)(void *astarg); void (*lp_blocking_ast)(void *astarg, int level); - void (*lp_unlock_ast)(void *astarg, enum dlm_status status); + void (*lp_unlock_ast)(void *astarg, int error); }; -enum dlm_status ocfs2_dlm_lock(struct dlm_ctxt *dlm, +int ocfs2_dlm_lock(struct dlm_ctxt *dlm, int mode, struct dlm_lockstatus *lksb, u32 flags, void *name, unsigned int namelen, void *astarg); -enum dlm_status ocfs2_dlm_unlock(struct dlm_ctxt *dlm, +int ocfs2_dlm_unlock(struct dlm_ctxt *dlm, struct dlm_lockstatus *lksb, u32 flags, void *astarg); -- cgit v1.2.3