diff options
author | Kinglong Mee <kinglongmee@gmail.com> | 2015-03-28 23:46:09 +0800 |
---|---|---|
committer | J. Bruce Fields <bfields@redhat.com> | 2015-03-31 16:46:39 -0400 |
commit | 1ec8c0c47f63b4af66e3615618f842267ac88b4a (patch) | |
tree | daff1aedced240871e494b5c8f919831083942fe /fs/nfsd | |
parent | b14f4f7e61aaa4437a42e2e11055fc01782a15bf (diff) | |
download | linux-1ec8c0c47f63b4af66e3615618f842267ac88b4a.tar.gz linux-1ec8c0c47f63b4af66e3615618f842267ac88b4a.tar.bz2 linux-1ec8c0c47f63b4af66e3615618f842267ac88b4a.zip |
nfsd: Remove duplicate macro define for max sec label length
NFS4_MAXLABELLEN has defined for sec label max length, use it directly.
Signed-off-by: Kinglong Mee <kinglongmee@gmail.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/nfsd')
-rw-r--r-- | fs/nfsd/nfs4proc.c | 2 | ||||
-rw-r--r-- | fs/nfsd/nfs4xdr.c | 2 | ||||
-rw-r--r-- | fs/nfsd/xdr4.h | 1 |
3 files changed, 2 insertions, 3 deletions
diff --git a/fs/nfsd/nfs4proc.c b/fs/nfsd/nfs4proc.c index 8d7260ebb611..b401da386604 100644 --- a/fs/nfsd/nfs4proc.c +++ b/fs/nfsd/nfs4proc.c @@ -1815,7 +1815,7 @@ static inline u32 nfsd4_getattr_rsize(struct svc_rqst *rqstp, bmap0 &= ~FATTR4_WORD0_FILEHANDLE; } if (bmap2 & FATTR4_WORD2_SECURITY_LABEL) { - ret += NFSD4_MAX_SEC_LABEL_LEN + 12; + ret += NFS4_MAXLABELLEN + 12; bmap2 &= ~FATTR4_WORD2_SECURITY_LABEL; } /* diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c index 5c0aa74cba86..cea6c529434f 100644 --- a/fs/nfsd/nfs4xdr.c +++ b/fs/nfsd/nfs4xdr.c @@ -424,7 +424,7 @@ nfsd4_decode_fattr(struct nfsd4_compoundargs *argp, u32 *bmval, len += 4; dummy32 = be32_to_cpup(p++); READ_BUF(dummy32); - if (dummy32 > NFSD4_MAX_SEC_LABEL_LEN) + if (dummy32 > NFS4_MAXLABELLEN) return nfserr_badlabel; len += (XDR_QUADLEN(dummy32) << 2); READMEM(buf, dummy32); diff --git a/fs/nfsd/xdr4.h b/fs/nfsd/xdr4.h index 83e80d6d94a6..556ce2e47555 100644 --- a/fs/nfsd/xdr4.h +++ b/fs/nfsd/xdr4.h @@ -40,7 +40,6 @@ #include "state.h" #include "nfsd.h" -#define NFSD4_MAX_SEC_LABEL_LEN 2048 #define NFSD4_MAX_TAGLEN 128 #define XDR_LEN(n) (((n) + 3) & ~3) |