Commit 82bd687c authored by Neil Brown's avatar Neil Brown Committed by Linus Torvalds

[PATCH] knfsd: get rid of the special delegation_stateid_t, use the existing stateid_t.

Signed-off-by: default avatarAndy Adamson <andros@citi.umich.edu>
Signed-off-by: default avatarNeil Brown <neilb@cse.unsw.edu.au>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 34e284b6
......@@ -790,8 +790,8 @@ nfsd4_decode_open(struct nfsd4_compoundargs *argp, struct nfsd4_open *open)
READ32(open->op_delegate_type);
break;
case NFS4_OPEN_CLAIM_DELEGATE_CUR:
READ_BUF(sizeof(delegation_stateid_t) + 4);
COPYMEM(&open->op_delegate_stateid, sizeof(delegation_stateid_t));
READ_BUF(sizeof(stateid_t) + 4);
COPYMEM(&open->op_delegate_stateid, sizeof(stateid_t));
READ32(open->op_fname.len);
READ_BUF(open->op_fname.len);
SAVEMEM(open->op_fname.data, open->op_fname.len);
......@@ -2072,8 +2072,8 @@ nfsd4_encode_open(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_open
case NFS4_OPEN_DELEGATE_NONE:
break;
case NFS4_OPEN_DELEGATE_READ:
RESERVE_SPACE(20 + sizeof(delegation_stateid_t));
WRITEMEM(&open->op_delegate_stateid, sizeof(delegation_stateid_t));
RESERVE_SPACE(20 + sizeof(stateid_t));
WRITEMEM(&open->op_delegate_stateid, sizeof(stateid_t));
WRITE32(0);
/*
......@@ -2086,8 +2086,8 @@ nfsd4_encode_open(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_open
ADJUST_ARGS();
break;
case NFS4_OPEN_DELEGATE_WRITE:
RESERVE_SPACE(32 + sizeof(delegation_stateid_t));
WRITEMEM(&open->op_delegate_stateid, sizeof(delegation_stateid_t));
RESERVE_SPACE(32 + sizeof(stateid_t));
WRITEMEM(&open->op_delegate_stateid, sizeof(stateid_t));
WRITE32(0);
/*
......
......@@ -44,16 +44,6 @@
#define NFSD4_MAX_TAGLEN 128
#define XDR_LEN(n) (((n) + 3) & ~3)
typedef u32 delegation_zero_t;
typedef u32 delegation_boot_t;
typedef u64 delegation_id_t;
typedef struct {
delegation_zero_t ds_zero;
delegation_boot_t ds_boot;
delegation_id_t ds_id;
} delegation_stateid_t;
struct nfsd4_change_info {
u32 atomic;
u32 before_ctime_sec;
......@@ -202,7 +192,7 @@ struct nfsd4_open {
u32 op_claim_type; /* request */
struct xdr_netobj op_fname; /* request - everything but CLAIM_PREV */
u32 op_delegate_type; /* request - CLAIM_PREV only */
delegation_stateid_t op_delegate_stateid; /* request - CLAIM_DELEGATE_CUR only */
stateid_t op_delegate_stateid; /* request - response */
u32 op_create; /* request */
u32 op_createmode; /* request */
u32 op_bmval[2]; /* request */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment