aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/nfs_xdr.h
diff options
context:
space:
mode:
authorBenny Halevy <bhalevy@panasas.com>2009-04-01 09:21:52 -0400
committerBenny Halevy <bhalevy@panasas.com>2009-06-17 13:46:19 -0400
commit9ff71c3a9827b99699510076dffa0bbe7c36bfd4 (patch)
tree1ff268228bd9c8789854a907807132b99afe6d7e /include/linux/nfs_xdr.h
parentc2e713dd83dcabb2ae951ea572e7de68c96e2d48 (diff)
nfs41: client xdr definitions
Define stubs for sequence args and res data structures and embed them in all other nfs4 and nfs41 xdr types. They are needed for sending any op in a nfs41 compound rpc. Signed-off-by: Andy Adamson<andros@netapp.com> [moved new args/res definitions away, to where they're first used] Signed-off-by: Benny Halevy <bhalevy@panasas.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'include/linux/nfs_xdr.h')
-rw-r--r--include/linux/nfs_xdr.h52
1 files changed, 52 insertions, 0 deletions
diff --git a/include/linux/nfs_xdr.h b/include/linux/nfs_xdr.h
index b89c34e40bc2..f2c5700c7b6e 100644
--- a/include/linux/nfs_xdr.h
+++ b/include/linux/nfs_xdr.h
@@ -145,6 +145,15 @@ struct nfs4_change_info {
145}; 145};
146 146
147struct nfs_seqid; 147struct nfs_seqid;
148
149struct nfs4_sequence_args {
150 /* stub */
151};
152
153struct nfs4_sequence_res {
154 /* stub */
155};
156
148/* 157/*
149 * Arguments to the open call. 158 * Arguments to the open call.
150 */ 159 */
@@ -165,6 +174,7 @@ struct nfs_openargs {
165 const struct nfs_server *server; /* Needed for ID mapping */ 174 const struct nfs_server *server; /* Needed for ID mapping */
166 const u32 * bitmask; 175 const u32 * bitmask;
167 __u32 claim; 176 __u32 claim;
177 struct nfs4_sequence_args seq_args;
168}; 178};
169 179
170struct nfs_openres { 180struct nfs_openres {
@@ -181,6 +191,7 @@ struct nfs_openres {
181 __u32 do_recall; 191 __u32 do_recall;
182 __u64 maxsize; 192 __u64 maxsize;
183 __u32 attrset[NFS4_BITMAP_SIZE]; 193 __u32 attrset[NFS4_BITMAP_SIZE];
194 struct nfs4_sequence_res seq_res;
184}; 195};
185 196
186/* 197/*
@@ -206,6 +217,7 @@ struct nfs_closeargs {
206 struct nfs_seqid * seqid; 217 struct nfs_seqid * seqid;
207 fmode_t fmode; 218 fmode_t fmode;
208 const u32 * bitmask; 219 const u32 * bitmask;
220 struct nfs4_sequence_args seq_args;
209}; 221};
210 222
211struct nfs_closeres { 223struct nfs_closeres {
@@ -213,6 +225,7 @@ struct nfs_closeres {
213 struct nfs_fattr * fattr; 225 struct nfs_fattr * fattr;
214 struct nfs_seqid * seqid; 226 struct nfs_seqid * seqid;
215 const struct nfs_server *server; 227 const struct nfs_server *server;
228 struct nfs4_sequence_res seq_res;
216}; 229};
217/* 230/*
218 * * Arguments to the lock,lockt, and locku call. 231 * * Arguments to the lock,lockt, and locku call.
@@ -233,12 +246,14 @@ struct nfs_lock_args {
233 unsigned char block : 1; 246 unsigned char block : 1;
234 unsigned char reclaim : 1; 247 unsigned char reclaim : 1;
235 unsigned char new_lock_owner : 1; 248 unsigned char new_lock_owner : 1;
249 struct nfs4_sequence_args seq_args;
236}; 250};
237 251
238struct nfs_lock_res { 252struct nfs_lock_res {
239 nfs4_stateid stateid; 253 nfs4_stateid stateid;
240 struct nfs_seqid * lock_seqid; 254 struct nfs_seqid * lock_seqid;
241 struct nfs_seqid * open_seqid; 255 struct nfs_seqid * open_seqid;
256 struct nfs4_sequence_res seq_res;
242}; 257};
243 258
244struct nfs_locku_args { 259struct nfs_locku_args {
@@ -246,32 +261,38 @@ struct nfs_locku_args {
246 struct file_lock * fl; 261 struct file_lock * fl;
247 struct nfs_seqid * seqid; 262 struct nfs_seqid * seqid;
248 nfs4_stateid * stateid; 263 nfs4_stateid * stateid;
264 struct nfs4_sequence_args seq_args;
249}; 265};
250 266
251struct nfs_locku_res { 267struct nfs_locku_res {
252 nfs4_stateid stateid; 268 nfs4_stateid stateid;
253 struct nfs_seqid * seqid; 269 struct nfs_seqid * seqid;
270 struct nfs4_sequence_res seq_res;
254}; 271};
255 272
256struct nfs_lockt_args { 273struct nfs_lockt_args {
257 struct nfs_fh * fh; 274 struct nfs_fh * fh;
258 struct file_lock * fl; 275 struct file_lock * fl;
259 struct nfs_lowner lock_owner; 276 struct nfs_lowner lock_owner;
277 struct nfs4_sequence_args seq_args;
260}; 278};
261 279
262struct nfs_lockt_res { 280struct nfs_lockt_res {
263 struct file_lock * denied; /* LOCK, LOCKT failed */ 281 struct file_lock * denied; /* LOCK, LOCKT failed */
282 struct nfs4_sequence_res seq_res;
264}; 283};
265 284
266struct nfs4_delegreturnargs { 285struct nfs4_delegreturnargs {
267 const struct nfs_fh *fhandle; 286 const struct nfs_fh *fhandle;
268 const nfs4_stateid *stateid; 287 const nfs4_stateid *stateid;
269 const u32 * bitmask; 288 const u32 * bitmask;
289 struct nfs4_sequence_args seq_args;
270}; 290};
271 291
272struct nfs4_delegreturnres { 292struct nfs4_delegreturnres {
273 struct nfs_fattr * fattr; 293 struct nfs_fattr * fattr;
274 const struct nfs_server *server; 294 const struct nfs_server *server;
295 struct nfs4_sequence_res seq_res;
275}; 296};
276 297
277/* 298/*
@@ -284,12 +305,14 @@ struct nfs_readargs {
284 __u32 count; 305 __u32 count;
285 unsigned int pgbase; 306 unsigned int pgbase;
286 struct page ** pages; 307 struct page ** pages;
308 struct nfs4_sequence_args seq_args;
287}; 309};
288 310
289struct nfs_readres { 311struct nfs_readres {
290 struct nfs_fattr * fattr; 312 struct nfs_fattr * fattr;
291 __u32 count; 313 __u32 count;
292 int eof; 314 int eof;
315 struct nfs4_sequence_res seq_res;
293}; 316};
294 317
295/* 318/*
@@ -304,6 +327,7 @@ struct nfs_writeargs {
304 unsigned int pgbase; 327 unsigned int pgbase;
305 struct page ** pages; 328 struct page ** pages;
306 const u32 * bitmask; 329 const u32 * bitmask;
330 struct nfs4_sequence_args seq_args;
307}; 331};
308 332
309struct nfs_writeverf { 333struct nfs_writeverf {
@@ -316,6 +340,7 @@ struct nfs_writeres {
316 struct nfs_writeverf * verf; 340 struct nfs_writeverf * verf;
317 __u32 count; 341 __u32 count;
318 const struct nfs_server *server; 342 const struct nfs_server *server;
343 struct nfs4_sequence_res seq_res;
319}; 344};
320 345
321/* 346/*
@@ -325,12 +350,14 @@ struct nfs_removeargs {
325 const struct nfs_fh *fh; 350 const struct nfs_fh *fh;
326 struct qstr name; 351 struct qstr name;
327 const u32 * bitmask; 352 const u32 * bitmask;
353 struct nfs4_sequence_args seq_args;
328}; 354};
329 355
330struct nfs_removeres { 356struct nfs_removeres {
331 const struct nfs_server *server; 357 const struct nfs_server *server;
332 struct nfs4_change_info cinfo; 358 struct nfs4_change_info cinfo;
333 struct nfs_fattr dir_attr; 359 struct nfs_fattr dir_attr;
360 struct nfs4_sequence_res seq_res;
334}; 361};
335 362
336/* 363/*
@@ -383,6 +410,7 @@ struct nfs_setattrargs {
383 struct iattr * iap; 410 struct iattr * iap;
384 const struct nfs_server * server; /* Needed for name mapping */ 411 const struct nfs_server * server; /* Needed for name mapping */
385 const u32 * bitmask; 412 const u32 * bitmask;
413 struct nfs4_sequence_args seq_args;
386}; 414};
387 415
388struct nfs_setaclargs { 416struct nfs_setaclargs {
@@ -390,6 +418,7 @@ struct nfs_setaclargs {
390 size_t acl_len; 418 size_t acl_len;
391 unsigned int acl_pgbase; 419 unsigned int acl_pgbase;
392 struct page ** acl_pages; 420 struct page ** acl_pages;
421 struct nfs4_sequence_args seq_args;
393}; 422};
394 423
395struct nfs_getaclargs { 424struct nfs_getaclargs {
@@ -397,11 +426,13 @@ struct nfs_getaclargs {
397 size_t acl_len; 426 size_t acl_len;
398 unsigned int acl_pgbase; 427 unsigned int acl_pgbase;
399 struct page ** acl_pages; 428 struct page ** acl_pages;
429 struct nfs4_sequence_args seq_args;
400}; 430};
401 431
402struct nfs_setattrres { 432struct nfs_setattrres {
403 struct nfs_fattr * fattr; 433 struct nfs_fattr * fattr;
404 const struct nfs_server * server; 434 const struct nfs_server * server;
435 struct nfs4_sequence_res seq_res;
405}; 436};
406 437
407struct nfs_linkargs { 438struct nfs_linkargs {
@@ -583,6 +614,7 @@ struct nfs4_accessargs {
583 const struct nfs_fh * fh; 614 const struct nfs_fh * fh;
584 const u32 * bitmask; 615 const u32 * bitmask;
585 u32 access; 616 u32 access;
617 struct nfs4_sequence_args seq_args;
586}; 618};
587 619
588struct nfs4_accessres { 620struct nfs4_accessres {
@@ -590,6 +622,7 @@ struct nfs4_accessres {
590 struct nfs_fattr * fattr; 622 struct nfs_fattr * fattr;
591 u32 supported; 623 u32 supported;
592 u32 access; 624 u32 access;
625 struct nfs4_sequence_res seq_res;
593}; 626};
594 627
595struct nfs4_create_arg { 628struct nfs4_create_arg {
@@ -609,6 +642,7 @@ struct nfs4_create_arg {
609 const struct iattr * attrs; 642 const struct iattr * attrs;
610 const struct nfs_fh * dir_fh; 643 const struct nfs_fh * dir_fh;
611 const u32 * bitmask; 644 const u32 * bitmask;
645 struct nfs4_sequence_args seq_args;
612}; 646};
613 647
614struct nfs4_create_res { 648struct nfs4_create_res {
@@ -617,21 +651,25 @@ struct nfs4_create_res {
617 struct nfs_fattr * fattr; 651 struct nfs_fattr * fattr;
618 struct nfs4_change_info dir_cinfo; 652 struct nfs4_change_info dir_cinfo;
619 struct nfs_fattr * dir_fattr; 653 struct nfs_fattr * dir_fattr;
654 struct nfs4_sequence_res seq_res;
620}; 655};
621 656
622struct nfs4_fsinfo_arg { 657struct nfs4_fsinfo_arg {
623 const struct nfs_fh * fh; 658 const struct nfs_fh * fh;
624 const u32 * bitmask; 659 const u32 * bitmask;
660 struct nfs4_sequence_args seq_args;
625}; 661};
626 662
627struct nfs4_getattr_arg { 663struct nfs4_getattr_arg {
628 const struct nfs_fh * fh; 664 const struct nfs_fh * fh;
629 const u32 * bitmask; 665 const u32 * bitmask;
666 struct nfs4_sequence_args seq_args;
630}; 667};
631 668
632struct nfs4_getattr_res { 669struct nfs4_getattr_res {
633 const struct nfs_server * server; 670 const struct nfs_server * server;
634 struct nfs_fattr * fattr; 671 struct nfs_fattr * fattr;
672 struct nfs4_sequence_res seq_res;
635}; 673};
636 674
637struct nfs4_link_arg { 675struct nfs4_link_arg {
@@ -639,6 +677,7 @@ struct nfs4_link_arg {
639 const struct nfs_fh * dir_fh; 677 const struct nfs_fh * dir_fh;
640 const struct qstr * name; 678 const struct qstr * name;
641 const u32 * bitmask; 679 const u32 * bitmask;
680 struct nfs4_sequence_args seq_args;
642}; 681};
643 682
644struct nfs4_link_res { 683struct nfs4_link_res {
@@ -646,6 +685,7 @@ struct nfs4_link_res {
646 struct nfs_fattr * fattr; 685 struct nfs_fattr * fattr;
647 struct nfs4_change_info cinfo; 686 struct nfs4_change_info cinfo;
648 struct nfs_fattr * dir_attr; 687 struct nfs_fattr * dir_attr;
688 struct nfs4_sequence_res seq_res;
649}; 689};
650 690
651 691
@@ -653,21 +693,25 @@ struct nfs4_lookup_arg {
653 const struct nfs_fh * dir_fh; 693 const struct nfs_fh * dir_fh;
654 const struct qstr * name; 694 const struct qstr * name;
655 const u32 * bitmask; 695 const u32 * bitmask;
696 struct nfs4_sequence_args seq_args;
656}; 697};
657 698
658struct nfs4_lookup_res { 699struct nfs4_lookup_res {
659 const struct nfs_server * server; 700 const struct nfs_server * server;
660 struct nfs_fattr * fattr; 701 struct nfs_fattr * fattr;
661 struct nfs_fh * fh; 702 struct nfs_fh * fh;
703 struct nfs4_sequence_res seq_res;
662}; 704};
663 705
664struct nfs4_lookup_root_arg { 706struct nfs4_lookup_root_arg {
665 const u32 * bitmask; 707 const u32 * bitmask;
708 struct nfs4_sequence_args seq_args;
666}; 709};
667 710
668struct nfs4_pathconf_arg { 711struct nfs4_pathconf_arg {
669 const struct nfs_fh * fh; 712 const struct nfs_fh * fh;
670 const u32 * bitmask; 713 const u32 * bitmask;
714 struct nfs4_sequence_args seq_args;
671}; 715};
672 716
673struct nfs4_readdir_arg { 717struct nfs4_readdir_arg {
@@ -678,11 +722,13 @@ struct nfs4_readdir_arg {
678 struct page ** pages; /* zero-copy data */ 722 struct page ** pages; /* zero-copy data */
679 unsigned int pgbase; /* zero-copy data */ 723 unsigned int pgbase; /* zero-copy data */
680 const u32 * bitmask; 724 const u32 * bitmask;
725 struct nfs4_sequence_args seq_args;
681}; 726};
682 727
683struct nfs4_readdir_res { 728struct nfs4_readdir_res {
684 nfs4_verifier verifier; 729 nfs4_verifier verifier;
685 unsigned int pgbase; 730 unsigned int pgbase;
731 struct nfs4_sequence_res seq_res;
686}; 732};
687 733
688struct nfs4_readlink { 734struct nfs4_readlink {
@@ -690,6 +736,7 @@ struct nfs4_readlink {
690 unsigned int pgbase; 736 unsigned int pgbase;
691 unsigned int pglen; /* zero-copy data */ 737 unsigned int pglen; /* zero-copy data */
692 struct page ** pages; /* zero-copy data */ 738 struct page ** pages; /* zero-copy data */
739 struct nfs4_sequence_args seq_args;
693}; 740};
694 741
695struct nfs4_rename_arg { 742struct nfs4_rename_arg {
@@ -698,6 +745,7 @@ struct nfs4_rename_arg {
698 const struct qstr * old_name; 745 const struct qstr * old_name;
699 const struct qstr * new_name; 746 const struct qstr * new_name;
700 const u32 * bitmask; 747 const u32 * bitmask;
748 struct nfs4_sequence_args seq_args;
701}; 749};
702 750
703struct nfs4_rename_res { 751struct nfs4_rename_res {
@@ -706,6 +754,7 @@ struct nfs4_rename_res {
706 struct nfs_fattr * old_fattr; 754 struct nfs_fattr * old_fattr;
707 struct nfs4_change_info new_cinfo; 755 struct nfs4_change_info new_cinfo;
708 struct nfs_fattr * new_fattr; 756 struct nfs_fattr * new_fattr;
757 struct nfs4_sequence_res seq_res;
709}; 758};
710 759
711#define NFS4_SETCLIENTID_NAMELEN (127) 760#define NFS4_SETCLIENTID_NAMELEN (127)
@@ -724,6 +773,7 @@ struct nfs4_setclientid {
724struct nfs4_statfs_arg { 773struct nfs4_statfs_arg {
725 const struct nfs_fh * fh; 774 const struct nfs_fh * fh;
726 const u32 * bitmask; 775 const u32 * bitmask;
776 struct nfs4_sequence_args seq_args;
727}; 777};
728 778
729struct nfs4_server_caps_res { 779struct nfs4_server_caps_res {
@@ -731,6 +781,7 @@ struct nfs4_server_caps_res {
731 u32 acl_bitmask; 781 u32 acl_bitmask;
732 u32 has_links; 782 u32 has_links;
733 u32 has_symlinks; 783 u32 has_symlinks;
784 struct nfs4_sequence_res seq_res;
734}; 785};
735 786
736struct nfs4_string { 787struct nfs4_string {
@@ -765,6 +816,7 @@ struct nfs4_fs_locations_arg {
765 const struct qstr *name; 816 const struct qstr *name;
766 struct page *page; 817 struct page *page;
767 const u32 *bitmask; 818 const u32 *bitmask;
819 struct nfs4_sequence_args seq_args;
768}; 820};
769 821
770#endif /* CONFIG_NFS_V4 */ 822#endif /* CONFIG_NFS_V4 */