summaryrefslogtreecommitdiffstats
path: root/fs/nfsd/nfs4xdr.c
diff options
context:
space:
mode:
authorKinglong Mee <kinglongmee@gmail.com>2014-06-29 19:18:17 +0800
committerJ. Bruce Fields <bfields@redhat.com>2014-07-08 17:14:28 -0400
commit1055414fe19db2db6c8947c0b9ee9c8fe07beea1 (patch)
treecc63dd806e6c4c2846e2b66b6fc3768e061fb66f /fs/nfsd/nfs4xdr.c
parentd5e2338324102dcf34aa25aeaf96064cc4d94dce (diff)
downloadlinux-1055414fe19db2db6c8947c0b9ee9c8fe07beea1.tar.bz2
NFSD: Avoid warning message when compile at i686 arch
fs/nfsd/nfs4xdr.c: In function 'nfsd4_encode_readv': >> fs/nfsd/nfs4xdr.c:3137:148: warning: comparison of distinct pointer types lacks a cast [enabled by default] thislen = min(len, ((void *)xdr->end - (void *)xdr->p)); Reported-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Kinglong Mee <kinglongmee@gmail.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/nfsd/nfs4xdr.c')
-rw-r--r--fs/nfsd/nfs4xdr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c
index 46115f2c3074..9388a4316fa8 100644
--- a/fs/nfsd/nfs4xdr.c
+++ b/fs/nfsd/nfs4xdr.c
@@ -3140,7 +3140,7 @@ static __be32 nfsd4_encode_readv(struct nfsd4_compoundres *resp,
len = maxcount;
v = 0;
- thislen = min(len, ((void *)xdr->end - (void *)xdr->p));
+ thislen = min_t(long, len, ((void *)xdr->end - (void *)xdr->p));
p = xdr_reserve_space(xdr, (thislen+3)&~3);
WARN_ON_ONCE(!p);
resp->rqstp->rq_vec[v].iov_base = p;