#ifndef DLMAPI_H
#define DLMAPI_H
struct dlm_lock;
struct dlm_ctxt;
enum dlm_status { … };
const char *dlm_errmsg(enum dlm_status err);
const char *dlm_errname(enum dlm_status err);
#define dlm_error(st) …
#define DLM_LKSB_UNUSED1 …
#define DLM_LKSB_PUT_LVB …
#define DLM_LKSB_GET_LVB …
#define DLM_LKSB_UNUSED2 …
#define DLM_LKSB_UNUSED3 …
#define DLM_LKSB_UNUSED4 …
#define DLM_LKSB_UNUSED5 …
#define DLM_LKSB_UNUSED6 …
#define DLM_LVB_LEN …
struct dlm_lockstatus { … };
#define LKM_IVMODE …
#define LKM_NLMODE …
#define LKM_CRMODE …
#define LKM_CWMODE …
#define LKM_PRMODE …
#define LKM_PWMODE …
#define LKM_EXMODE …
#define LKM_MAXMODE …
#define LKM_MODEMASK …
#define LKM_ORPHAN …
#define LKM_PARENTABLE …
#define LKM_BLOCK …
#define LKM_LOCAL …
#define LKM_VALBLK …
#define LKM_NOQUEUE …
#define LKM_CONVERT …
#define LKM_NODLCKWT …
#define LKM_UNLOCK …
#define LKM_CANCEL …
#define LKM_DEQALL …
#define LKM_INVVALBLK …
#define LKM_SYNCSTS …
#define LKM_TIMEOUT …
#define LKM_SNGLDLCK …
#define LKM_FINDLOCAL …
#define LKM_PROC_OWNED …
#define LKM_XID …
#define LKM_XID_CONFLICT …
#define LKM_FORCE …
#define LKM_REVVALBLK …
#define LKM_UNUSED1 …
#define LKM_UNUSED2 …
#define LKM_UNUSED3 …
#define LKM_UNUSED4 …
#define LKM_UNUSED5 …
#define LKM_UNUSED6 …
#define LKM_UNUSED7 …
#define LKM_MIGRATION …
#define LKM_PUT_LVB …
#define LKM_GET_LVB …
#define LKM_RECOVERY …
dlm_astlockfunc_t;
dlm_bastlockfunc_t;
dlm_astunlockfunc_t;
enum dlm_status dlmlock(struct dlm_ctxt *dlm,
int mode,
struct dlm_lockstatus *lksb,
int flags,
const char *name,
int namelen,
dlm_astlockfunc_t *ast,
void *data,
dlm_bastlockfunc_t *bast);
enum dlm_status dlmunlock(struct dlm_ctxt *dlm,
struct dlm_lockstatus *lksb,
int flags,
dlm_astunlockfunc_t *unlockast,
void *data);
struct dlm_protocol_version { … };
struct dlm_ctxt * dlm_register_domain(const char *domain, u32 key,
struct dlm_protocol_version *fs_proto);
void dlm_unregister_domain(struct dlm_ctxt *dlm);
void dlm_print_one_lock(struct dlm_lock *lockid);
dlm_eviction_func;
struct dlm_eviction_cb { … };
void dlm_setup_eviction_cb(struct dlm_eviction_cb *cb,
dlm_eviction_func *f,
void *data);
void dlm_register_eviction_cb(struct dlm_ctxt *dlm,
struct dlm_eviction_cb *cb);
void dlm_unregister_eviction_cb(struct dlm_eviction_cb *cb);
#endif