[DLM] compat patch

Here's a patch which add 32/64 bit compat to the DLM IOs and tidies the
structures for alignment.

As it causes an ABI change I had few qualms about adding the extra flag for
"is64bit" as it simply uses a byte that would have been padding.

Cc: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Patrick Caulfield <pcaulfie@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
This commit is contained in:
Patrick Caulfield 2006-06-09 16:14:20 -04:00 committed by Steven Whitehouse
parent 01eb7c0796
commit 22da645fd6
2 changed files with 163 additions and 14 deletions

View file

@ -18,35 +18,37 @@
#define DLM_USER_LVB_LEN 32
/* Version of the device interface */
#define DLM_DEVICE_VERSION_MAJOR 4
#define DLM_DEVICE_VERSION_MAJOR 5
#define DLM_DEVICE_VERSION_MINOR 0
#define DLM_DEVICE_VERSION_PATCH 0
/* struct passed to the lock write */
struct dlm_lock_params {
__u8 mode;
__u8 namelen;
__u16 flags;
__u32 lkid;
__u32 parent;
__u8 namelen;
void __user *castparam;
void __user *castaddr;
void __user *bastparam;
void __user *bastaddr;
struct dlm_lksb __user *lksb;
char lvb[DLM_USER_LVB_LEN];
char name[1];
char name[0];
};
struct dlm_lspace_params {
__u32 flags;
__u32 minor;
char name[1];
char name[0];
};
struct dlm_write_request {
__u32 version[3];
__u8 cmd;
__u8 is64bit;
__u8 unused[2];
union {
struct dlm_lock_params lock;
@ -63,6 +65,7 @@ struct dlm_lock_result {
struct dlm_lksb __user * user_lksb;
struct dlm_lksb lksb;
__u8 bast_mode;
__u8 unused[3];
/* Offsets may be zero if no data is present */
__u32 lvb_offset;
};