diff options
Diffstat (limited to 'fs/nfsd')
-rw-r--r-- | fs/nfsd/nfs4proc.c | 82 | ||||
-rw-r--r-- | fs/nfsd/nfs4recover.c | 14 | ||||
-rw-r--r-- | fs/nfsd/nfs4state.c | 96 | ||||
-rw-r--r-- | fs/nfsd/nfs4xdr.c | 150 |
4 files changed, 171 insertions, 171 deletions
diff --git a/fs/nfsd/nfs4proc.c b/fs/nfsd/nfs4proc.c index ca6414248527..63823945f972 100644 --- a/fs/nfsd/nfs4proc.c +++ b/fs/nfsd/nfs4proc.c | |||
@@ -67,10 +67,10 @@ fh_dup2(struct svc_fh *dst, struct svc_fh *src) | |||
67 | *dst = *src; | 67 | *dst = *src; |
68 | } | 68 | } |
69 | 69 | ||
70 | static int | 70 | static __be32 |
71 | do_open_permission(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open, int accmode) | 71 | do_open_permission(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open, int accmode) |
72 | { | 72 | { |
73 | int status; | 73 | __be32 status; |
74 | 74 | ||
75 | if (open->op_truncate && | 75 | if (open->op_truncate && |
76 | !(open->op_share_access & NFS4_SHARE_ACCESS_WRITE)) | 76 | !(open->op_share_access & NFS4_SHARE_ACCESS_WRITE)) |
@@ -88,11 +88,11 @@ do_open_permission(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfs | |||
88 | return status; | 88 | return status; |
89 | } | 89 | } |
90 | 90 | ||
91 | static int | 91 | static __be32 |
92 | do_open_lookup(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open) | 92 | do_open_lookup(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open) |
93 | { | 93 | { |
94 | struct svc_fh resfh; | 94 | struct svc_fh resfh; |
95 | int status; | 95 | __be32 status; |
96 | 96 | ||
97 | fh_init(&resfh, NFS4_FHSIZE); | 97 | fh_init(&resfh, NFS4_FHSIZE); |
98 | open->op_truncate = 0; | 98 | open->op_truncate = 0; |
@@ -131,10 +131,10 @@ do_open_lookup(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_o | |||
131 | return status; | 131 | return status; |
132 | } | 132 | } |
133 | 133 | ||
134 | static int | 134 | static __be32 |
135 | do_open_fhandle(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open) | 135 | do_open_fhandle(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open) |
136 | { | 136 | { |
137 | int status; | 137 | __be32 status; |
138 | 138 | ||
139 | /* Only reclaims from previously confirmed clients are valid */ | 139 | /* Only reclaims from previously confirmed clients are valid */ |
140 | if ((status = nfs4_check_open_reclaim(&open->op_clientid))) | 140 | if ((status = nfs4_check_open_reclaim(&open->op_clientid))) |
@@ -161,10 +161,10 @@ do_open_fhandle(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_ | |||
161 | } | 161 | } |
162 | 162 | ||
163 | 163 | ||
164 | static inline int | 164 | static inline __be32 |
165 | nfsd4_open(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open, struct nfs4_stateowner **replay_owner) | 165 | nfsd4_open(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open, struct nfs4_stateowner **replay_owner) |
166 | { | 166 | { |
167 | int status; | 167 | __be32 status; |
168 | dprintk("NFSD: nfsd4_open filename %.*s op_stateowner %p\n", | 168 | dprintk("NFSD: nfsd4_open filename %.*s op_stateowner %p\n", |
169 | (int)open->op_fname.len, open->op_fname.data, | 169 | (int)open->op_fname.len, open->op_fname.data, |
170 | open->op_stateowner); | 170 | open->op_stateowner); |
@@ -261,7 +261,7 @@ out: | |||
261 | /* | 261 | /* |
262 | * filehandle-manipulating ops. | 262 | * filehandle-manipulating ops. |
263 | */ | 263 | */ |
264 | static inline int | 264 | static inline __be32 |
265 | nfsd4_getfh(struct svc_fh *current_fh, struct svc_fh **getfh) | 265 | nfsd4_getfh(struct svc_fh *current_fh, struct svc_fh **getfh) |
266 | { | 266 | { |
267 | if (!current_fh->fh_dentry) | 267 | if (!current_fh->fh_dentry) |
@@ -271,7 +271,7 @@ nfsd4_getfh(struct svc_fh *current_fh, struct svc_fh **getfh) | |||
271 | return nfs_ok; | 271 | return nfs_ok; |
272 | } | 272 | } |
273 | 273 | ||
274 | static inline int | 274 | static inline __be32 |
275 | nfsd4_putfh(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_putfh *putfh) | 275 | nfsd4_putfh(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_putfh *putfh) |
276 | { | 276 | { |
277 | fh_put(current_fh); | 277 | fh_put(current_fh); |
@@ -280,10 +280,10 @@ nfsd4_putfh(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_putf | |||
280 | return fh_verify(rqstp, current_fh, 0, MAY_NOP); | 280 | return fh_verify(rqstp, current_fh, 0, MAY_NOP); |
281 | } | 281 | } |
282 | 282 | ||
283 | static inline int | 283 | static inline __be32 |
284 | nfsd4_putrootfh(struct svc_rqst *rqstp, struct svc_fh *current_fh) | 284 | nfsd4_putrootfh(struct svc_rqst *rqstp, struct svc_fh *current_fh) |
285 | { | 285 | { |
286 | int status; | 286 | __be32 status; |
287 | 287 | ||
288 | fh_put(current_fh); | 288 | fh_put(current_fh); |
289 | status = exp_pseudoroot(rqstp->rq_client, current_fh, | 289 | status = exp_pseudoroot(rqstp->rq_client, current_fh, |
@@ -291,7 +291,7 @@ nfsd4_putrootfh(struct svc_rqst *rqstp, struct svc_fh *current_fh) | |||
291 | return status; | 291 | return status; |
292 | } | 292 | } |
293 | 293 | ||
294 | static inline int | 294 | static inline __be32 |
295 | nfsd4_restorefh(struct svc_fh *current_fh, struct svc_fh *save_fh) | 295 | nfsd4_restorefh(struct svc_fh *current_fh, struct svc_fh *save_fh) |
296 | { | 296 | { |
297 | if (!save_fh->fh_dentry) | 297 | if (!save_fh->fh_dentry) |
@@ -301,7 +301,7 @@ nfsd4_restorefh(struct svc_fh *current_fh, struct svc_fh *save_fh) | |||
301 | return nfs_ok; | 301 | return nfs_ok; |
302 | } | 302 | } |
303 | 303 | ||
304 | static inline int | 304 | static inline __be32 |
305 | nfsd4_savefh(struct svc_fh *current_fh, struct svc_fh *save_fh) | 305 | nfsd4_savefh(struct svc_fh *current_fh, struct svc_fh *save_fh) |
306 | { | 306 | { |
307 | if (!current_fh->fh_dentry) | 307 | if (!current_fh->fh_dentry) |
@@ -314,7 +314,7 @@ nfsd4_savefh(struct svc_fh *current_fh, struct svc_fh *save_fh) | |||
314 | /* | 314 | /* |
315 | * misc nfsv4 ops | 315 | * misc nfsv4 ops |
316 | */ | 316 | */ |
317 | static inline int | 317 | static inline __be32 |
318 | nfsd4_access(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_access *access) | 318 | nfsd4_access(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_access *access) |
319 | { | 319 | { |
320 | if (access->ac_req_access & ~NFS3_ACCESS_FULL) | 320 | if (access->ac_req_access & ~NFS3_ACCESS_FULL) |
@@ -324,10 +324,10 @@ nfsd4_access(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_acc | |||
324 | return nfsd_access(rqstp, current_fh, &access->ac_resp_access, &access->ac_supported); | 324 | return nfsd_access(rqstp, current_fh, &access->ac_resp_access, &access->ac_supported); |
325 | } | 325 | } |
326 | 326 | ||
327 | static inline int | 327 | static inline __be32 |
328 | nfsd4_commit(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_commit *commit) | 328 | nfsd4_commit(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_commit *commit) |
329 | { | 329 | { |
330 | int status; | 330 | __be32 status; |
331 | 331 | ||
332 | u32 *p = (u32 *)commit->co_verf.data; | 332 | u32 *p = (u32 *)commit->co_verf.data; |
333 | *p++ = nfssvc_boot.tv_sec; | 333 | *p++ = nfssvc_boot.tv_sec; |
@@ -339,11 +339,11 @@ nfsd4_commit(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_com | |||
339 | return status; | 339 | return status; |
340 | } | 340 | } |
341 | 341 | ||
342 | static int | 342 | static __be32 |
343 | nfsd4_create(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_create *create) | 343 | nfsd4_create(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_create *create) |
344 | { | 344 | { |
345 | struct svc_fh resfh; | 345 | struct svc_fh resfh; |
346 | int status; | 346 | __be32 status; |
347 | dev_t rdev; | 347 | dev_t rdev; |
348 | 348 | ||
349 | fh_init(&resfh, NFS4_FHSIZE); | 349 | fh_init(&resfh, NFS4_FHSIZE); |
@@ -423,10 +423,10 @@ nfsd4_create(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_cre | |||
423 | return status; | 423 | return status; |
424 | } | 424 | } |
425 | 425 | ||
426 | static inline int | 426 | static inline __be32 |
427 | nfsd4_getattr(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_getattr *getattr) | 427 | nfsd4_getattr(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_getattr *getattr) |
428 | { | 428 | { |
429 | int status; | 429 | __be32 status; |
430 | 430 | ||
431 | status = fh_verify(rqstp, current_fh, 0, MAY_NOP); | 431 | status = fh_verify(rqstp, current_fh, 0, MAY_NOP); |
432 | if (status) | 432 | if (status) |
@@ -442,11 +442,11 @@ nfsd4_getattr(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_ge | |||
442 | return nfs_ok; | 442 | return nfs_ok; |
443 | } | 443 | } |
444 | 444 | ||
445 | static inline int | 445 | static inline __be32 |
446 | nfsd4_link(struct svc_rqst *rqstp, struct svc_fh *current_fh, | 446 | nfsd4_link(struct svc_rqst *rqstp, struct svc_fh *current_fh, |
447 | struct svc_fh *save_fh, struct nfsd4_link *link) | 447 | struct svc_fh *save_fh, struct nfsd4_link *link) |
448 | { | 448 | { |
449 | int status = nfserr_nofilehandle; | 449 | __be32 status = nfserr_nofilehandle; |
450 | 450 | ||
451 | if (!save_fh->fh_dentry) | 451 | if (!save_fh->fh_dentry) |
452 | return status; | 452 | return status; |
@@ -456,11 +456,11 @@ nfsd4_link(struct svc_rqst *rqstp, struct svc_fh *current_fh, | |||
456 | return status; | 456 | return status; |
457 | } | 457 | } |
458 | 458 | ||
459 | static int | 459 | static __be32 |
460 | nfsd4_lookupp(struct svc_rqst *rqstp, struct svc_fh *current_fh) | 460 | nfsd4_lookupp(struct svc_rqst *rqstp, struct svc_fh *current_fh) |
461 | { | 461 | { |
462 | struct svc_fh tmp_fh; | 462 | struct svc_fh tmp_fh; |
463 | int ret; | 463 | __be32 ret; |
464 | 464 | ||
465 | fh_init(&tmp_fh, NFS4_FHSIZE); | 465 | fh_init(&tmp_fh, NFS4_FHSIZE); |
466 | if((ret = exp_pseudoroot(rqstp->rq_client, &tmp_fh, | 466 | if((ret = exp_pseudoroot(rqstp->rq_client, &tmp_fh, |
@@ -474,16 +474,16 @@ nfsd4_lookupp(struct svc_rqst *rqstp, struct svc_fh *current_fh) | |||
474 | return nfsd_lookup(rqstp, current_fh, "..", 2, current_fh); | 474 | return nfsd_lookup(rqstp, current_fh, "..", 2, current_fh); |
475 | } | 475 | } |
476 | 476 | ||
477 | static inline int | 477 | static inline __be32 |
478 | nfsd4_lookup(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lookup *lookup) | 478 | nfsd4_lookup(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lookup *lookup) |
479 | { | 479 | { |
480 | return nfsd_lookup(rqstp, current_fh, lookup->lo_name, lookup->lo_len, current_fh); | 480 | return nfsd_lookup(rqstp, current_fh, lookup->lo_name, lookup->lo_len, current_fh); |
481 | } | 481 | } |
482 | 482 | ||
483 | static inline int | 483 | static inline __be32 |
484 | nfsd4_read(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_read *read) | 484 | nfsd4_read(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_read *read) |
485 | { | 485 | { |
486 | int status; | 486 | __be32 status; |
487 | 487 | ||
488 | /* no need to check permission - this will be done in nfsd_read() */ | 488 | /* no need to check permission - this will be done in nfsd_read() */ |
489 | 489 | ||
@@ -508,7 +508,7 @@ out: | |||
508 | return status; | 508 | return status; |
509 | } | 509 | } |
510 | 510 | ||
511 | static inline int | 511 | static inline __be32 |
512 | nfsd4_readdir(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_readdir *readdir) | 512 | nfsd4_readdir(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_readdir *readdir) |
513 | { | 513 | { |
514 | u64 cookie = readdir->rd_cookie; | 514 | u64 cookie = readdir->rd_cookie; |
@@ -531,7 +531,7 @@ nfsd4_readdir(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_re | |||
531 | return nfs_ok; | 531 | return nfs_ok; |
532 | } | 532 | } |
533 | 533 | ||
534 | static inline int | 534 | static inline __be32 |
535 | nfsd4_readlink(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_readlink *readlink) | 535 | nfsd4_readlink(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_readlink *readlink) |
536 | { | 536 | { |
537 | readlink->rl_rqstp = rqstp; | 537 | readlink->rl_rqstp = rqstp; |
@@ -539,10 +539,10 @@ nfsd4_readlink(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_r | |||
539 | return nfs_ok; | 539 | return nfs_ok; |
540 | } | 540 | } |
541 | 541 | ||
542 | static inline int | 542 | static inline __be32 |
543 | nfsd4_remove(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_remove *remove) | 543 | nfsd4_remove(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_remove *remove) |
544 | { | 544 | { |
545 | int status; | 545 | __be32 status; |
546 | 546 | ||
547 | if (nfs4_in_grace()) | 547 | if (nfs4_in_grace()) |
548 | return nfserr_grace; | 548 | return nfserr_grace; |
@@ -556,11 +556,11 @@ nfsd4_remove(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_rem | |||
556 | return status; | 556 | return status; |
557 | } | 557 | } |
558 | 558 | ||
559 | static inline int | 559 | static inline __be32 |
560 | nfsd4_rename(struct svc_rqst *rqstp, struct svc_fh *current_fh, | 560 | nfsd4_rename(struct svc_rqst *rqstp, struct svc_fh *current_fh, |
561 | struct svc_fh *save_fh, struct nfsd4_rename *rename) | 561 | struct svc_fh *save_fh, struct nfsd4_rename *rename) |
562 | { | 562 | { |
563 | int status = nfserr_nofilehandle; | 563 | __be32 status = nfserr_nofilehandle; |
564 | 564 | ||
565 | if (!save_fh->fh_dentry) | 565 | if (!save_fh->fh_dentry) |
566 | return status; | 566 | return status; |
@@ -589,10 +589,10 @@ nfsd4_rename(struct svc_rqst *rqstp, struct svc_fh *current_fh, | |||
589 | return status; | 589 | return status; |
590 | } | 590 | } |
591 | 591 | ||
592 | static inline int | 592 | static inline __be32 |
593 | nfsd4_setattr(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_setattr *setattr) | 593 | nfsd4_setattr(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_setattr *setattr) |
594 | { | 594 | { |
595 | int status = nfs_ok; | 595 | __be32 status = nfs_ok; |
596 | 596 | ||
597 | if (setattr->sa_iattr.ia_valid & ATTR_SIZE) { | 597 | if (setattr->sa_iattr.ia_valid & ATTR_SIZE) { |
598 | nfs4_lock_state(); | 598 | nfs4_lock_state(); |
@@ -614,13 +614,13 @@ nfsd4_setattr(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_se | |||
614 | return status; | 614 | return status; |
615 | } | 615 | } |
616 | 616 | ||
617 | static inline int | 617 | static inline __be32 |
618 | nfsd4_write(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_write *write) | 618 | nfsd4_write(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_write *write) |
619 | { | 619 | { |
620 | stateid_t *stateid = &write->wr_stateid; | 620 | stateid_t *stateid = &write->wr_stateid; |
621 | struct file *filp = NULL; | 621 | struct file *filp = NULL; |
622 | u32 *p; | 622 | u32 *p; |
623 | int status = nfs_ok; | 623 | __be32 status = nfs_ok; |
624 | 624 | ||
625 | /* no need to check permission - this will be done in nfsd_write() */ | 625 | /* no need to check permission - this will be done in nfsd_write() */ |
626 | 626 | ||
@@ -661,12 +661,12 @@ nfsd4_write(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_writ | |||
661 | * attributes matched. VERIFY is implemented by mapping NFSERR_SAME | 661 | * attributes matched. VERIFY is implemented by mapping NFSERR_SAME |
662 | * to NFS_OK after the call; NVERIFY by mapping NFSERR_NOT_SAME to NFS_OK. | 662 | * to NFS_OK after the call; NVERIFY by mapping NFSERR_NOT_SAME to NFS_OK. |
663 | */ | 663 | */ |
664 | static int | 664 | static __be32 |
665 | nfsd4_verify(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_verify *verify) | 665 | nfsd4_verify(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_verify *verify) |
666 | { | 666 | { |
667 | __be32 *buf, *p; | 667 | __be32 *buf, *p; |
668 | int count; | 668 | int count; |
669 | int status; | 669 | __be32 status; |
670 | 670 | ||
671 | status = fh_verify(rqstp, current_fh, 0, MAY_NOP); | 671 | status = fh_verify(rqstp, current_fh, 0, MAY_NOP); |
672 | if (status) | 672 | if (status) |
@@ -741,7 +741,7 @@ nfsd4_proc_compound(struct svc_rqst *rqstp, | |||
741 | struct svc_fh *save_fh = NULL; | 741 | struct svc_fh *save_fh = NULL; |
742 | struct nfs4_stateowner *replay_owner = NULL; | 742 | struct nfs4_stateowner *replay_owner = NULL; |
743 | int slack_space; /* in words, not bytes! */ | 743 | int slack_space; /* in words, not bytes! */ |
744 | int status; | 744 | __be32 status; |
745 | 745 | ||
746 | status = nfserr_resource; | 746 | status = nfserr_resource; |
747 | current_fh = kmalloc(sizeof(*current_fh), GFP_KERNEL); | 747 | current_fh = kmalloc(sizeof(*current_fh), GFP_KERNEL); |
diff --git a/fs/nfsd/nfs4recover.c b/fs/nfsd/nfs4recover.c index 1cbd2e4ee122..e9d07704680e 100644 --- a/fs/nfsd/nfs4recover.c +++ b/fs/nfsd/nfs4recover.c | |||
@@ -83,13 +83,13 @@ md5_to_hex(char *out, char *md5) | |||
83 | *out = '\0'; | 83 | *out = '\0'; |
84 | } | 84 | } |
85 | 85 | ||
86 | int | 86 | __be32 |
87 | nfs4_make_rec_clidname(char *dname, struct xdr_netobj *clname) | 87 | nfs4_make_rec_clidname(char *dname, struct xdr_netobj *clname) |
88 | { | 88 | { |
89 | struct xdr_netobj cksum; | 89 | struct xdr_netobj cksum; |
90 | struct hash_desc desc; | 90 | struct hash_desc desc; |
91 | struct scatterlist sg[1]; | 91 | struct scatterlist sg[1]; |
92 | int status = nfserr_resource; | 92 | __be32 status = nfserr_resource; |
93 | 93 | ||
94 | dprintk("NFSD: nfs4_make_rec_clidname for %.*s\n", | 94 | dprintk("NFSD: nfs4_make_rec_clidname for %.*s\n", |
95 | clname->len, clname->data); | 95 | clname->len, clname->data); |
@@ -193,7 +193,7 @@ nfsd4_build_dentrylist(void *arg, const char *name, int namlen, | |||
193 | struct dentry_list *child; | 193 | struct dentry_list *child; |
194 | 194 | ||
195 | if (name && isdotent(name, namlen)) | 195 | if (name && isdotent(name, namlen)) |
196 | return nfs_ok; | 196 | return 0; |
197 | dentry = lookup_one_len(name, parent, namlen); | 197 | dentry = lookup_one_len(name, parent, namlen); |
198 | if (IS_ERR(dentry)) | 198 | if (IS_ERR(dentry)) |
199 | return PTR_ERR(dentry); | 199 | return PTR_ERR(dentry); |
@@ -333,14 +333,14 @@ purge_old(struct dentry *parent, struct dentry *child) | |||
333 | int status; | 333 | int status; |
334 | 334 | ||
335 | if (nfs4_has_reclaimed_state(child->d_name.name)) | 335 | if (nfs4_has_reclaimed_state(child->d_name.name)) |
336 | return nfs_ok; | 336 | return 0; |
337 | 337 | ||
338 | status = nfsd4_clear_clid_dir(parent, child); | 338 | status = nfsd4_clear_clid_dir(parent, child); |
339 | if (status) | 339 | if (status) |
340 | printk("failed to remove client recovery directory %s\n", | 340 | printk("failed to remove client recovery directory %s\n", |
341 | child->d_name.name); | 341 | child->d_name.name); |
342 | /* Keep trying, success or failure: */ | 342 | /* Keep trying, success or failure: */ |
343 | return nfs_ok; | 343 | return 0; |
344 | } | 344 | } |
345 | 345 | ||
346 | void | 346 | void |
@@ -365,10 +365,10 @@ load_recdir(struct dentry *parent, struct dentry *child) | |||
365 | printk("nfsd4: illegal name %s in recovery directory\n", | 365 | printk("nfsd4: illegal name %s in recovery directory\n", |
366 | child->d_name.name); | 366 | child->d_name.name); |
367 | /* Keep trying; maybe the others are OK: */ | 367 | /* Keep trying; maybe the others are OK: */ |
368 | return nfs_ok; | 368 | return 0; |
369 | } | 369 | } |
370 | nfs4_client_to_reclaim(child->d_name.name); | 370 | nfs4_client_to_reclaim(child->d_name.name); |
371 | return nfs_ok; | 371 | return 0; |
372 | } | 372 | } |
373 | 373 | ||
374 | int | 374 | int |
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index ebcf226a9e4a..e5ca6d7028df 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c | |||
@@ -710,7 +710,7 @@ out_err: | |||
710 | * as described above. | 710 | * as described above. |
711 | * | 711 | * |
712 | */ | 712 | */ |
713 | int | 713 | __be32 |
714 | nfsd4_setclientid(struct svc_rqst *rqstp, struct nfsd4_setclientid *setclid) | 714 | nfsd4_setclientid(struct svc_rqst *rqstp, struct nfsd4_setclientid *setclid) |
715 | { | 715 | { |
716 | u32 ip_addr = rqstp->rq_addr.sin_addr.s_addr; | 716 | u32 ip_addr = rqstp->rq_addr.sin_addr.s_addr; |
@@ -721,7 +721,7 @@ nfsd4_setclientid(struct svc_rqst *rqstp, struct nfsd4_setclientid *setclid) | |||
721 | nfs4_verifier clverifier = setclid->se_verf; | 721 | nfs4_verifier clverifier = setclid->se_verf; |
722 | unsigned int strhashval; | 722 | unsigned int strhashval; |
723 | struct nfs4_client *conf, *unconf, *new; | 723 | struct nfs4_client *conf, *unconf, *new; |
724 | int status; | 724 | __be32 status; |
725 | char dname[HEXDIR_LEN]; | 725 | char dname[HEXDIR_LEN]; |
726 | 726 | ||
727 | if (!check_name(clname)) | 727 | if (!check_name(clname)) |
@@ -875,14 +875,14 @@ out: | |||
875 | * | 875 | * |
876 | * NOTE: callback information will be processed here in a future patch | 876 | * NOTE: callback information will be processed here in a future patch |
877 | */ | 877 | */ |
878 | int | 878 | __be32 |
879 | nfsd4_setclientid_confirm(struct svc_rqst *rqstp, struct nfsd4_setclientid_confirm *setclientid_confirm) | 879 | nfsd4_setclientid_confirm(struct svc_rqst *rqstp, struct nfsd4_setclientid_confirm *setclientid_confirm) |
880 | { | 880 | { |
881 | u32 ip_addr = rqstp->rq_addr.sin_addr.s_addr; | 881 | u32 ip_addr = rqstp->rq_addr.sin_addr.s_addr; |
882 | struct nfs4_client *conf, *unconf; | 882 | struct nfs4_client *conf, *unconf; |
883 | nfs4_verifier confirm = setclientid_confirm->sc_confirm; | 883 | nfs4_verifier confirm = setclientid_confirm->sc_confirm; |
884 | clientid_t * clid = &setclientid_confirm->sc_clientid; | 884 | clientid_t * clid = &setclientid_confirm->sc_clientid; |
885 | int status; | 885 | __be32 status; |
886 | 886 | ||
887 | if (STALE_CLIENTID(clid)) | 887 | if (STALE_CLIENTID(clid)) |
888 | return nfserr_stale_clientid; | 888 | return nfserr_stale_clientid; |
@@ -1280,13 +1280,13 @@ test_share(struct nfs4_stateid *stp, struct nfsd4_open *open) { | |||
1280 | * Called to check deny when READ with all zero stateid or | 1280 | * Called to check deny when READ with all zero stateid or |
1281 | * WRITE with all zero or all one stateid | 1281 | * WRITE with all zero or all one stateid |
1282 | */ | 1282 | */ |
1283 | static int | 1283 | static __be32 |
1284 | nfs4_share_conflict(struct svc_fh *current_fh, unsigned int deny_type) | 1284 | nfs4_share_conflict(struct svc_fh *current_fh, unsigned int deny_type) |
1285 | { | 1285 | { |
1286 | struct inode *ino = current_fh->fh_dentry->d_inode; | 1286 | struct inode *ino = current_fh->fh_dentry->d_inode; |
1287 | struct nfs4_file *fp; | 1287 | struct nfs4_file *fp; |
1288 | struct nfs4_stateid *stp; | 1288 | struct nfs4_stateid *stp; |
1289 | int ret; | 1289 | __be32 ret; |
1290 | 1290 | ||
1291 | dprintk("NFSD: nfs4_share_conflict\n"); | 1291 | dprintk("NFSD: nfs4_share_conflict\n"); |
1292 | 1292 | ||
@@ -1444,7 +1444,7 @@ static struct lock_manager_operations nfsd_lease_mng_ops = { | |||
1444 | }; | 1444 | }; |
1445 | 1445 | ||
1446 | 1446 | ||
1447 | int | 1447 | __be32 |
1448 | nfsd4_process_open1(struct nfsd4_open *open) | 1448 | nfsd4_process_open1(struct nfsd4_open *open) |
1449 | { | 1449 | { |
1450 | clientid_t *clientid = &open->op_clientid; | 1450 | clientid_t *clientid = &open->op_clientid; |
@@ -1501,7 +1501,7 @@ renew: | |||
1501 | return nfs_ok; | 1501 | return nfs_ok; |
1502 | } | 1502 | } |
1503 | 1503 | ||
1504 | static inline int | 1504 | static inline __be32 |
1505 | nfs4_check_delegmode(struct nfs4_delegation *dp, int flags) | 1505 | nfs4_check_delegmode(struct nfs4_delegation *dp, int flags) |
1506 | { | 1506 | { |
1507 | if ((flags & WR_STATE) && (dp->dl_type == NFS4_OPEN_DELEGATE_READ)) | 1507 | if ((flags & WR_STATE) && (dp->dl_type == NFS4_OPEN_DELEGATE_READ)) |
@@ -1522,12 +1522,12 @@ find_delegation_file(struct nfs4_file *fp, stateid_t *stid) | |||
1522 | return NULL; | 1522 | return NULL; |
1523 | } | 1523 | } |
1524 | 1524 | ||
1525 | static int | 1525 | static __be32 |
1526 | nfs4_check_deleg(struct nfs4_file *fp, struct nfsd4_open *open, | 1526 | nfs4_check_deleg(struct nfs4_file *fp, struct nfsd4_open *open, |
1527 | struct nfs4_delegation **dp) | 1527 | struct nfs4_delegation **dp) |
1528 | { | 1528 | { |
1529 | int flags; | 1529 | int flags; |
1530 | int status = nfserr_bad_stateid; | 1530 | __be32 status = nfserr_bad_stateid; |
1531 | 1531 | ||
1532 | *dp = find_delegation_file(fp, &open->op_delegate_stateid); | 1532 | *dp = find_delegation_file(fp, &open->op_delegate_stateid); |
1533 | if (*dp == NULL) | 1533 | if (*dp == NULL) |
@@ -1546,11 +1546,11 @@ out: | |||
1546 | return nfs_ok; | 1546 | return nfs_ok; |
1547 | } | 1547 | } |
1548 | 1548 | ||
1549 | static int | 1549 | static __be32 |
1550 | nfs4_check_open(struct nfs4_file *fp, struct nfsd4_open *open, struct nfs4_stateid **stpp) | 1550 | nfs4_check_open(struct nfs4_file *fp, struct nfsd4_open *open, struct nfs4_stateid **stpp) |
1551 | { | 1551 | { |
1552 | struct nfs4_stateid *local; | 1552 | struct nfs4_stateid *local; |
1553 | int status = nfserr_share_denied; | 1553 | __be32 status = nfserr_share_denied; |
1554 | struct nfs4_stateowner *sop = open->op_stateowner; | 1554 | struct nfs4_stateowner *sop = open->op_stateowner; |
1555 | 1555 | ||
1556 | list_for_each_entry(local, &fp->fi_stateids, st_perfile) { | 1556 | list_for_each_entry(local, &fp->fi_stateids, st_perfile) { |
@@ -1575,7 +1575,7 @@ nfs4_alloc_stateid(void) | |||
1575 | return kmem_cache_alloc(stateid_slab, GFP_KERNEL); | 1575 | return kmem_cache_alloc(stateid_slab, GFP_KERNEL); |
1576 | } | 1576 | } |
1577 | 1577 | ||
1578 | static int | 1578 | static __be32 |
1579 | nfs4_new_open(struct svc_rqst *rqstp, struct nfs4_stateid **stpp, | 1579 | nfs4_new_open(struct svc_rqst *rqstp, struct nfs4_stateid **stpp, |
1580 | struct nfs4_delegation *dp, | 1580 | struct nfs4_delegation *dp, |
1581 | struct svc_fh *cur_fh, int flags) | 1581 | struct svc_fh *cur_fh, int flags) |
@@ -1590,7 +1590,7 @@ nfs4_new_open(struct svc_rqst *rqstp, struct nfs4_stateid **stpp, | |||
1590 | get_file(dp->dl_vfs_file); | 1590 | get_file(dp->dl_vfs_file); |
1591 | stp->st_vfs_file = dp->dl_vfs_file; | 1591 | stp->st_vfs_file = dp->dl_vfs_file; |
1592 | } else { | 1592 | } else { |
1593 | int status; | 1593 | __be32 status; |
1594 | status = nfsd_open(rqstp, cur_fh, S_IFREG, flags, | 1594 | status = nfsd_open(rqstp, cur_fh, S_IFREG, flags, |
1595 | &stp->st_vfs_file); | 1595 | &stp->st_vfs_file); |
1596 | if (status) { | 1596 | if (status) { |
@@ -1604,7 +1604,7 @@ nfs4_new_open(struct svc_rqst *rqstp, struct nfs4_stateid **stpp, | |||
1604 | return 0; | 1604 | return 0; |
1605 | } | 1605 | } |
1606 | 1606 | ||
1607 | static inline int | 1607 | static inline __be32 |
1608 | nfsd4_truncate(struct svc_rqst *rqstp, struct svc_fh *fh, | 1608 | nfsd4_truncate(struct svc_rqst *rqstp, struct svc_fh *fh, |
1609 | struct nfsd4_open *open) | 1609 | struct nfsd4_open *open) |
1610 | { | 1610 | { |
@@ -1619,22 +1619,22 @@ nfsd4_truncate(struct svc_rqst *rqstp, struct svc_fh *fh, | |||
1619 | return nfsd_setattr(rqstp, fh, &iattr, 0, (time_t)0); | 1619 | return nfsd_setattr(rqstp, fh, &iattr, 0, (time_t)0); |
1620 | } | 1620 | } |
1621 | 1621 | ||
1622 | static int | 1622 | static __be32 |
1623 | nfs4_upgrade_open(struct svc_rqst *rqstp, struct svc_fh *cur_fh, struct nfs4_stateid *stp, struct nfsd4_open *open) | 1623 | nfs4_upgrade_open(struct svc_rqst *rqstp, struct svc_fh *cur_fh, struct nfs4_stateid *stp, struct nfsd4_open *open) |
1624 | { | 1624 | { |
1625 | struct file *filp = stp->st_vfs_file; | 1625 | struct file *filp = stp->st_vfs_file; |
1626 | struct inode *inode = filp->f_dentry->d_inode; | 1626 | struct inode *inode = filp->f_dentry->d_inode; |
1627 | unsigned int share_access, new_writer; | 1627 | unsigned int share_access, new_writer; |
1628 | int status; | 1628 | __be32 status; |
1629 | 1629 | ||
1630 | set_access(&share_access, stp->st_access_bmap); | 1630 | set_access(&share_access, stp->st_access_bmap); |
1631 | new_writer = (~share_access) & open->op_share_access | 1631 | new_writer = (~share_access) & open->op_share_access |
1632 | & NFS4_SHARE_ACCESS_WRITE; | 1632 | & NFS4_SHARE_ACCESS_WRITE; |
1633 | 1633 | ||
1634 | if (new_writer) { | 1634 | if (new_writer) { |
1635 | status = get_write_access(inode); | 1635 | int err = get_write_access(inode); |
1636 | if (status) | 1636 | if (err) |
1637 | return nfserrno(status); | 1637 | return nfserrno(err); |
1638 | } | 1638 | } |
1639 | status = nfsd4_truncate(rqstp, cur_fh, open); | 1639 | status = nfsd4_truncate(rqstp, cur_fh, open); |
1640 | if (status) { | 1640 | if (status) { |
@@ -1738,14 +1738,14 @@ out: | |||
1738 | /* | 1738 | /* |
1739 | * called with nfs4_lock_state() held. | 1739 | * called with nfs4_lock_state() held. |
1740 | */ | 1740 | */ |
1741 | int | 1741 | __be32 |
1742 | nfsd4_process_open2(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open) | 1742 | nfsd4_process_open2(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open) |
1743 | { | 1743 | { |
1744 | struct nfs4_file *fp = NULL; | 1744 | struct nfs4_file *fp = NULL; |
1745 | struct inode *ino = current_fh->fh_dentry->d_inode; | 1745 | struct inode *ino = current_fh->fh_dentry->d_inode; |
1746 | struct nfs4_stateid *stp = NULL; | 1746 | struct nfs4_stateid *stp = NULL; |
1747 | struct nfs4_delegation *dp = NULL; | 1747 | struct nfs4_delegation *dp = NULL; |
1748 | int status; | 1748 | __be32 status; |
1749 | 1749 | ||
1750 | status = nfserr_inval; | 1750 | status = nfserr_inval; |
1751 | if (!access_valid(open->op_share_access) | 1751 | if (!access_valid(open->op_share_access) |
@@ -1833,11 +1833,11 @@ static struct work_struct laundromat_work; | |||
1833 | static void laundromat_main(void *); | 1833 | static void laundromat_main(void *); |
1834 | static DECLARE_WORK(laundromat_work, laundromat_main, NULL); | 1834 | static DECLARE_WORK(laundromat_work, laundromat_main, NULL); |
1835 | 1835 | ||
1836 | int | 1836 | __be32 |
1837 | nfsd4_renew(clientid_t *clid) | 1837 | nfsd4_renew(clientid_t *clid) |
1838 | { | 1838 | { |
1839 | struct nfs4_client *clp; | 1839 | struct nfs4_client *clp; |
1840 | int status; | 1840 | __be32 status; |
1841 | 1841 | ||
1842 | nfs4_lock_state(); | 1842 | nfs4_lock_state(); |
1843 | dprintk("process_renew(%08x/%08x): starting\n", | 1843 | dprintk("process_renew(%08x/%08x): starting\n", |
@@ -1996,9 +1996,9 @@ access_permit_write(unsigned long access_bmap) | |||
1996 | } | 1996 | } |
1997 | 1997 | ||
1998 | static | 1998 | static |
1999 | int nfs4_check_openmode(struct nfs4_stateid *stp, int flags) | 1999 | __be32 nfs4_check_openmode(struct nfs4_stateid *stp, int flags) |
2000 | { | 2000 | { |
2001 | int status = nfserr_openmode; | 2001 | __be32 status = nfserr_openmode; |
2002 | 2002 | ||
2003 | if ((flags & WR_STATE) && (!access_permit_write(stp->st_access_bmap))) | 2003 | if ((flags & WR_STATE) && (!access_permit_write(stp->st_access_bmap))) |
2004 | goto out; | 2004 | goto out; |
@@ -2009,7 +2009,7 @@ out: | |||
2009 | return status; | 2009 | return status; |
2010 | } | 2010 | } |
2011 | 2011 | ||
2012 | static inline int | 2012 | static inline __be32 |
2013 | check_special_stateids(svc_fh *current_fh, stateid_t *stateid, int flags) | 2013 | check_special_stateids(svc_fh *current_fh, stateid_t *stateid, int flags) |
2014 | { | 2014 | { |
2015 | /* Trying to call delegreturn with a special stateid? Yuch: */ | 2015 | /* Trying to call delegreturn with a special stateid? Yuch: */ |
@@ -2043,14 +2043,14 @@ io_during_grace_disallowed(struct inode *inode, int flags) | |||
2043 | /* | 2043 | /* |
2044 | * Checks for stateid operations | 2044 | * Checks for stateid operations |
2045 | */ | 2045 | */ |
2046 | int | 2046 | __be32 |
2047 | nfs4_preprocess_stateid_op(struct svc_fh *current_fh, stateid_t *stateid, int flags, struct file **filpp) | 2047 | nfs4_preprocess_stateid_op(struct svc_fh *current_fh, stateid_t *stateid, int flags, struct file **filpp) |
2048 | { | 2048 | { |
2049 | struct nfs4_stateid *stp = NULL; | 2049 | struct nfs4_stateid *stp = NULL; |
2050 | struct nfs4_delegation *dp = NULL; | 2050 | struct nfs4_delegation *dp = NULL; |
2051 | stateid_t *stidp; | 2051 | stateid_t *stidp; |
2052 | struct inode *ino = current_fh->fh_dentry->d_inode; | 2052 | struct inode *ino = current_fh->fh_dentry->d_inode; |
2053 | int status; | 2053 | __be32 status; |
2054 | 2054 | ||
2055 | dprintk("NFSD: preprocess_stateid_op: stateid = (%08x/%08x/%08x/%08x)\n", | 2055 | dprintk("NFSD: preprocess_stateid_op: stateid = (%08x/%08x/%08x/%08x)\n", |
2056 | stateid->si_boot, stateid->si_stateownerid, | 2056 | stateid->si_boot, stateid->si_stateownerid, |
@@ -2125,7 +2125,7 @@ setlkflg (int type) | |||
2125 | /* | 2125 | /* |
2126 | * Checks for sequence id mutating operations. | 2126 | * Checks for sequence id mutating operations. |
2127 | */ | 2127 | */ |
2128 | static int | 2128 | static __be32 |
2129 | nfs4_preprocess_seqid_op(struct svc_fh *current_fh, u32 seqid, stateid_t *stateid, int flags, struct nfs4_stateowner **sopp, struct nfs4_stateid **stpp, struct nfsd4_lock *lock) | 2129 | nfs4_preprocess_seqid_op(struct svc_fh *current_fh, u32 seqid, stateid_t *stateid, int flags, struct nfs4_stateowner **sopp, struct nfs4_stateid **stpp, struct nfsd4_lock *lock) |
2130 | { | 2130 | { |
2131 | struct nfs4_stateid *stp; | 2131 | struct nfs4_stateid *stp; |
@@ -2169,7 +2169,7 @@ nfs4_preprocess_seqid_op(struct svc_fh *current_fh, u32 seqid, stateid_t *statei | |||
2169 | clientid_t *lockclid = &lock->v.new.clientid; | 2169 | clientid_t *lockclid = &lock->v.new.clientid; |
2170 | struct nfs4_client *clp = sop->so_client; | 2170 | struct nfs4_client *clp = sop->so_client; |
2171 | int lkflg = 0; | 2171 | int lkflg = 0; |
2172 | int status; | 2172 | __be32 status; |
2173 | 2173 | ||
2174 | lkflg = setlkflg(lock->lk_type); | 2174 | lkflg = setlkflg(lock->lk_type); |
2175 | 2175 | ||
@@ -2241,10 +2241,10 @@ check_replay: | |||
2241 | return nfserr_bad_seqid; | 2241 | return nfserr_bad_seqid; |
2242 | } | 2242 | } |
2243 | 2243 | ||
2244 | int | 2244 | __be32 |
2245 | nfsd4_open_confirm(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open_confirm *oc, struct nfs4_stateowner **replay_owner) | 2245 | nfsd4_open_confirm(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open_confirm *oc, struct nfs4_stateowner **replay_owner) |
2246 | { | 2246 | { |
2247 | int status; | 2247 | __be32 status; |
2248 | struct nfs4_stateowner *sop; | 2248 | struct nfs4_stateowner *sop; |
2249 | struct nfs4_stateid *stp; | 2249 | struct nfs4_stateid *stp; |
2250 | 2250 | ||
@@ -2310,10 +2310,10 @@ reset_union_bmap_deny(unsigned long deny, unsigned long *bmap) | |||
2310 | } | 2310 | } |
2311 | } | 2311 | } |
2312 | 2312 | ||
2313 | int | 2313 | __be32 |
2314 | nfsd4_open_downgrade(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open_downgrade *od, struct nfs4_stateowner **replay_owner) | 2314 | nfsd4_open_downgrade(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open_downgrade *od, struct nfs4_stateowner **replay_owner) |
2315 | { | 2315 | { |
2316 | int status; | 2316 | __be32 status; |
2317 | struct nfs4_stateid *stp; | 2317 | struct nfs4_stateid *stp; |
2318 | unsigned int share_access; | 2318 | unsigned int share_access; |
2319 | 2319 | ||
@@ -2365,10 +2365,10 @@ out: | |||
2365 | /* | 2365 | /* |
2366 | * nfs4_unlock_state() called after encode | 2366 | * nfs4_unlock_state() called after encode |
2367 | */ | 2367 | */ |
2368 | int | 2368 | __be32 |
2369 | nfsd4_close(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_close *close, struct nfs4_stateowner **replay_owner) | 2369 | nfsd4_close(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_close *close, struct nfs4_stateowner **replay_owner) |
2370 | { | 2370 | { |
2371 | int status; | 2371 | __be32 status; |
2372 | struct nfs4_stateid *stp; | 2372 | struct nfs4_stateid *stp; |
2373 | 2373 | ||
2374 | dprintk("NFSD: nfsd4_close on file %.*s\n", | 2374 | dprintk("NFSD: nfsd4_close on file %.*s\n", |
@@ -2404,10 +2404,10 @@ out: | |||
2404 | return status; | 2404 | return status; |
2405 | } | 2405 | } |
2406 | 2406 | ||
2407 | int | 2407 | __be32 |
2408 | nfsd4_delegreturn(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_delegreturn *dr) | 2408 | nfsd4_delegreturn(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_delegreturn *dr) |
2409 | { | 2409 | { |
2410 | int status; | 2410 | __be32 status; |
2411 | 2411 | ||
2412 | if ((status = fh_verify(rqstp, current_fh, S_IFREG, 0))) | 2412 | if ((status = fh_verify(rqstp, current_fh, S_IFREG, 0))) |
2413 | goto out; | 2413 | goto out; |
@@ -2635,7 +2635,7 @@ check_lock_length(u64 offset, u64 length) | |||
2635 | /* | 2635 | /* |
2636 | * LOCK operation | 2636 | * LOCK operation |
2637 | */ | 2637 | */ |
2638 | int | 2638 | __be32 |
2639 | nfsd4_lock(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lock *lock, struct nfs4_stateowner **replay_owner) | 2639 | nfsd4_lock(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lock *lock, struct nfs4_stateowner **replay_owner) |
2640 | { | 2640 | { |
2641 | struct nfs4_stateowner *open_sop = NULL; | 2641 | struct nfs4_stateowner *open_sop = NULL; |
@@ -2644,7 +2644,7 @@ nfsd4_lock(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lock | |||
2644 | struct file *filp; | 2644 | struct file *filp; |
2645 | struct file_lock file_lock; | 2645 | struct file_lock file_lock; |
2646 | struct file_lock conflock; | 2646 | struct file_lock conflock; |
2647 | int status = 0; | 2647 | __be32 status = 0; |
2648 | unsigned int strhashval; | 2648 | unsigned int strhashval; |
2649 | 2649 | ||
2650 | dprintk("NFSD: nfsd4_lock: start=%Ld length=%Ld\n", | 2650 | dprintk("NFSD: nfsd4_lock: start=%Ld length=%Ld\n", |
@@ -2793,14 +2793,14 @@ out: | |||
2793 | /* | 2793 | /* |
2794 | * LOCKT operation | 2794 | * LOCKT operation |
2795 | */ | 2795 | */ |
2796 | int | 2796 | __be32 |
2797 | nfsd4_lockt(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lockt *lockt) | 2797 | nfsd4_lockt(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_lockt *lockt) |
2798 | { | 2798 | { |
2799 | struct inode *inode; | 2799 | struct inode *inode; |
2800 | struct file file; | 2800 | struct file file; |
2801 | struct file_lock file_lock; | 2801 | struct file_lock file_lock; |
2802 | struct file_lock conflock; | 2802 | struct file_lock conflock; |
2803 | int status; | 2803 | __be32 status; |
2804 | 2804 | ||
2805 | if (nfs4_in_grace()) | 2805 | if (nfs4_in_grace()) |
2806 | return nfserr_grace; | 2806 | return nfserr_grace; |
@@ -2873,13 +2873,13 @@ out: | |||
2873 | return status; | 2873 | return status; |
2874 | } | 2874 | } |
2875 | 2875 | ||
2876 | int | 2876 | __be32 |
2877 | nfsd4_locku(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_locku *locku, struct nfs4_stateowner **replay_owner) | 2877 | nfsd4_locku(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_locku *locku, struct nfs4_stateowner **replay_owner) |
2878 | { | 2878 | { |
2879 | struct nfs4_stateid *stp; | 2879 | struct nfs4_stateid *stp; |
2880 | struct file *filp = NULL; | 2880 | struct file *filp = NULL; |
2881 | struct file_lock file_lock; | 2881 | struct file_lock file_lock; |
2882 | int status; | 2882 | __be32 status; |
2883 | 2883 | ||
2884 | dprintk("NFSD: nfsd4_locku: start=%Ld length=%Ld\n", | 2884 | dprintk("NFSD: nfsd4_locku: start=%Ld length=%Ld\n", |
2885 | (long long) locku->lu_offset, | 2885 | (long long) locku->lu_offset, |
@@ -2965,7 +2965,7 @@ out: | |||
2965 | return status; | 2965 | return status; |
2966 | } | 2966 | } |
2967 | 2967 | ||
2968 | int | 2968 | __be32 |
2969 | nfsd4_release_lockowner(struct svc_rqst *rqstp, struct nfsd4_release_lockowner *rlockowner) | 2969 | nfsd4_release_lockowner(struct svc_rqst *rqstp, struct nfsd4_release_lockowner *rlockowner) |
2970 | { | 2970 | { |
2971 | clientid_t *clid = &rlockowner->rl_clientid; | 2971 | clientid_t *clid = &rlockowner->rl_clientid; |
@@ -2974,7 +2974,7 @@ nfsd4_release_lockowner(struct svc_rqst *rqstp, struct nfsd4_release_lockowner * | |||
2974 | struct xdr_netobj *owner = &rlockowner->rl_owner; | 2974 | struct xdr_netobj *owner = &rlockowner->rl_owner; |
2975 | struct list_head matches; | 2975 | struct list_head matches; |
2976 | int i; | 2976 | int i; |
2977 | int status; | 2977 | __be32 status; |
2978 | 2978 | ||
2979 | dprintk("nfsd4_release_lockowner clientid: (%08x/%08x):\n", | 2979 | dprintk("nfsd4_release_lockowner clientid: (%08x/%08x):\n", |
2980 | clid->cl_boot, clid->cl_id); | 2980 | clid->cl_boot, clid->cl_id); |
@@ -3111,7 +3111,7 @@ nfs4_find_reclaim_client(clientid_t *clid) | |||
3111 | /* | 3111 | /* |
3112 | * Called from OPEN. Look for clientid in reclaim list. | 3112 | * Called from OPEN. Look for clientid in reclaim list. |
3113 | */ | 3113 | */ |
3114 | int | 3114 | __be32 |
3115 | nfs4_check_open_reclaim(clientid_t *clid) | 3115 | nfs4_check_open_reclaim(clientid_t *clid) |
3116 | { | 3116 | { |
3117 | return nfs4_find_reclaim_client(clid) ? nfs_ok : nfserr_reclaim_bad; | 3117 | return nfs4_find_reclaim_client(clid) ? nfs_ok : nfserr_reclaim_bad; |
diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c index 3419d99aeb1a..d7b630f1a9ae 100644 --- a/fs/nfsd/nfs4xdr.c +++ b/fs/nfsd/nfs4xdr.c | |||
@@ -68,8 +68,8 @@ | |||
68 | #define NFS4_REFERRAL_FSID_MAJOR 0x8000000ULL | 68 | #define NFS4_REFERRAL_FSID_MAJOR 0x8000000ULL |
69 | #define NFS4_REFERRAL_FSID_MINOR 0x8000000ULL | 69 | #define NFS4_REFERRAL_FSID_MINOR 0x8000000ULL |
70 | 70 | ||
71 | static int | 71 | static __be32 |
72 | check_filename(char *str, int len, int err) | 72 | check_filename(char *str, int len, __be32 err) |
73 | { | 73 | { |
74 | int i; | 74 | int i; |
75 | 75 | ||
@@ -95,7 +95,7 @@ check_filename(char *str, int len, int err) | |||
95 | */ | 95 | */ |
96 | #define DECODE_HEAD \ | 96 | #define DECODE_HEAD \ |
97 | __be32 *p; \ | 97 | __be32 *p; \ |
98 | int status | 98 | __be32 status |
99 | #define DECODE_TAIL \ | 99 | #define DECODE_TAIL \ |
100 | status = 0; \ | 100 | status = 0; \ |
101 | out: \ | 101 | out: \ |
@@ -217,7 +217,7 @@ static char *savemem(struct nfsd4_compoundargs *argp, __be32 *p, int nbytes) | |||
217 | } | 217 | } |
218 | 218 | ||
219 | 219 | ||
220 | static int | 220 | static __be32 |
221 | nfsd4_decode_bitmap(struct nfsd4_compoundargs *argp, u32 *bmval) | 221 | nfsd4_decode_bitmap(struct nfsd4_compoundargs *argp, u32 *bmval) |
222 | { | 222 | { |
223 | u32 bmlen; | 223 | u32 bmlen; |
@@ -240,7 +240,7 @@ nfsd4_decode_bitmap(struct nfsd4_compoundargs *argp, u32 *bmval) | |||
240 | DECODE_TAIL; | 240 | DECODE_TAIL; |
241 | } | 241 | } |
242 | 242 | ||
243 | static int | 243 | static __be32 |
244 | nfsd4_decode_fattr(struct nfsd4_compoundargs *argp, u32 *bmval, struct iattr *iattr, | 244 | nfsd4_decode_fattr(struct nfsd4_compoundargs *argp, u32 *bmval, struct iattr *iattr, |
245 | struct nfs4_acl **acl) | 245 | struct nfs4_acl **acl) |
246 | { | 246 | { |
@@ -418,7 +418,7 @@ out_nfserr: | |||
418 | goto out; | 418 | goto out; |
419 | } | 419 | } |
420 | 420 | ||
421 | static int | 421 | static __be32 |
422 | nfsd4_decode_access(struct nfsd4_compoundargs *argp, struct nfsd4_access *access) | 422 | nfsd4_decode_access(struct nfsd4_compoundargs *argp, struct nfsd4_access *access) |
423 | { | 423 | { |
424 | DECODE_HEAD; | 424 | DECODE_HEAD; |
@@ -429,7 +429,7 @@ nfsd4_decode_access(struct nfsd4_compoundargs *argp, struct nfsd4_access *access | |||
429 | DECODE_TAIL; | 429 | DECODE_TAIL; |
430 | } | 430 | } |
431 | 431 | ||
432 | static int | 432 | static __be32 |
433 | nfsd4_decode_close(struct nfsd4_compoundargs *argp, struct nfsd4_close *close) | 433 | nfsd4_decode_close(struct nfsd4_compoundargs *argp, struct nfsd4_close *close) |
434 | { | 434 | { |
435 | DECODE_HEAD; | 435 | DECODE_HEAD; |
@@ -444,7 +444,7 @@ nfsd4_decode_close(struct nfsd4_compoundargs *argp, struct nfsd4_close *close) | |||
444 | } | 444 | } |
445 | 445 | ||
446 | 446 | ||
447 | static int | 447 | static __be32 |
448 | nfsd4_decode_commit(struct nfsd4_compoundargs *argp, struct nfsd4_commit *commit) | 448 | nfsd4_decode_commit(struct nfsd4_compoundargs *argp, struct nfsd4_commit *commit) |
449 | { | 449 | { |
450 | DECODE_HEAD; | 450 | DECODE_HEAD; |
@@ -456,7 +456,7 @@ nfsd4_decode_commit(struct nfsd4_compoundargs *argp, struct nfsd4_commit *commit | |||
456 | DECODE_TAIL; | 456 | DECODE_TAIL; |
457 | } | 457 | } |
458 | 458 | ||
459 | static int | 459 | static __be32 |
460 | nfsd4_decode_create(struct nfsd4_compoundargs *argp, struct nfsd4_create *create) | 460 | nfsd4_decode_create(struct nfsd4_compoundargs *argp, struct nfsd4_create *create) |
461 | { | 461 | { |
462 | DECODE_HEAD; | 462 | DECODE_HEAD; |
@@ -496,7 +496,7 @@ nfsd4_decode_create(struct nfsd4_compoundargs *argp, struct nfsd4_create *create | |||
496 | DECODE_TAIL; | 496 | DECODE_TAIL; |
497 | } | 497 | } |
498 | 498 | ||
499 | static inline int | 499 | static inline __be32 |
500 | nfsd4_decode_delegreturn(struct nfsd4_compoundargs *argp, struct nfsd4_delegreturn *dr) | 500 | nfsd4_decode_delegreturn(struct nfsd4_compoundargs *argp, struct nfsd4_delegreturn *dr) |
501 | { | 501 | { |
502 | DECODE_HEAD; | 502 | DECODE_HEAD; |
@@ -508,13 +508,13 @@ nfsd4_decode_delegreturn(struct nfsd4_compoundargs *argp, struct nfsd4_delegretu | |||
508 | DECODE_TAIL; | 508 | DECODE_TAIL; |
509 | } | 509 | } |
510 | 510 | ||
511 | static inline int | 511 | static inline __be32 |
512 | nfsd4_decode_getattr(struct nfsd4_compoundargs *argp, struct nfsd4_getattr *getattr) | 512 | nfsd4_decode_getattr(struct nfsd4_compoundargs *argp, struct nfsd4_getattr *getattr) |
513 | { | 513 | { |
514 | return nfsd4_decode_bitmap(argp, getattr->ga_bmval); | 514 | return nfsd4_decode_bitmap(argp, getattr->ga_bmval); |
515 | } | 515 | } |
516 | 516 | ||
517 | static int | 517 | static __be32 |
518 | nfsd4_decode_link(struct nfsd4_compoundargs *argp, struct nfsd4_link *link) | 518 | nfsd4_decode_link(struct nfsd4_compoundargs *argp, struct nfsd4_link *link) |
519 | { | 519 | { |
520 | DECODE_HEAD; | 520 | DECODE_HEAD; |
@@ -529,7 +529,7 @@ nfsd4_decode_link(struct nfsd4_compoundargs *argp, struct nfsd4_link *link) | |||
529 | DECODE_TAIL; | 529 | DECODE_TAIL; |
530 | } | 530 | } |
531 | 531 | ||
532 | static int | 532 | static __be32 |
533 | nfsd4_decode_lock(struct nfsd4_compoundargs *argp, struct nfsd4_lock *lock) | 533 | nfsd4_decode_lock(struct nfsd4_compoundargs *argp, struct nfsd4_lock *lock) |
534 | { | 534 | { |
535 | DECODE_HEAD; | 535 | DECODE_HEAD; |
@@ -568,7 +568,7 @@ nfsd4_decode_lock(struct nfsd4_compoundargs *argp, struct nfsd4_lock *lock) | |||
568 | DECODE_TAIL; | 568 | DECODE_TAIL; |
569 | } | 569 | } |
570 | 570 | ||
571 | static int | 571 | static __be32 |
572 | nfsd4_decode_lockt(struct nfsd4_compoundargs *argp, struct nfsd4_lockt *lockt) | 572 | nfsd4_decode_lockt(struct nfsd4_compoundargs *argp, struct nfsd4_lockt *lockt) |
573 | { | 573 | { |
574 | DECODE_HEAD; | 574 | DECODE_HEAD; |
@@ -587,7 +587,7 @@ nfsd4_decode_lockt(struct nfsd4_compoundargs *argp, struct nfsd4_lockt *lockt) | |||
587 | DECODE_TAIL; | 587 | DECODE_TAIL; |
588 | } | 588 | } |
589 | 589 | ||
590 | static int | 590 | static __be32 |
591 | nfsd4_decode_locku(struct nfsd4_compoundargs *argp, struct nfsd4_locku *locku) | 591 | nfsd4_decode_locku(struct nfsd4_compoundargs *argp, struct nfsd4_locku *locku) |
592 | { | 592 | { |
593 | DECODE_HEAD; | 593 | DECODE_HEAD; |
@@ -606,7 +606,7 @@ nfsd4_decode_locku(struct nfsd4_compoundargs *argp, struct nfsd4_locku *locku) | |||
606 | DECODE_TAIL; | 606 | DECODE_TAIL; |
607 | } | 607 | } |
608 | 608 | ||
609 | static int | 609 | static __be32 |
610 | nfsd4_decode_lookup(struct nfsd4_compoundargs *argp, struct nfsd4_lookup *lookup) | 610 | nfsd4_decode_lookup(struct nfsd4_compoundargs *argp, struct nfsd4_lookup *lookup) |
611 | { | 611 | { |
612 | DECODE_HEAD; | 612 | DECODE_HEAD; |
@@ -621,7 +621,7 @@ nfsd4_decode_lookup(struct nfsd4_compoundargs *argp, struct nfsd4_lookup *lookup | |||
621 | DECODE_TAIL; | 621 | DECODE_TAIL; |
622 | } | 622 | } |
623 | 623 | ||
624 | static int | 624 | static __be32 |
625 | nfsd4_decode_open(struct nfsd4_compoundargs *argp, struct nfsd4_open *open) | 625 | nfsd4_decode_open(struct nfsd4_compoundargs *argp, struct nfsd4_open *open) |
626 | { | 626 | { |
627 | DECODE_HEAD; | 627 | DECODE_HEAD; |
@@ -699,7 +699,7 @@ nfsd4_decode_open(struct nfsd4_compoundargs *argp, struct nfsd4_open *open) | |||
699 | DECODE_TAIL; | 699 | DECODE_TAIL; |
700 | } | 700 | } |
701 | 701 | ||
702 | static int | 702 | static __be32 |
703 | nfsd4_decode_open_confirm(struct nfsd4_compoundargs *argp, struct nfsd4_open_confirm *open_conf) | 703 | nfsd4_decode_open_confirm(struct nfsd4_compoundargs *argp, struct nfsd4_open_confirm *open_conf) |
704 | { | 704 | { |
705 | DECODE_HEAD; | 705 | DECODE_HEAD; |
@@ -713,7 +713,7 @@ nfsd4_decode_open_confirm(struct nfsd4_compoundargs *argp, struct nfsd4_open_con | |||
713 | DECODE_TAIL; | 713 | DECODE_TAIL; |
714 | } | 714 | } |
715 | 715 | ||
716 | static int | 716 | static __be32 |
717 | nfsd4_decode_open_downgrade(struct nfsd4_compoundargs *argp, struct nfsd4_open_downgrade *open_down) | 717 | nfsd4_decode_open_downgrade(struct nfsd4_compoundargs *argp, struct nfsd4_open_downgrade *open_down) |
718 | { | 718 | { |
719 | DECODE_HEAD; | 719 | DECODE_HEAD; |
@@ -729,7 +729,7 @@ nfsd4_decode_open_downgrade(struct nfsd4_compoundargs *argp, struct nfsd4_open_d | |||
729 | DECODE_TAIL; | 729 | DECODE_TAIL; |
730 | } | 730 | } |
731 | 731 | ||
732 | static int | 732 | static __be32 |
733 | nfsd4_decode_putfh(struct nfsd4_compoundargs *argp, struct nfsd4_putfh *putfh) | 733 | nfsd4_decode_putfh(struct nfsd4_compoundargs *argp, struct nfsd4_putfh *putfh) |
734 | { | 734 | { |
735 | DECODE_HEAD; | 735 | DECODE_HEAD; |
@@ -744,7 +744,7 @@ nfsd4_decode_putfh(struct nfsd4_compoundargs *argp, struct nfsd4_putfh *putfh) | |||
744 | DECODE_TAIL; | 744 | DECODE_TAIL; |
745 | } | 745 | } |
746 | 746 | ||
747 | static int | 747 | static __be32 |
748 | nfsd4_decode_read(struct nfsd4_compoundargs *argp, struct nfsd4_read *read) | 748 | nfsd4_decode_read(struct nfsd4_compoundargs *argp, struct nfsd4_read *read) |
749 | { | 749 | { |
750 | DECODE_HEAD; | 750 | DECODE_HEAD; |
@@ -758,7 +758,7 @@ nfsd4_decode_read(struct nfsd4_compoundargs *argp, struct nfsd4_read *read) | |||
758 | DECODE_TAIL; | 758 | DECODE_TAIL; |
759 | } | 759 | } |
760 | 760 | ||
761 | static int | 761 | static __be32 |
762 | nfsd4_decode_readdir(struct nfsd4_compoundargs *argp, struct nfsd4_readdir *readdir) | 762 | nfsd4_decode_readdir(struct nfsd4_compoundargs *argp, struct nfsd4_readdir *readdir) |
763 | { | 763 | { |
764 | DECODE_HEAD; | 764 | DECODE_HEAD; |
@@ -774,7 +774,7 @@ nfsd4_decode_readdir(struct nfsd4_compoundargs *argp, struct nfsd4_readdir *read | |||
774 | DECODE_TAIL; | 774 | DECODE_TAIL; |
775 | } | 775 | } |
776 | 776 | ||
777 | static int | 777 | static __be32 |
778 | nfsd4_decode_remove(struct nfsd4_compoundargs *argp, struct nfsd4_remove *remove) | 778 | nfsd4_decode_remove(struct nfsd4_compoundargs *argp, struct nfsd4_remove *remove) |
779 | { | 779 | { |
780 | DECODE_HEAD; | 780 | DECODE_HEAD; |
@@ -789,7 +789,7 @@ nfsd4_decode_remove(struct nfsd4_compoundargs *argp, struct nfsd4_remove *remove | |||
789 | DECODE_TAIL; | 789 | DECODE_TAIL; |
790 | } | 790 | } |
791 | 791 | ||
792 | static int | 792 | static __be32 |
793 | nfsd4_decode_rename(struct nfsd4_compoundargs *argp, struct nfsd4_rename *rename) | 793 | nfsd4_decode_rename(struct nfsd4_compoundargs *argp, struct nfsd4_rename *rename) |
794 | { | 794 | { |
795 | DECODE_HEAD; | 795 | DECODE_HEAD; |
@@ -809,7 +809,7 @@ nfsd4_decode_rename(struct nfsd4_compoundargs *argp, struct nfsd4_rename *rename | |||
809 | DECODE_TAIL; | 809 | DECODE_TAIL; |
810 | } | 810 | } |
811 | 811 | ||
812 | static int | 812 | static __be32 |
813 | nfsd4_decode_renew(struct nfsd4_compoundargs *argp, clientid_t *clientid) | 813 | nfsd4_decode_renew(struct nfsd4_compoundargs *argp, clientid_t *clientid) |
814 | { | 814 | { |
815 | DECODE_HEAD; | 815 | DECODE_HEAD; |
@@ -820,7 +820,7 @@ nfsd4_decode_renew(struct nfsd4_compoundargs *argp, clientid_t *clientid) | |||
820 | DECODE_TAIL; | 820 | DECODE_TAIL; |
821 | } | 821 | } |
822 | 822 | ||
823 | static int | 823 | static __be32 |
824 | nfsd4_decode_setattr(struct nfsd4_compoundargs *argp, struct nfsd4_setattr *setattr) | 824 | nfsd4_decode_setattr(struct nfsd4_compoundargs *argp, struct nfsd4_setattr *setattr) |
825 | { | 825 | { |
826 | DECODE_HEAD; | 826 | DECODE_HEAD; |
@@ -834,7 +834,7 @@ nfsd4_decode_setattr(struct nfsd4_compoundargs *argp, struct nfsd4_setattr *seta | |||
834 | DECODE_TAIL; | 834 | DECODE_TAIL; |
835 | } | 835 | } |
836 | 836 | ||
837 | static int | 837 | static __be32 |
838 | nfsd4_decode_setclientid(struct nfsd4_compoundargs *argp, struct nfsd4_setclientid *setclientid) | 838 | nfsd4_decode_setclientid(struct nfsd4_compoundargs *argp, struct nfsd4_setclientid *setclientid) |
839 | { | 839 | { |
840 | DECODE_HEAD; | 840 | DECODE_HEAD; |
@@ -859,7 +859,7 @@ nfsd4_decode_setclientid(struct nfsd4_compoundargs *argp, struct nfsd4_setclient | |||
859 | DECODE_TAIL; | 859 | DECODE_TAIL; |
860 | } | 860 | } |
861 | 861 | ||
862 | static int | 862 | static __be32 |
863 | nfsd4_decode_setclientid_confirm(struct nfsd4_compoundargs *argp, struct nfsd4_setclientid_confirm *scd_c) | 863 | nfsd4_decode_setclientid_confirm(struct nfsd4_compoundargs *argp, struct nfsd4_setclientid_confirm *scd_c) |
864 | { | 864 | { |
865 | DECODE_HEAD; | 865 | DECODE_HEAD; |
@@ -872,7 +872,7 @@ nfsd4_decode_setclientid_confirm(struct nfsd4_compoundargs *argp, struct nfsd4_s | |||
872 | } | 872 | } |
873 | 873 | ||
874 | /* Also used for NVERIFY */ | 874 | /* Also used for NVERIFY */ |
875 | static int | 875 | static __be32 |
876 | nfsd4_decode_verify(struct nfsd4_compoundargs *argp, struct nfsd4_verify *verify) | 876 | nfsd4_decode_verify(struct nfsd4_compoundargs *argp, struct nfsd4_verify *verify) |
877 | { | 877 | { |
878 | #if 0 | 878 | #if 0 |
@@ -908,7 +908,7 @@ nfsd4_decode_verify(struct nfsd4_compoundargs *argp, struct nfsd4_verify *verify | |||
908 | DECODE_TAIL; | 908 | DECODE_TAIL; |
909 | } | 909 | } |
910 | 910 | ||
911 | static int | 911 | static __be32 |
912 | nfsd4_decode_write(struct nfsd4_compoundargs *argp, struct nfsd4_write *write) | 912 | nfsd4_decode_write(struct nfsd4_compoundargs *argp, struct nfsd4_write *write) |
913 | { | 913 | { |
914 | int avail; | 914 | int avail; |
@@ -959,7 +959,7 @@ nfsd4_decode_write(struct nfsd4_compoundargs *argp, struct nfsd4_write *write) | |||
959 | DECODE_TAIL; | 959 | DECODE_TAIL; |
960 | } | 960 | } |
961 | 961 | ||
962 | static int | 962 | static __be32 |
963 | nfsd4_decode_release_lockowner(struct nfsd4_compoundargs *argp, struct nfsd4_release_lockowner *rlockowner) | 963 | nfsd4_decode_release_lockowner(struct nfsd4_compoundargs *argp, struct nfsd4_release_lockowner *rlockowner) |
964 | { | 964 | { |
965 | DECODE_HEAD; | 965 | DECODE_HEAD; |
@@ -973,7 +973,7 @@ nfsd4_decode_release_lockowner(struct nfsd4_compoundargs *argp, struct nfsd4_rel | |||
973 | DECODE_TAIL; | 973 | DECODE_TAIL; |
974 | } | 974 | } |
975 | 975 | ||
976 | static int | 976 | static __be32 |
977 | nfsd4_decode_compound(struct nfsd4_compoundargs *argp) | 977 | nfsd4_decode_compound(struct nfsd4_compoundargs *argp) |
978 | { | 978 | { |
979 | DECODE_HEAD; | 979 | DECODE_HEAD; |
@@ -1234,7 +1234,7 @@ nfsd4_decode_compound(struct nfsd4_compoundargs *argp) | |||
1234 | /* Encode as an array of strings the string given with components | 1234 | /* Encode as an array of strings the string given with components |
1235 | * seperated @sep. | 1235 | * seperated @sep. |
1236 | */ | 1236 | */ |
1237 | static int nfsd4_encode_components(char sep, char *components, | 1237 | static __be32 nfsd4_encode_components(char sep, char *components, |
1238 | __be32 **pp, int *buflen) | 1238 | __be32 **pp, int *buflen) |
1239 | { | 1239 | { |
1240 | __be32 *p = *pp; | 1240 | __be32 *p = *pp; |
@@ -1271,10 +1271,10 @@ static int nfsd4_encode_components(char sep, char *components, | |||
1271 | /* | 1271 | /* |
1272 | * encode a location element of a fs_locations structure | 1272 | * encode a location element of a fs_locations structure |
1273 | */ | 1273 | */ |
1274 | static int nfsd4_encode_fs_location4(struct nfsd4_fs_location *location, | 1274 | static __be32 nfsd4_encode_fs_location4(struct nfsd4_fs_location *location, |
1275 | __be32 **pp, int *buflen) | 1275 | __be32 **pp, int *buflen) |
1276 | { | 1276 | { |
1277 | int status; | 1277 | __be32 status; |
1278 | __be32 *p = *pp; | 1278 | __be32 *p = *pp; |
1279 | 1279 | ||
1280 | status = nfsd4_encode_components(':', location->hosts, &p, buflen); | 1280 | status = nfsd4_encode_components(':', location->hosts, &p, buflen); |
@@ -1292,7 +1292,7 @@ static int nfsd4_encode_fs_location4(struct nfsd4_fs_location *location, | |||
1292 | * Returned string is safe to use as long as the caller holds a reference | 1292 | * Returned string is safe to use as long as the caller holds a reference |
1293 | * to @exp. | 1293 | * to @exp. |
1294 | */ | 1294 | */ |
1295 | static char *nfsd4_path(struct svc_rqst *rqstp, struct svc_export *exp, u32 *stat) | 1295 | static char *nfsd4_path(struct svc_rqst *rqstp, struct svc_export *exp, __be32 *stat) |
1296 | { | 1296 | { |
1297 | struct svc_fh tmp_fh; | 1297 | struct svc_fh tmp_fh; |
1298 | char *path, *rootpath; | 1298 | char *path, *rootpath; |
@@ -1318,11 +1318,11 @@ static char *nfsd4_path(struct svc_rqst *rqstp, struct svc_export *exp, u32 *sta | |||
1318 | /* | 1318 | /* |
1319 | * encode a fs_locations structure | 1319 | * encode a fs_locations structure |
1320 | */ | 1320 | */ |
1321 | static int nfsd4_encode_fs_locations(struct svc_rqst *rqstp, | 1321 | static __be32 nfsd4_encode_fs_locations(struct svc_rqst *rqstp, |
1322 | struct svc_export *exp, | 1322 | struct svc_export *exp, |
1323 | __be32 **pp, int *buflen) | 1323 | __be32 **pp, int *buflen) |
1324 | { | 1324 | { |
1325 | u32 status; | 1325 | __be32 status; |
1326 | int i; | 1326 | int i; |
1327 | __be32 *p = *pp; | 1327 | __be32 *p = *pp; |
1328 | struct nfsd4_fs_locations *fslocs = &exp->ex_fslocs; | 1328 | struct nfsd4_fs_locations *fslocs = &exp->ex_fslocs; |
@@ -1353,7 +1353,7 @@ static u32 nfs4_ftypes[16] = { | |||
1353 | NF4SOCK, NF4BAD, NF4LNK, NF4BAD, | 1353 | NF4SOCK, NF4BAD, NF4LNK, NF4BAD, |
1354 | }; | 1354 | }; |
1355 | 1355 | ||
1356 | static int | 1356 | static __be32 |
1357 | nfsd4_encode_name(struct svc_rqst *rqstp, int whotype, uid_t id, int group, | 1357 | nfsd4_encode_name(struct svc_rqst *rqstp, int whotype, uid_t id, int group, |
1358 | __be32 **p, int *buflen) | 1358 | __be32 **p, int *buflen) |
1359 | { | 1359 | { |
@@ -1375,19 +1375,19 @@ nfsd4_encode_name(struct svc_rqst *rqstp, int whotype, uid_t id, int group, | |||
1375 | return 0; | 1375 | return 0; |
1376 | } | 1376 | } |
1377 | 1377 | ||
1378 | static inline int | 1378 | static inline __be32 |
1379 | nfsd4_encode_user(struct svc_rqst *rqstp, uid_t uid, __be32 **p, int *buflen) | 1379 | nfsd4_encode_user(struct svc_rqst *rqstp, uid_t uid, __be32 **p, int *buflen) |
1380 | { | 1380 | { |
1381 | return nfsd4_encode_name(rqstp, NFS4_ACL_WHO_NAMED, uid, 0, p, buflen); | 1381 | return nfsd4_encode_name(rqstp, NFS4_ACL_WHO_NAMED, uid, 0, p, buflen); |
1382 | } | 1382 | } |
1383 | 1383 | ||
1384 | static inline int | 1384 | static inline __be32 |
1385 | nfsd4_encode_group(struct svc_rqst *rqstp, uid_t gid, __be32 **p, int *buflen) | 1385 | nfsd4_encode_group(struct svc_rqst *rqstp, uid_t gid, __be32 **p, int *buflen) |
1386 | { | 1386 | { |
1387 | return nfsd4_encode_name(rqstp, NFS4_ACL_WHO_NAMED, gid, 1, p, buflen); | 1387 | return nfsd4_encode_name(rqstp, NFS4_ACL_WHO_NAMED, gid, 1, p, buflen); |
1388 | } | 1388 | } |
1389 | 1389 | ||
1390 | static inline int | 1390 | static inline __be32 |
1391 | nfsd4_encode_aclname(struct svc_rqst *rqstp, int whotype, uid_t id, int group, | 1391 | nfsd4_encode_aclname(struct svc_rqst *rqstp, int whotype, uid_t id, int group, |
1392 | __be32 **p, int *buflen) | 1392 | __be32 **p, int *buflen) |
1393 | { | 1393 | { |
@@ -1398,7 +1398,7 @@ nfsd4_encode_aclname(struct svc_rqst *rqstp, int whotype, uid_t id, int group, | |||
1398 | FATTR4_WORD0_RDATTR_ERROR) | 1398 | FATTR4_WORD0_RDATTR_ERROR) |
1399 | #define WORD1_ABSENT_FS_ATTRS FATTR4_WORD1_MOUNTED_ON_FILEID | 1399 | #define WORD1_ABSENT_FS_ATTRS FATTR4_WORD1_MOUNTED_ON_FILEID |
1400 | 1400 | ||
1401 | static int fattr_handle_absent_fs(u32 *bmval0, u32 *bmval1, u32 *rdattr_err) | 1401 | static __be32 fattr_handle_absent_fs(u32 *bmval0, u32 *bmval1, u32 *rdattr_err) |
1402 | { | 1402 | { |
1403 | /* As per referral draft: */ | 1403 | /* As per referral draft: */ |
1404 | if (*bmval0 & ~WORD0_ABSENT_FS_ATTRS || | 1404 | if (*bmval0 & ~WORD0_ABSENT_FS_ATTRS || |
@@ -1421,7 +1421,7 @@ static int fattr_handle_absent_fs(u32 *bmval0, u32 *bmval1, u32 *rdattr_err) | |||
1421 | * @countp is the buffer size in _words_; upon successful return this becomes | 1421 | * @countp is the buffer size in _words_; upon successful return this becomes |
1422 | * replaced with the number of words written. | 1422 | * replaced with the number of words written. |
1423 | */ | 1423 | */ |
1424 | int | 1424 | __be32 |
1425 | nfsd4_encode_fattr(struct svc_fh *fhp, struct svc_export *exp, | 1425 | nfsd4_encode_fattr(struct svc_fh *fhp, struct svc_export *exp, |
1426 | struct dentry *dentry, __be32 *buffer, int *countp, u32 *bmval, | 1426 | struct dentry *dentry, __be32 *buffer, int *countp, u32 *bmval, |
1427 | struct svc_rqst *rqstp) | 1427 | struct svc_rqst *rqstp) |
@@ -1437,7 +1437,7 @@ nfsd4_encode_fattr(struct svc_fh *fhp, struct svc_export *exp, | |||
1437 | u64 dummy64; | 1437 | u64 dummy64; |
1438 | u32 rdattr_err = 0; | 1438 | u32 rdattr_err = 0; |
1439 | __be32 *p = buffer; | 1439 | __be32 *p = buffer; |
1440 | int status; | 1440 | __be32 status; |
1441 | int aclsupport = 0; | 1441 | int aclsupport = 0; |
1442 | struct nfs4_acl *acl = NULL; | 1442 | struct nfs4_acl *acl = NULL; |
1443 | 1443 | ||
@@ -1829,13 +1829,13 @@ out_serverfault: | |||
1829 | goto out; | 1829 | goto out; |
1830 | } | 1830 | } |
1831 | 1831 | ||
1832 | static int | 1832 | static __be32 |
1833 | nfsd4_encode_dirent_fattr(struct nfsd4_readdir *cd, | 1833 | nfsd4_encode_dirent_fattr(struct nfsd4_readdir *cd, |
1834 | const char *name, int namlen, __be32 *p, int *buflen) | 1834 | const char *name, int namlen, __be32 *p, int *buflen) |
1835 | { | 1835 | { |
1836 | struct svc_export *exp = cd->rd_fhp->fh_export; | 1836 | struct svc_export *exp = cd->rd_fhp->fh_export; |
1837 | struct dentry *dentry; | 1837 | struct dentry *dentry; |
1838 | int nfserr; | 1838 | __be32 nfserr; |
1839 | 1839 | ||
1840 | dentry = lookup_one_len(name, cd->rd_fhp->fh_dentry, namlen); | 1840 | dentry = lookup_one_len(name, cd->rd_fhp->fh_dentry, namlen); |
1841 | if (IS_ERR(dentry)) | 1841 | if (IS_ERR(dentry)) |
@@ -1865,7 +1865,7 @@ out_put: | |||
1865 | } | 1865 | } |
1866 | 1866 | ||
1867 | static __be32 * | 1867 | static __be32 * |
1868 | nfsd4_encode_rdattr_error(__be32 *p, int buflen, int nfserr) | 1868 | nfsd4_encode_rdattr_error(__be32 *p, int buflen, __be32 nfserr) |
1869 | { | 1869 | { |
1870 | __be32 *attrlenp; | 1870 | __be32 *attrlenp; |
1871 | 1871 | ||
@@ -1888,7 +1888,7 @@ nfsd4_encode_dirent(struct readdir_cd *ccd, const char *name, int namlen, | |||
1888 | struct nfsd4_readdir *cd = container_of(ccd, struct nfsd4_readdir, common); | 1888 | struct nfsd4_readdir *cd = container_of(ccd, struct nfsd4_readdir, common); |
1889 | int buflen; | 1889 | int buflen; |
1890 | __be32 *p = cd->buffer; | 1890 | __be32 *p = cd->buffer; |
1891 | int nfserr = nfserr_toosmall; | 1891 | __be32 nfserr = nfserr_toosmall; |
1892 | 1892 | ||
1893 | /* In nfsv4, "." and ".." never make it onto the wire.. */ | 1893 | /* In nfsv4, "." and ".." never make it onto the wire.. */ |
1894 | if (name && isdotent(name, namlen)) { | 1894 | if (name && isdotent(name, namlen)) { |
@@ -1944,7 +1944,7 @@ fail: | |||
1944 | } | 1944 | } |
1945 | 1945 | ||
1946 | static void | 1946 | static void |
1947 | nfsd4_encode_access(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_access *access) | 1947 | nfsd4_encode_access(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_access *access) |
1948 | { | 1948 | { |
1949 | ENCODE_HEAD; | 1949 | ENCODE_HEAD; |
1950 | 1950 | ||
@@ -1957,7 +1957,7 @@ nfsd4_encode_access(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_acc | |||
1957 | } | 1957 | } |
1958 | 1958 | ||
1959 | static void | 1959 | static void |
1960 | nfsd4_encode_close(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_close *close) | 1960 | nfsd4_encode_close(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_close *close) |
1961 | { | 1961 | { |
1962 | ENCODE_SEQID_OP_HEAD; | 1962 | ENCODE_SEQID_OP_HEAD; |
1963 | 1963 | ||
@@ -1972,7 +1972,7 @@ nfsd4_encode_close(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_clos | |||
1972 | 1972 | ||
1973 | 1973 | ||
1974 | static void | 1974 | static void |
1975 | nfsd4_encode_commit(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_commit *commit) | 1975 | nfsd4_encode_commit(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_commit *commit) |
1976 | { | 1976 | { |
1977 | ENCODE_HEAD; | 1977 | ENCODE_HEAD; |
1978 | 1978 | ||
@@ -1984,7 +1984,7 @@ nfsd4_encode_commit(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_com | |||
1984 | } | 1984 | } |
1985 | 1985 | ||
1986 | static void | 1986 | static void |
1987 | nfsd4_encode_create(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_create *create) | 1987 | nfsd4_encode_create(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_create *create) |
1988 | { | 1988 | { |
1989 | ENCODE_HEAD; | 1989 | ENCODE_HEAD; |
1990 | 1990 | ||
@@ -1998,8 +1998,8 @@ nfsd4_encode_create(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_cre | |||
1998 | } | 1998 | } |
1999 | } | 1999 | } |
2000 | 2000 | ||
2001 | static int | 2001 | static __be32 |
2002 | nfsd4_encode_getattr(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_getattr *getattr) | 2002 | nfsd4_encode_getattr(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_getattr *getattr) |
2003 | { | 2003 | { |
2004 | struct svc_fh *fhp = getattr->ga_fhp; | 2004 | struct svc_fh *fhp = getattr->ga_fhp; |
2005 | int buflen; | 2005 | int buflen; |
@@ -2017,7 +2017,7 @@ nfsd4_encode_getattr(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_ge | |||
2017 | } | 2017 | } |
2018 | 2018 | ||
2019 | static void | 2019 | static void |
2020 | nfsd4_encode_getfh(struct nfsd4_compoundres *resp, int nfserr, struct svc_fh *fhp) | 2020 | nfsd4_encode_getfh(struct nfsd4_compoundres *resp, __be32 nfserr, struct svc_fh *fhp) |
2021 | { | 2021 | { |
2022 | unsigned int len; | 2022 | unsigned int len; |
2023 | ENCODE_HEAD; | 2023 | ENCODE_HEAD; |
@@ -2057,7 +2057,7 @@ nfsd4_encode_lock_denied(struct nfsd4_compoundres *resp, struct nfsd4_lock_denie | |||
2057 | } | 2057 | } |
2058 | 2058 | ||
2059 | static void | 2059 | static void |
2060 | nfsd4_encode_lock(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_lock *lock) | 2060 | nfsd4_encode_lock(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_lock *lock) |
2061 | { | 2061 | { |
2062 | ENCODE_SEQID_OP_HEAD; | 2062 | ENCODE_SEQID_OP_HEAD; |
2063 | 2063 | ||
@@ -2073,14 +2073,14 @@ nfsd4_encode_lock(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_lock | |||
2073 | } | 2073 | } |
2074 | 2074 | ||
2075 | static void | 2075 | static void |
2076 | nfsd4_encode_lockt(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_lockt *lockt) | 2076 | nfsd4_encode_lockt(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_lockt *lockt) |
2077 | { | 2077 | { |
2078 | if (nfserr == nfserr_denied) | 2078 | if (nfserr == nfserr_denied) |
2079 | nfsd4_encode_lock_denied(resp, &lockt->lt_denied); | 2079 | nfsd4_encode_lock_denied(resp, &lockt->lt_denied); |
2080 | } | 2080 | } |
2081 | 2081 | ||
2082 | static void | 2082 | static void |
2083 | nfsd4_encode_locku(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_locku *locku) | 2083 | nfsd4_encode_locku(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_locku *locku) |
2084 | { | 2084 | { |
2085 | ENCODE_SEQID_OP_HEAD; | 2085 | ENCODE_SEQID_OP_HEAD; |
2086 | 2086 | ||
@@ -2096,7 +2096,7 @@ nfsd4_encode_locku(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_lock | |||
2096 | 2096 | ||
2097 | 2097 | ||
2098 | static void | 2098 | static void |
2099 | nfsd4_encode_link(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_link *link) | 2099 | nfsd4_encode_link(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_link *link) |
2100 | { | 2100 | { |
2101 | ENCODE_HEAD; | 2101 | ENCODE_HEAD; |
2102 | 2102 | ||
@@ -2109,7 +2109,7 @@ nfsd4_encode_link(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_link | |||
2109 | 2109 | ||
2110 | 2110 | ||
2111 | static void | 2111 | static void |
2112 | nfsd4_encode_open(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_open *open) | 2112 | nfsd4_encode_open(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_open *open) |
2113 | { | 2113 | { |
2114 | ENCODE_SEQID_OP_HEAD; | 2114 | ENCODE_SEQID_OP_HEAD; |
2115 | 2115 | ||
@@ -2174,7 +2174,7 @@ out: | |||
2174 | } | 2174 | } |
2175 | 2175 | ||
2176 | static void | 2176 | static void |
2177 | nfsd4_encode_open_confirm(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_open_confirm *oc) | 2177 | nfsd4_encode_open_confirm(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_open_confirm *oc) |
2178 | { | 2178 | { |
2179 | ENCODE_SEQID_OP_HEAD; | 2179 | ENCODE_SEQID_OP_HEAD; |
2180 | 2180 | ||
@@ -2189,7 +2189,7 @@ nfsd4_encode_open_confirm(struct nfsd4_compoundres *resp, int nfserr, struct nfs | |||
2189 | } | 2189 | } |
2190 | 2190 | ||
2191 | static void | 2191 | static void |
2192 | nfsd4_encode_open_downgrade(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_open_downgrade *od) | 2192 | nfsd4_encode_open_downgrade(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_open_downgrade *od) |
2193 | { | 2193 | { |
2194 | ENCODE_SEQID_OP_HEAD; | 2194 | ENCODE_SEQID_OP_HEAD; |
2195 | 2195 | ||
@@ -2203,8 +2203,8 @@ nfsd4_encode_open_downgrade(struct nfsd4_compoundres *resp, int nfserr, struct n | |||
2203 | ENCODE_SEQID_OP_TAIL(od->od_stateowner); | 2203 | ENCODE_SEQID_OP_TAIL(od->od_stateowner); |
2204 | } | 2204 | } |
2205 | 2205 | ||
2206 | static int | 2206 | static __be32 |
2207 | nfsd4_encode_read(struct nfsd4_compoundres *resp, int nfserr, | 2207 | nfsd4_encode_read(struct nfsd4_compoundres *resp, __be32 nfserr, |
2208 | struct nfsd4_read *read) | 2208 | struct nfsd4_read *read) |
2209 | { | 2209 | { |
2210 | u32 eof; | 2210 | u32 eof; |
@@ -2268,8 +2268,8 @@ nfsd4_encode_read(struct nfsd4_compoundres *resp, int nfserr, | |||
2268 | return 0; | 2268 | return 0; |
2269 | } | 2269 | } |
2270 | 2270 | ||
2271 | static int | 2271 | static __be32 |
2272 | nfsd4_encode_readlink(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_readlink *readlink) | 2272 | nfsd4_encode_readlink(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_readlink *readlink) |
2273 | { | 2273 | { |
2274 | int maxcount; | 2274 | int maxcount; |
2275 | char *page; | 2275 | char *page; |
@@ -2316,8 +2316,8 @@ nfsd4_encode_readlink(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_r | |||
2316 | return 0; | 2316 | return 0; |
2317 | } | 2317 | } |
2318 | 2318 | ||
2319 | static int | 2319 | static __be32 |
2320 | nfsd4_encode_readdir(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_readdir *readdir) | 2320 | nfsd4_encode_readdir(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_readdir *readdir) |
2321 | { | 2321 | { |
2322 | int maxcount; | 2322 | int maxcount; |
2323 | loff_t offset; | 2323 | loff_t offset; |
@@ -2396,7 +2396,7 @@ err_no_verf: | |||
2396 | } | 2396 | } |
2397 | 2397 | ||
2398 | static void | 2398 | static void |
2399 | nfsd4_encode_remove(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_remove *remove) | 2399 | nfsd4_encode_remove(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_remove *remove) |
2400 | { | 2400 | { |
2401 | ENCODE_HEAD; | 2401 | ENCODE_HEAD; |
2402 | 2402 | ||
@@ -2408,7 +2408,7 @@ nfsd4_encode_remove(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_rem | |||
2408 | } | 2408 | } |
2409 | 2409 | ||
2410 | static void | 2410 | static void |
2411 | nfsd4_encode_rename(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_rename *rename) | 2411 | nfsd4_encode_rename(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_rename *rename) |
2412 | { | 2412 | { |
2413 | ENCODE_HEAD; | 2413 | ENCODE_HEAD; |
2414 | 2414 | ||
@@ -2425,7 +2425,7 @@ nfsd4_encode_rename(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_ren | |||
2425 | * regardless of the error status. | 2425 | * regardless of the error status. |
2426 | */ | 2426 | */ |
2427 | static void | 2427 | static void |
2428 | nfsd4_encode_setattr(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_setattr *setattr) | 2428 | nfsd4_encode_setattr(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_setattr *setattr) |
2429 | { | 2429 | { |
2430 | ENCODE_HEAD; | 2430 | ENCODE_HEAD; |
2431 | 2431 | ||
@@ -2444,7 +2444,7 @@ nfsd4_encode_setattr(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_se | |||
2444 | } | 2444 | } |
2445 | 2445 | ||
2446 | static void | 2446 | static void |
2447 | nfsd4_encode_setclientid(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_setclientid *scd) | 2447 | nfsd4_encode_setclientid(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_setclientid *scd) |
2448 | { | 2448 | { |
2449 | ENCODE_HEAD; | 2449 | ENCODE_HEAD; |
2450 | 2450 | ||
@@ -2463,7 +2463,7 @@ nfsd4_encode_setclientid(struct nfsd4_compoundres *resp, int nfserr, struct nfsd | |||
2463 | } | 2463 | } |
2464 | 2464 | ||
2465 | static void | 2465 | static void |
2466 | nfsd4_encode_write(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_write *write) | 2466 | nfsd4_encode_write(struct nfsd4_compoundres *resp, __be32 nfserr, struct nfsd4_write *write) |
2467 | { | 2467 | { |
2468 | ENCODE_HEAD; | 2468 | ENCODE_HEAD; |
2469 | 2469 | ||
@@ -2641,7 +2641,7 @@ void nfsd4_release_compoundargs(struct nfsd4_compoundargs *args) | |||
2641 | int | 2641 | int |
2642 | nfs4svc_decode_compoundargs(struct svc_rqst *rqstp, __be32 *p, struct nfsd4_compoundargs *args) | 2642 | nfs4svc_decode_compoundargs(struct svc_rqst *rqstp, __be32 *p, struct nfsd4_compoundargs *args) |
2643 | { | 2643 | { |
2644 | int status; | 2644 | __be32 status; |
2645 | 2645 | ||
2646 | args->p = p; | 2646 | args->p = p; |
2647 | args->end = rqstp->rq_arg.head[0].iov_base + rqstp->rq_arg.head[0].iov_len; | 2647 | args->end = rqstp->rq_arg.head[0].iov_base + rqstp->rq_arg.head[0].iov_len; |