xref: /linux/include/uapi/linux/dlm_plock.h (revision 607ca46e97a1b6594b29647d98a32d545c24bdff)
1*607ca46eSDavid Howells /*
2*607ca46eSDavid Howells  * Copyright (C) 2005-2008 Red Hat, Inc.  All rights reserved.
3*607ca46eSDavid Howells  *
4*607ca46eSDavid Howells  * This copyrighted material is made available to anyone wishing to use,
5*607ca46eSDavid Howells  * modify, copy, or redistribute it subject to the terms and conditions
6*607ca46eSDavid Howells  * of the GNU General Public License v.2.
7*607ca46eSDavid Howells  */
8*607ca46eSDavid Howells 
9*607ca46eSDavid Howells #ifndef _UAPI__DLM_PLOCK_DOT_H__
10*607ca46eSDavid Howells #define _UAPI__DLM_PLOCK_DOT_H__
11*607ca46eSDavid Howells 
12*607ca46eSDavid Howells #include <linux/types.h>
13*607ca46eSDavid Howells 
14*607ca46eSDavid Howells #define DLM_PLOCK_MISC_NAME		"dlm_plock"
15*607ca46eSDavid Howells 
16*607ca46eSDavid Howells #define DLM_PLOCK_VERSION_MAJOR	1
17*607ca46eSDavid Howells #define DLM_PLOCK_VERSION_MINOR	2
18*607ca46eSDavid Howells #define DLM_PLOCK_VERSION_PATCH	0
19*607ca46eSDavid Howells 
20*607ca46eSDavid Howells enum {
21*607ca46eSDavid Howells 	DLM_PLOCK_OP_LOCK = 1,
22*607ca46eSDavid Howells 	DLM_PLOCK_OP_UNLOCK,
23*607ca46eSDavid Howells 	DLM_PLOCK_OP_GET,
24*607ca46eSDavid Howells };
25*607ca46eSDavid Howells 
26*607ca46eSDavid Howells #define DLM_PLOCK_FL_CLOSE 1
27*607ca46eSDavid Howells 
28*607ca46eSDavid Howells struct dlm_plock_info {
29*607ca46eSDavid Howells 	__u32 version[3];
30*607ca46eSDavid Howells 	__u8 optype;
31*607ca46eSDavid Howells 	__u8 ex;
32*607ca46eSDavid Howells 	__u8 wait;
33*607ca46eSDavid Howells 	__u8 flags;
34*607ca46eSDavid Howells 	__u32 pid;
35*607ca46eSDavid Howells 	__s32 nodeid;
36*607ca46eSDavid Howells 	__s32 rv;
37*607ca46eSDavid Howells 	__u32 fsid;
38*607ca46eSDavid Howells 	__u64 number;
39*607ca46eSDavid Howells 	__u64 start;
40*607ca46eSDavid Howells 	__u64 end;
41*607ca46eSDavid Howells 	__u64 owner;
42*607ca46eSDavid Howells };
43*607ca46eSDavid Howells 
44*607ca46eSDavid Howells 
45*607ca46eSDavid Howells #endif /* _UAPI__DLM_PLOCK_DOT_H__ */
46