aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfsd/nfs4callback.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/nfsd/nfs4callback.c')
-rw-r--r--fs/nfsd/nfs4callback.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/nfsd/nfs4callback.c b/fs/nfsd/nfs4callback.c
index d828662d737d..c872bd07fc10 100644
--- a/fs/nfsd/nfs4callback.c
+++ b/fs/nfsd/nfs4callback.c
@@ -326,6 +326,8 @@ out:
326 .p_encode = (kxdrproc_t) nfs4_xdr_##argtype, \ 326 .p_encode = (kxdrproc_t) nfs4_xdr_##argtype, \
327 .p_decode = (kxdrproc_t) nfs4_xdr_##restype, \ 327 .p_decode = (kxdrproc_t) nfs4_xdr_##restype, \
328 .p_bufsiz = MAX(NFS4_##argtype##_sz,NFS4_##restype##_sz) << 2, \ 328 .p_bufsiz = MAX(NFS4_##argtype##_sz,NFS4_##restype##_sz) << 2, \
329 .p_statidx = NFSPROC4_CB_##call, \
330 .p_name = #proc, \
329} 331}
330 332
331static struct rpc_procinfo nfs4_cb_procedures[] = { 333static struct rpc_procinfo nfs4_cb_procedures[] = {
@@ -335,7 +337,7 @@ static struct rpc_procinfo nfs4_cb_procedures[] = {
335 337
336static struct rpc_version nfs_cb_version4 = { 338static struct rpc_version nfs_cb_version4 = {
337 .number = 1, 339 .number = 1,
338 .nrprocs = sizeof(nfs4_cb_procedures)/sizeof(nfs4_cb_procedures[0]), 340 .nrprocs = ARRAY_SIZE(nfs4_cb_procedures),
339 .procs = nfs4_cb_procedures 341 .procs = nfs4_cb_procedures
340}; 342};
341 343
@@ -411,7 +413,7 @@ nfsd4_probe_callback(struct nfs4_client *clp)
411 /* Initialize rpc_program */ 413 /* Initialize rpc_program */
412 program->name = "nfs4_cb"; 414 program->name = "nfs4_cb";
413 program->number = cb->cb_prog; 415 program->number = cb->cb_prog;
414 program->nrvers = sizeof(nfs_cb_version)/sizeof(nfs_cb_version[0]); 416 program->nrvers = ARRAY_SIZE(nfs_cb_version);
415 program->version = nfs_cb_version; 417 program->version = nfs_cb_version;
416 program->stats = stat; 418 program->stats = stat;
417 419