nfs_xdr.h 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744
  1. #ifndef _LINUX_NFS_XDR_H
  2. #define _LINUX_NFS_XDR_H
  3. #include <linux/sunrpc/xprt.h>
  4. struct nfs4_fsid {
  5. __u64 major;
  6. __u64 minor;
  7. };
  8. struct nfs_fattr {
  9. unsigned short valid; /* which fields are valid */
  10. __u64 pre_size; /* pre_op_attr.size */
  11. struct timespec pre_mtime; /* pre_op_attr.mtime */
  12. struct timespec pre_ctime; /* pre_op_attr.ctime */
  13. enum nfs_ftype type; /* always use NFSv2 types */
  14. __u32 mode;
  15. __u32 nlink;
  16. __u32 uid;
  17. __u32 gid;
  18. __u64 size;
  19. union {
  20. struct {
  21. __u32 blocksize;
  22. __u32 blocks;
  23. } nfs2;
  24. struct {
  25. __u64 used;
  26. } nfs3;
  27. } du;
  28. dev_t rdev;
  29. union {
  30. __u64 nfs3; /* also nfs2 */
  31. struct nfs4_fsid nfs4;
  32. } fsid_u;
  33. __u64 fileid;
  34. struct timespec atime;
  35. struct timespec mtime;
  36. struct timespec ctime;
  37. __u32 bitmap[2]; /* NFSv4 returned attribute bitmap */
  38. __u64 change_attr; /* NFSv4 change attribute */
  39. __u64 pre_change_attr;/* pre-op NFSv4 change attribute */
  40. unsigned long timestamp;
  41. };
  42. #define NFS_ATTR_WCC 0x0001 /* pre-op WCC data */
  43. #define NFS_ATTR_FATTR 0x0002 /* post-op attributes */
  44. #define NFS_ATTR_FATTR_V3 0x0004 /* NFSv3 attributes */
  45. #define NFS_ATTR_FATTR_V4 0x0008
  46. #define NFS_ATTR_PRE_CHANGE 0x0010
  47. /*
  48. * Info on the file system
  49. */
  50. struct nfs_fsinfo {
  51. struct nfs_fattr *fattr; /* Post-op attributes */
  52. __u32 rtmax; /* max. read transfer size */
  53. __u32 rtpref; /* pref. read transfer size */
  54. __u32 rtmult; /* reads should be multiple of this */
  55. __u32 wtmax; /* max. write transfer size */
  56. __u32 wtpref; /* pref. write transfer size */
  57. __u32 wtmult; /* writes should be multiple of this */
  58. __u32 dtpref; /* pref. readdir transfer size */
  59. __u64 maxfilesize;
  60. __u32 lease_time; /* in seconds */
  61. };
  62. struct nfs_fsstat {
  63. struct nfs_fattr *fattr; /* Post-op attributes */
  64. __u64 tbytes; /* total size in bytes */
  65. __u64 fbytes; /* # of free bytes */
  66. __u64 abytes; /* # of bytes available to user */
  67. __u64 tfiles; /* # of files */
  68. __u64 ffiles; /* # of free files */
  69. __u64 afiles; /* # of files available to user */
  70. };
  71. struct nfs2_fsstat {
  72. __u32 tsize; /* Server transfer size */
  73. __u32 bsize; /* Filesystem block size */
  74. __u32 blocks; /* No. of "bsize" blocks on filesystem */
  75. __u32 bfree; /* No. of free "bsize" blocks */
  76. __u32 bavail; /* No. of available "bsize" blocks */
  77. };
  78. struct nfs_pathconf {
  79. struct nfs_fattr *fattr; /* Post-op attributes */
  80. __u32 max_link; /* max # of hard links */
  81. __u32 max_namelen; /* max name length */
  82. };
  83. struct nfs4_change_info {
  84. u32 atomic;
  85. u64 before;
  86. u64 after;
  87. };
  88. /*
  89. * Arguments to the open call.
  90. */
  91. struct nfs_openargs {
  92. const struct nfs_fh * fh;
  93. __u32 seqid;
  94. int open_flags;
  95. __u64 clientid;
  96. __u32 id;
  97. union {
  98. struct iattr * attrs; /* UNCHECKED, GUARDED */
  99. nfs4_verifier verifier; /* EXCLUSIVE */
  100. nfs4_stateid delegation; /* CLAIM_DELEGATE_CUR */
  101. int delegation_type; /* CLAIM_PREVIOUS */
  102. } u;
  103. const struct qstr * name;
  104. const struct nfs_server *server; /* Needed for ID mapping */
  105. const u32 * bitmask;
  106. __u32 claim;
  107. };
  108. struct nfs_openres {
  109. nfs4_stateid stateid;
  110. struct nfs_fh fh;
  111. struct nfs4_change_info cinfo;
  112. __u32 rflags;
  113. struct nfs_fattr * f_attr;
  114. const struct nfs_server *server;
  115. int delegation_type;
  116. nfs4_stateid delegation;
  117. __u32 do_recall;
  118. __u64 maxsize;
  119. };
  120. /*
  121. * Arguments to the open_confirm call.
  122. */
  123. struct nfs_open_confirmargs {
  124. const struct nfs_fh * fh;
  125. nfs4_stateid stateid;
  126. __u32 seqid;
  127. };
  128. struct nfs_open_confirmres {
  129. nfs4_stateid stateid;
  130. };
  131. /*
  132. * Arguments to the close call.
  133. */
  134. struct nfs_closeargs {
  135. struct nfs_fh * fh;
  136. nfs4_stateid stateid;
  137. __u32 seqid;
  138. int open_flags;
  139. };
  140. struct nfs_closeres {
  141. nfs4_stateid stateid;
  142. };
  143. /*
  144. * * Arguments to the lock,lockt, and locku call.
  145. * */
  146. struct nfs_lowner {
  147. __u64 clientid;
  148. u32 id;
  149. };
  150. struct nfs_open_to_lock {
  151. __u32 open_seqid;
  152. nfs4_stateid open_stateid;
  153. __u32 lock_seqid;
  154. struct nfs_lowner lock_owner;
  155. };
  156. struct nfs_exist_lock {
  157. nfs4_stateid stateid;
  158. __u32 seqid;
  159. };
  160. struct nfs_lock_opargs {
  161. __u32 reclaim;
  162. __u32 new_lock_owner;
  163. union {
  164. struct nfs_open_to_lock *open_lock;
  165. struct nfs_exist_lock *exist_lock;
  166. } u;
  167. };
  168. struct nfs_locku_opargs {
  169. __u32 seqid;
  170. nfs4_stateid stateid;
  171. };
  172. struct nfs_lockargs {
  173. struct nfs_fh * fh;
  174. __u32 type;
  175. __u64 offset;
  176. __u64 length;
  177. union {
  178. struct nfs_lock_opargs *lock; /* LOCK */
  179. struct nfs_lowner *lockt; /* LOCKT */
  180. struct nfs_locku_opargs *locku; /* LOCKU */
  181. } u;
  182. };
  183. struct nfs_lock_denied {
  184. __u64 offset;
  185. __u64 length;
  186. __u32 type;
  187. struct nfs_lowner owner;
  188. };
  189. struct nfs_lockres {
  190. union {
  191. nfs4_stateid stateid;/* LOCK success, LOCKU */
  192. struct nfs_lock_denied denied; /* LOCK failed, LOCKT success */
  193. } u;
  194. const struct nfs_server * server;
  195. };
  196. struct nfs4_delegreturnargs {
  197. const struct nfs_fh *fhandle;
  198. const nfs4_stateid *stateid;
  199. };
  200. /*
  201. * Arguments to the read call.
  202. */
  203. #define NFS_READ_MAXIOV (9U)
  204. #if (NFS_READ_MAXIOV > (MAX_IOVEC -2))
  205. #error "NFS_READ_MAXIOV is too large"
  206. #endif
  207. struct nfs_readargs {
  208. struct nfs_fh * fh;
  209. struct nfs_open_context *context;
  210. __u64 offset;
  211. __u32 count;
  212. unsigned int pgbase;
  213. struct page ** pages;
  214. };
  215. struct nfs_readres {
  216. struct nfs_fattr * fattr;
  217. __u32 count;
  218. int eof;
  219. };
  220. /*
  221. * Arguments to the write call.
  222. */
  223. #define NFS_WRITE_MAXIOV (9U)
  224. #if (NFS_WRITE_MAXIOV > (MAX_IOVEC -2))
  225. #error "NFS_WRITE_MAXIOV is too large"
  226. #endif
  227. struct nfs_writeargs {
  228. struct nfs_fh * fh;
  229. struct nfs_open_context *context;
  230. __u64 offset;
  231. __u32 count;
  232. enum nfs3_stable_how stable;
  233. unsigned int pgbase;
  234. struct page ** pages;
  235. };
  236. struct nfs_writeverf {
  237. enum nfs3_stable_how committed;
  238. __u32 verifier[2];
  239. };
  240. struct nfs_writeres {
  241. struct nfs_fattr * fattr;
  242. struct nfs_writeverf * verf;
  243. __u32 count;
  244. };
  245. /*
  246. * Argument struct for decode_entry function
  247. */
  248. struct nfs_entry {
  249. __u64 ino;
  250. __u64 cookie,
  251. prev_cookie;
  252. const char * name;
  253. unsigned int len;
  254. int eof;
  255. struct nfs_fh * fh;
  256. struct nfs_fattr * fattr;
  257. };
  258. /*
  259. * The following types are for NFSv2 only.
  260. */
  261. struct nfs_sattrargs {
  262. struct nfs_fh * fh;
  263. struct iattr * sattr;
  264. };
  265. struct nfs_diropargs {
  266. struct nfs_fh * fh;
  267. const char * name;
  268. unsigned int len;
  269. };
  270. struct nfs_createargs {
  271. struct nfs_fh * fh;
  272. const char * name;
  273. unsigned int len;
  274. struct iattr * sattr;
  275. };
  276. struct nfs_renameargs {
  277. struct nfs_fh * fromfh;
  278. const char * fromname;
  279. unsigned int fromlen;
  280. struct nfs_fh * tofh;
  281. const char * toname;
  282. unsigned int tolen;
  283. };
  284. struct nfs_setattrargs {
  285. struct nfs_fh * fh;
  286. nfs4_stateid stateid;
  287. struct iattr * iap;
  288. const struct nfs_server * server; /* Needed for name mapping */
  289. const u32 * bitmask;
  290. };
  291. struct nfs_getaclargs {
  292. struct nfs_fh * fh;
  293. size_t acl_len;
  294. unsigned int acl_pgbase;
  295. struct page ** acl_pages;
  296. };
  297. struct nfs_setattrres {
  298. struct nfs_fattr * fattr;
  299. const struct nfs_server * server;
  300. };
  301. struct nfs_linkargs {
  302. struct nfs_fh * fromfh;
  303. struct nfs_fh * tofh;
  304. const char * toname;
  305. unsigned int tolen;
  306. };
  307. struct nfs_symlinkargs {
  308. struct nfs_fh * fromfh;
  309. const char * fromname;
  310. unsigned int fromlen;
  311. const char * topath;
  312. unsigned int tolen;
  313. struct iattr * sattr;
  314. };
  315. struct nfs_readdirargs {
  316. struct nfs_fh * fh;
  317. __u32 cookie;
  318. unsigned int count;
  319. struct page ** pages;
  320. };
  321. struct nfs_diropok {
  322. struct nfs_fh * fh;
  323. struct nfs_fattr * fattr;
  324. };
  325. struct nfs_readlinkargs {
  326. struct nfs_fh * fh;
  327. unsigned int pgbase;
  328. unsigned int pglen;
  329. struct page ** pages;
  330. };
  331. struct nfs3_sattrargs {
  332. struct nfs_fh * fh;
  333. struct iattr * sattr;
  334. unsigned int guard;
  335. struct timespec guardtime;
  336. };
  337. struct nfs3_diropargs {
  338. struct nfs_fh * fh;
  339. const char * name;
  340. unsigned int len;
  341. };
  342. struct nfs3_accessargs {
  343. struct nfs_fh * fh;
  344. __u32 access;
  345. };
  346. struct nfs3_createargs {
  347. struct nfs_fh * fh;
  348. const char * name;
  349. unsigned int len;
  350. struct iattr * sattr;
  351. enum nfs3_createmode createmode;
  352. __u32 verifier[2];
  353. };
  354. struct nfs3_mkdirargs {
  355. struct nfs_fh * fh;
  356. const char * name;
  357. unsigned int len;
  358. struct iattr * sattr;
  359. };
  360. struct nfs3_symlinkargs {
  361. struct nfs_fh * fromfh;
  362. const char * fromname;
  363. unsigned int fromlen;
  364. const char * topath;
  365. unsigned int tolen;
  366. struct iattr * sattr;
  367. };
  368. struct nfs3_mknodargs {
  369. struct nfs_fh * fh;
  370. const char * name;
  371. unsigned int len;
  372. enum nfs3_ftype type;
  373. struct iattr * sattr;
  374. dev_t rdev;
  375. };
  376. struct nfs3_renameargs {
  377. struct nfs_fh * fromfh;
  378. const char * fromname;
  379. unsigned int fromlen;
  380. struct nfs_fh * tofh;
  381. const char * toname;
  382. unsigned int tolen;
  383. };
  384. struct nfs3_linkargs {
  385. struct nfs_fh * fromfh;
  386. struct nfs_fh * tofh;
  387. const char * toname;
  388. unsigned int tolen;
  389. };
  390. struct nfs3_readdirargs {
  391. struct nfs_fh * fh;
  392. __u64 cookie;
  393. __u32 verf[2];
  394. int plus;
  395. unsigned int count;
  396. struct page ** pages;
  397. };
  398. struct nfs3_diropres {
  399. struct nfs_fattr * dir_attr;
  400. struct nfs_fh * fh;
  401. struct nfs_fattr * fattr;
  402. };
  403. struct nfs3_accessres {
  404. struct nfs_fattr * fattr;
  405. __u32 access;
  406. };
  407. struct nfs3_readlinkargs {
  408. struct nfs_fh * fh;
  409. unsigned int pgbase;
  410. unsigned int pglen;
  411. struct page ** pages;
  412. };
  413. struct nfs3_renameres {
  414. struct nfs_fattr * fromattr;
  415. struct nfs_fattr * toattr;
  416. };
  417. struct nfs3_linkres {
  418. struct nfs_fattr * dir_attr;
  419. struct nfs_fattr * fattr;
  420. };
  421. struct nfs3_readdirres {
  422. struct nfs_fattr * dir_attr;
  423. __u32 * verf;
  424. int plus;
  425. };
  426. #ifdef CONFIG_NFS_V4
  427. typedef u64 clientid4;
  428. struct nfs4_accessargs {
  429. const struct nfs_fh * fh;
  430. u32 access;
  431. };
  432. struct nfs4_accessres {
  433. u32 supported;
  434. u32 access;
  435. };
  436. struct nfs4_create_arg {
  437. u32 ftype;
  438. union {
  439. struct qstr * symlink; /* NF4LNK */
  440. struct {
  441. u32 specdata1;
  442. u32 specdata2;
  443. } device; /* NF4BLK, NF4CHR */
  444. } u;
  445. const struct qstr * name;
  446. const struct nfs_server * server;
  447. const struct iattr * attrs;
  448. const struct nfs_fh * dir_fh;
  449. const u32 * bitmask;
  450. };
  451. struct nfs4_create_res {
  452. const struct nfs_server * server;
  453. struct nfs_fh * fh;
  454. struct nfs_fattr * fattr;
  455. struct nfs4_change_info dir_cinfo;
  456. };
  457. struct nfs4_fsinfo_arg {
  458. const struct nfs_fh * fh;
  459. const u32 * bitmask;
  460. };
  461. struct nfs4_getattr_arg {
  462. const struct nfs_fh * fh;
  463. const u32 * bitmask;
  464. };
  465. struct nfs4_getattr_res {
  466. const struct nfs_server * server;
  467. struct nfs_fattr * fattr;
  468. };
  469. struct nfs4_link_arg {
  470. const struct nfs_fh * fh;
  471. const struct nfs_fh * dir_fh;
  472. const struct qstr * name;
  473. };
  474. struct nfs4_lookup_arg {
  475. const struct nfs_fh * dir_fh;
  476. const struct qstr * name;
  477. const u32 * bitmask;
  478. };
  479. struct nfs4_lookup_res {
  480. const struct nfs_server * server;
  481. struct nfs_fattr * fattr;
  482. struct nfs_fh * fh;
  483. };
  484. struct nfs4_lookup_root_arg {
  485. const u32 * bitmask;
  486. };
  487. struct nfs4_pathconf_arg {
  488. const struct nfs_fh * fh;
  489. const u32 * bitmask;
  490. };
  491. struct nfs4_readdir_arg {
  492. const struct nfs_fh * fh;
  493. u64 cookie;
  494. nfs4_verifier verifier;
  495. u32 count;
  496. struct page ** pages; /* zero-copy data */
  497. unsigned int pgbase; /* zero-copy data */
  498. const u32 * bitmask;
  499. };
  500. struct nfs4_readdir_res {
  501. nfs4_verifier verifier;
  502. unsigned int pgbase;
  503. };
  504. struct nfs4_readlink {
  505. const struct nfs_fh * fh;
  506. unsigned int pgbase;
  507. unsigned int pglen; /* zero-copy data */
  508. struct page ** pages; /* zero-copy data */
  509. };
  510. struct nfs4_remove_arg {
  511. const struct nfs_fh * fh;
  512. const struct qstr * name;
  513. };
  514. struct nfs4_rename_arg {
  515. const struct nfs_fh * old_dir;
  516. const struct nfs_fh * new_dir;
  517. const struct qstr * old_name;
  518. const struct qstr * new_name;
  519. };
  520. struct nfs4_rename_res {
  521. struct nfs4_change_info old_cinfo;
  522. struct nfs4_change_info new_cinfo;
  523. };
  524. struct nfs4_setclientid {
  525. const nfs4_verifier * sc_verifier; /* request */
  526. unsigned int sc_name_len;
  527. char sc_name[32]; /* request */
  528. u32 sc_prog; /* request */
  529. unsigned int sc_netid_len;
  530. char sc_netid[4]; /* request */
  531. unsigned int sc_uaddr_len;
  532. char sc_uaddr[24]; /* request */
  533. u32 sc_cb_ident; /* request */
  534. };
  535. struct nfs4_statfs_arg {
  536. const struct nfs_fh * fh;
  537. const u32 * bitmask;
  538. };
  539. struct nfs4_server_caps_res {
  540. u32 attr_bitmask[2];
  541. u32 acl_bitmask;
  542. u32 has_links;
  543. u32 has_symlinks;
  544. };
  545. #endif /* CONFIG_NFS_V4 */
  546. struct nfs_page;
  547. struct nfs_read_data {
  548. int flags;
  549. struct rpc_task task;
  550. struct inode *inode;
  551. struct rpc_cred *cred;
  552. struct nfs_fattr fattr; /* fattr storage */
  553. struct list_head pages; /* Coalesced read requests */
  554. struct nfs_page *req; /* multi ops per nfs_page */
  555. struct page *pagevec[NFS_READ_MAXIOV];
  556. struct nfs_readargs args;
  557. struct nfs_readres res;
  558. #ifdef CONFIG_NFS_V4
  559. unsigned long timestamp; /* For lease renewal */
  560. #endif
  561. void (*complete) (struct nfs_read_data *, int);
  562. };
  563. struct nfs_write_data {
  564. int flags;
  565. struct rpc_task task;
  566. struct inode *inode;
  567. struct rpc_cred *cred;
  568. struct nfs_fattr fattr;
  569. struct nfs_writeverf verf;
  570. struct list_head pages; /* Coalesced requests we wish to flush */
  571. struct nfs_page *req; /* multi ops per nfs_page */
  572. struct page *pagevec[NFS_WRITE_MAXIOV];
  573. struct nfs_writeargs args; /* argument struct */
  574. struct nfs_writeres res; /* result struct */
  575. #ifdef CONFIG_NFS_V4
  576. unsigned long timestamp; /* For lease renewal */
  577. #endif
  578. void (*complete) (struct nfs_write_data *, int);
  579. };
  580. struct nfs_access_entry;
  581. /*
  582. * RPC procedure vector for NFSv2/NFSv3 demuxing
  583. */
  584. struct nfs_rpc_ops {
  585. int version; /* Protocol version */
  586. struct dentry_operations *dentry_ops;
  587. struct inode_operations *dir_inode_ops;
  588. struct inode_operations *file_inode_ops;
  589. int (*getroot) (struct nfs_server *, struct nfs_fh *,
  590. struct nfs_fsinfo *);
  591. int (*getattr) (struct nfs_server *, struct nfs_fh *,
  592. struct nfs_fattr *);
  593. int (*setattr) (struct dentry *, struct nfs_fattr *,
  594. struct iattr *);
  595. int (*lookup) (struct inode *, struct qstr *,
  596. struct nfs_fh *, struct nfs_fattr *);
  597. int (*access) (struct inode *, struct nfs_access_entry *);
  598. int (*readlink)(struct inode *, struct page *, unsigned int,
  599. unsigned int);
  600. int (*read) (struct nfs_read_data *);
  601. int (*write) (struct nfs_write_data *);
  602. int (*commit) (struct nfs_write_data *);
  603. int (*create) (struct inode *, struct dentry *,
  604. struct iattr *, int);
  605. int (*remove) (struct inode *, struct qstr *);
  606. int (*unlink_setup) (struct rpc_message *,
  607. struct dentry *, struct qstr *);
  608. int (*unlink_done) (struct dentry *, struct rpc_task *);
  609. int (*rename) (struct inode *, struct qstr *,
  610. struct inode *, struct qstr *);
  611. int (*link) (struct inode *, struct inode *, struct qstr *);
  612. int (*symlink) (struct inode *, struct qstr *, struct qstr *,
  613. struct iattr *, struct nfs_fh *,
  614. struct nfs_fattr *);
  615. int (*mkdir) (struct inode *, struct dentry *, struct iattr *);
  616. int (*rmdir) (struct inode *, struct qstr *);
  617. int (*readdir) (struct dentry *, struct rpc_cred *,
  618. u64, struct page *, unsigned int, int);
  619. int (*mknod) (struct inode *, struct dentry *, struct iattr *,
  620. dev_t);
  621. int (*statfs) (struct nfs_server *, struct nfs_fh *,
  622. struct nfs_fsstat *);
  623. int (*fsinfo) (struct nfs_server *, struct nfs_fh *,
  624. struct nfs_fsinfo *);
  625. int (*pathconf) (struct nfs_server *, struct nfs_fh *,
  626. struct nfs_pathconf *);
  627. u32 * (*decode_dirent)(u32 *, struct nfs_entry *, int plus);
  628. void (*read_setup) (struct nfs_read_data *);
  629. void (*write_setup) (struct nfs_write_data *, int how);
  630. void (*commit_setup) (struct nfs_write_data *, int how);
  631. int (*file_open) (struct inode *, struct file *);
  632. int (*file_release) (struct inode *, struct file *);
  633. int (*lock)(struct file *, int, struct file_lock *);
  634. void (*clear_acl_cache)(struct inode *);
  635. };
  636. /*
  637. * NFS_CALL(getattr, inode, (fattr));
  638. * into
  639. * NFS_PROTO(inode)->getattr(fattr);
  640. */
  641. #define NFS_CALL(op, inode, args) NFS_PROTO(inode)->op args
  642. /*
  643. * Function vectors etc. for the NFS client
  644. */
  645. extern struct nfs_rpc_ops nfs_v2_clientops;
  646. extern struct nfs_rpc_ops nfs_v3_clientops;
  647. extern struct nfs_rpc_ops nfs_v4_clientops;
  648. extern struct rpc_version nfs_version2;
  649. extern struct rpc_version nfs_version3;
  650. extern struct rpc_version nfs_version4;
  651. #endif