nfs.h 25 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102
  1. /*
  2. * Please do not edit this file.
  3. * It was generated using rpcgen.
  4. */
  5. #ifndef _NFS_H_RPCGEN
  6. #define _NFS_H_RPCGEN
  7. #include <rpc/rpc.h>
  8. #ifdef __cplusplus
  9. extern "C" {
  10. #endif
  11. /* This file is copied from RFC1813
  12. * Copyright 1995 Sun Micrososystems (I assume)
  13. */
  14. #define NFS3_FHSIZE 64
  15. #define NFS3_COOKIEVERFSIZE 8
  16. #define NFS3_CREATEVERFSIZE 8
  17. #define NFS3_WRITEVERFSIZE 8
  18. #define ACCESS3_READ 0x0001
  19. #define ACCESS3_LOOKUP 0x0002
  20. #define ACCESS3_MODIFY 0x0004
  21. #define ACCESS3_EXTEND 0x0008
  22. #define ACCESS3_DELETE 0x0010
  23. #define ACCESS3_EXECUTE 0x0020
  24. #define FSF3_LINK 0x0001
  25. #define FSF3_SYMLINK 0x0002
  26. #define FSF3_HOMOGENEOUS 0x0008
  27. #define FSF3_CANSETTIME 0x0010
  28. typedef unsigned long long uint64;
  29. typedef long long int64;
  30. typedef u_long uint32;
  31. typedef long int32;
  32. typedef char *filename3;
  33. typedef char *nfspath3;
  34. typedef uint64 fileid3;
  35. typedef uint64 cookie3;
  36. typedef char cookieverf3[NFS3_COOKIEVERFSIZE];
  37. typedef char createverf3[NFS3_CREATEVERFSIZE];
  38. typedef char writeverf3[NFS3_WRITEVERFSIZE];
  39. typedef uint32 uid3;
  40. typedef uint32 gid3;
  41. typedef uint64 size3;
  42. typedef uint64 offset3;
  43. typedef uint32 mode3;
  44. typedef uint32 count3;
  45. enum nfsstat3 {
  46. NFS3_OK = 0,
  47. NFS3ERR_PERM = 1,
  48. NFS3ERR_NOENT = 2,
  49. NFS3ERR_IO = 5,
  50. NFS3ERR_NXIO = 6,
  51. NFS3ERR_ACCES = 13,
  52. NFS3ERR_EXIST = 17,
  53. NFS3ERR_XDEV = 18,
  54. NFS3ERR_NODEV = 19,
  55. NFS3ERR_NOTDIR = 20,
  56. NFS3ERR_ISDIR = 21,
  57. NFS3ERR_INVAL = 22,
  58. NFS3ERR_FBIG = 27,
  59. NFS3ERR_NOSPC = 28,
  60. NFS3ERR_ROFS = 30,
  61. NFS3ERR_MLINK = 31,
  62. NFS3ERR_NAMETOOLONG = 63,
  63. NFS3ERR_NOTEMPTY = 66,
  64. NFS3ERR_DQUOT = 69,
  65. NFS3ERR_STALE = 70,
  66. NFS3ERR_REMOTE = 71,
  67. NFS3ERR_BADHANDLE = 10001,
  68. NFS3ERR_NOT_SYNC = 10002,
  69. NFS3ERR_BAD_COOKIE = 10003,
  70. NFS3ERR_NOTSUPP = 10004,
  71. NFS3ERR_TOOSMALL = 10005,
  72. NFS3ERR_SERVERFAULT = 10006,
  73. NFS3ERR_BADTYPE = 10007,
  74. NFS3ERR_JUKEBOX = 10008
  75. };
  76. typedef enum nfsstat3 nfsstat3;
  77. enum ftype3 {
  78. NFS3REG = 1,
  79. NFS3DIR = 2,
  80. NFS3BLK = 3,
  81. NFS3CHR = 4,
  82. NFS3LNK = 5,
  83. NFS3SOCK = 6,
  84. NFS3FIFO = 7
  85. };
  86. typedef enum ftype3 ftype3;
  87. enum stable_how {
  88. UNSTABLE = 0,
  89. DATA_SYNC = 1,
  90. FILE_SYNC = 2
  91. };
  92. typedef enum stable_how stable_how;
  93. enum createmode3 {
  94. UNCHECKED = 0,
  95. GUARDED = 1,
  96. EXCLUSIVE = 2
  97. };
  98. typedef enum createmode3 createmode3;
  99. struct specdata3 {
  100. uint32 specdata1;
  101. uint32 specdata2;
  102. };
  103. typedef struct specdata3 specdata3;
  104. struct nfs_fh3 {
  105. struct {
  106. u_int data_len;
  107. char *data_val;
  108. } data;
  109. };
  110. typedef struct nfs_fh3 nfs_fh3;
  111. struct nfstime3 {
  112. uint32 seconds;
  113. uint32 nseconds;
  114. };
  115. typedef struct nfstime3 nfstime3;
  116. struct fattr3 {
  117. ftype3 type;
  118. mode3 mode;
  119. uint32 nlink;
  120. uid3 uid;
  121. gid3 gid;
  122. size3 size;
  123. size3 used;
  124. specdata3 rdev;
  125. uint64 fsid;
  126. fileid3 fileid;
  127. nfstime3 atime;
  128. nfstime3 mtime;
  129. nfstime3 ctime;
  130. };
  131. typedef struct fattr3 fattr3;
  132. struct post_op_attr {
  133. bool_t attributes_follow;
  134. union {
  135. fattr3 attributes;
  136. } post_op_attr_u;
  137. };
  138. typedef struct post_op_attr post_op_attr;
  139. struct wcc_attr {
  140. size3 size;
  141. nfstime3 mtime;
  142. nfstime3 ctime;
  143. };
  144. typedef struct wcc_attr wcc_attr;
  145. struct pre_op_attr {
  146. bool_t attributes_follow;
  147. union {
  148. wcc_attr attributes;
  149. } pre_op_attr_u;
  150. };
  151. typedef struct pre_op_attr pre_op_attr;
  152. struct wcc_data {
  153. pre_op_attr before;
  154. post_op_attr after;
  155. };
  156. typedef struct wcc_data wcc_data;
  157. struct post_op_fh3 {
  158. bool_t handle_follows;
  159. union {
  160. nfs_fh3 handle;
  161. } post_op_fh3_u;
  162. };
  163. typedef struct post_op_fh3 post_op_fh3;
  164. enum time_how {
  165. DONT_CHANGE = 0,
  166. SET_TO_SERVER_TIME = 1,
  167. SET_TO_CLIENT_TIME = 2
  168. };
  169. typedef enum time_how time_how;
  170. struct set_mode3 {
  171. bool_t set_it;
  172. union {
  173. mode3 mode;
  174. } set_mode3_u;
  175. };
  176. typedef struct set_mode3 set_mode3;
  177. struct set_uid3 {
  178. bool_t set_it;
  179. union {
  180. uid3 uid;
  181. } set_uid3_u;
  182. };
  183. typedef struct set_uid3 set_uid3;
  184. struct set_gid3 {
  185. bool_t set_it;
  186. union {
  187. gid3 gid;
  188. } set_gid3_u;
  189. };
  190. typedef struct set_gid3 set_gid3;
  191. struct set_size3 {
  192. bool_t set_it;
  193. union {
  194. size3 size;
  195. } set_size3_u;
  196. };
  197. typedef struct set_size3 set_size3;
  198. struct set_atime {
  199. time_how set_it;
  200. union {
  201. nfstime3 atime;
  202. } set_atime_u;
  203. };
  204. typedef struct set_atime set_atime;
  205. struct set_mtime {
  206. time_how set_it;
  207. union {
  208. nfstime3 mtime;
  209. } set_mtime_u;
  210. };
  211. typedef struct set_mtime set_mtime;
  212. struct sattr3 {
  213. set_mode3 mode;
  214. set_uid3 uid;
  215. set_gid3 gid;
  216. set_size3 size;
  217. set_atime atime;
  218. set_mtime mtime;
  219. };
  220. typedef struct sattr3 sattr3;
  221. struct diropargs3 {
  222. nfs_fh3 dir;
  223. filename3 name;
  224. };
  225. typedef struct diropargs3 diropargs3;
  226. struct GETATTR3args {
  227. nfs_fh3 object;
  228. };
  229. typedef struct GETATTR3args GETATTR3args;
  230. struct GETATTR3resok {
  231. fattr3 obj_attributes;
  232. };
  233. typedef struct GETATTR3resok GETATTR3resok;
  234. struct GETATTR3res {
  235. nfsstat3 status;
  236. union {
  237. GETATTR3resok resok;
  238. } GETATTR3res_u;
  239. };
  240. typedef struct GETATTR3res GETATTR3res;
  241. struct sattrguard3 {
  242. bool_t check;
  243. union {
  244. nfstime3 obj_ctime;
  245. } sattrguard3_u;
  246. };
  247. typedef struct sattrguard3 sattrguard3;
  248. struct SETATTR3args {
  249. nfs_fh3 object;
  250. sattr3 new_attributes;
  251. sattrguard3 guard;
  252. };
  253. typedef struct SETATTR3args SETATTR3args;
  254. struct SETATTR3resok {
  255. wcc_data obj_wcc;
  256. };
  257. typedef struct SETATTR3resok SETATTR3resok;
  258. struct SETATTR3resfail {
  259. wcc_data obj_wcc;
  260. };
  261. typedef struct SETATTR3resfail SETATTR3resfail;
  262. struct SETATTR3res {
  263. nfsstat3 status;
  264. union {
  265. SETATTR3resok resok;
  266. SETATTR3resfail resfail;
  267. } SETATTR3res_u;
  268. };
  269. typedef struct SETATTR3res SETATTR3res;
  270. struct LOOKUP3args {
  271. diropargs3 what;
  272. };
  273. typedef struct LOOKUP3args LOOKUP3args;
  274. struct LOOKUP3resok {
  275. nfs_fh3 object;
  276. post_op_attr obj_attributes;
  277. post_op_attr dir_attributes;
  278. };
  279. typedef struct LOOKUP3resok LOOKUP3resok;
  280. struct LOOKUP3resfail {
  281. post_op_attr dir_attributes;
  282. };
  283. typedef struct LOOKUP3resfail LOOKUP3resfail;
  284. struct LOOKUP3res {
  285. nfsstat3 status;
  286. union {
  287. LOOKUP3resok resok;
  288. LOOKUP3resfail resfail;
  289. } LOOKUP3res_u;
  290. };
  291. typedef struct LOOKUP3res LOOKUP3res;
  292. struct ACCESS3args {
  293. nfs_fh3 object;
  294. uint32 access;
  295. };
  296. typedef struct ACCESS3args ACCESS3args;
  297. struct ACCESS3resok {
  298. post_op_attr obj_attributes;
  299. uint32 access;
  300. };
  301. typedef struct ACCESS3resok ACCESS3resok;
  302. struct ACCESS3resfail {
  303. post_op_attr obj_attributes;
  304. };
  305. typedef struct ACCESS3resfail ACCESS3resfail;
  306. struct ACCESS3res {
  307. nfsstat3 status;
  308. union {
  309. ACCESS3resok resok;
  310. ACCESS3resfail resfail;
  311. } ACCESS3res_u;
  312. };
  313. typedef struct ACCESS3res ACCESS3res;
  314. struct READLINK3args {
  315. nfs_fh3 symlink;
  316. };
  317. typedef struct READLINK3args READLINK3args;
  318. struct READLINK3resok {
  319. post_op_attr symlink_attributes;
  320. nfspath3 data;
  321. };
  322. typedef struct READLINK3resok READLINK3resok;
  323. struct READLINK3resfail {
  324. post_op_attr symlink_attributes;
  325. };
  326. typedef struct READLINK3resfail READLINK3resfail;
  327. struct READLINK3res {
  328. nfsstat3 status;
  329. union {
  330. READLINK3resok resok;
  331. READLINK3resfail resfail;
  332. } READLINK3res_u;
  333. };
  334. typedef struct READLINK3res READLINK3res;
  335. struct READ3args {
  336. nfs_fh3 file;
  337. offset3 offset;
  338. count3 count;
  339. };
  340. typedef struct READ3args READ3args;
  341. struct READ3resok {
  342. post_op_attr file_attributes;
  343. count3 count;
  344. bool_t eof;
  345. struct {
  346. u_int data_len;
  347. char *data_val;
  348. } data;
  349. };
  350. typedef struct READ3resok READ3resok;
  351. struct READ3resfail {
  352. post_op_attr file_attributes;
  353. };
  354. typedef struct READ3resfail READ3resfail;
  355. struct READ3res {
  356. nfsstat3 status;
  357. union {
  358. READ3resok resok;
  359. READ3resfail resfail;
  360. } READ3res_u;
  361. };
  362. typedef struct READ3res READ3res;
  363. struct WRITE3args {
  364. nfs_fh3 file;
  365. offset3 offset;
  366. count3 count;
  367. stable_how stable;
  368. struct {
  369. u_int data_len;
  370. char *data_val;
  371. } data;
  372. };
  373. typedef struct WRITE3args WRITE3args;
  374. struct WRITE3resok {
  375. wcc_data file_wcc;
  376. count3 count;
  377. stable_how committed;
  378. writeverf3 verf;
  379. };
  380. typedef struct WRITE3resok WRITE3resok;
  381. struct WRITE3resfail {
  382. wcc_data file_wcc;
  383. };
  384. typedef struct WRITE3resfail WRITE3resfail;
  385. struct WRITE3res {
  386. nfsstat3 status;
  387. union {
  388. WRITE3resok resok;
  389. WRITE3resfail resfail;
  390. } WRITE3res_u;
  391. };
  392. typedef struct WRITE3res WRITE3res;
  393. struct createhow3 {
  394. createmode3 mode;
  395. union {
  396. sattr3 obj_attributes;
  397. createverf3 verf;
  398. } createhow3_u;
  399. };
  400. typedef struct createhow3 createhow3;
  401. struct CREATE3args {
  402. diropargs3 where;
  403. createhow3 how;
  404. };
  405. typedef struct CREATE3args CREATE3args;
  406. struct CREATE3resok {
  407. post_op_fh3 obj;
  408. post_op_attr obj_attributes;
  409. wcc_data dir_wcc;
  410. };
  411. typedef struct CREATE3resok CREATE3resok;
  412. struct CREATE3resfail {
  413. wcc_data dir_wcc;
  414. };
  415. typedef struct CREATE3resfail CREATE3resfail;
  416. struct CREATE3res {
  417. nfsstat3 status;
  418. union {
  419. CREATE3resok resok;
  420. CREATE3resfail resfail;
  421. } CREATE3res_u;
  422. };
  423. typedef struct CREATE3res CREATE3res;
  424. struct MKDIR3args {
  425. diropargs3 where;
  426. sattr3 attributes;
  427. };
  428. typedef struct MKDIR3args MKDIR3args;
  429. struct MKDIR3resok {
  430. post_op_fh3 obj;
  431. post_op_attr obj_attributes;
  432. wcc_data dir_wcc;
  433. };
  434. typedef struct MKDIR3resok MKDIR3resok;
  435. struct MKDIR3resfail {
  436. wcc_data dir_wcc;
  437. };
  438. typedef struct MKDIR3resfail MKDIR3resfail;
  439. struct MKDIR3res {
  440. nfsstat3 status;
  441. union {
  442. MKDIR3resok resok;
  443. MKDIR3resfail resfail;
  444. } MKDIR3res_u;
  445. };
  446. typedef struct MKDIR3res MKDIR3res;
  447. struct symlinkdata3 {
  448. sattr3 symlink_attributes;
  449. nfspath3 symlink_data;
  450. };
  451. typedef struct symlinkdata3 symlinkdata3;
  452. struct SYMLINK3args {
  453. diropargs3 where;
  454. symlinkdata3 symlink;
  455. };
  456. typedef struct SYMLINK3args SYMLINK3args;
  457. struct SYMLINK3resok {
  458. post_op_fh3 obj;
  459. post_op_attr obj_attributes;
  460. wcc_data dir_wcc;
  461. };
  462. typedef struct SYMLINK3resok SYMLINK3resok;
  463. struct SYMLINK3resfail {
  464. wcc_data dir_wcc;
  465. };
  466. typedef struct SYMLINK3resfail SYMLINK3resfail;
  467. struct SYMLINK3res {
  468. nfsstat3 status;
  469. union {
  470. SYMLINK3resok resok;
  471. SYMLINK3resfail resfail;
  472. } SYMLINK3res_u;
  473. };
  474. typedef struct SYMLINK3res SYMLINK3res;
  475. struct devicedata3 {
  476. sattr3 dev_attributes;
  477. specdata3 spec;
  478. };
  479. typedef struct devicedata3 devicedata3;
  480. struct mknoddata3 {
  481. ftype3 type;
  482. union {
  483. devicedata3 device;
  484. sattr3 pipe_attributes;
  485. } mknoddata3_u;
  486. };
  487. typedef struct mknoddata3 mknoddata3;
  488. struct MKNOD3args {
  489. diropargs3 where;
  490. mknoddata3 what;
  491. };
  492. typedef struct MKNOD3args MKNOD3args;
  493. struct MKNOD3resok {
  494. post_op_fh3 obj;
  495. post_op_attr obj_attributes;
  496. wcc_data dir_wcc;
  497. };
  498. typedef struct MKNOD3resok MKNOD3resok;
  499. struct MKNOD3resfail {
  500. wcc_data dir_wcc;
  501. };
  502. typedef struct MKNOD3resfail MKNOD3resfail;
  503. struct MKNOD3res {
  504. nfsstat3 status;
  505. union {
  506. MKNOD3resok resok;
  507. MKNOD3resfail resfail;
  508. } MKNOD3res_u;
  509. };
  510. typedef struct MKNOD3res MKNOD3res;
  511. struct REMOVE3args {
  512. diropargs3 object;
  513. };
  514. typedef struct REMOVE3args REMOVE3args;
  515. struct REMOVE3resok {
  516. wcc_data dir_wcc;
  517. };
  518. typedef struct REMOVE3resok REMOVE3resok;
  519. struct REMOVE3resfail {
  520. wcc_data dir_wcc;
  521. };
  522. typedef struct REMOVE3resfail REMOVE3resfail;
  523. struct REMOVE3res {
  524. nfsstat3 status;
  525. union {
  526. REMOVE3resok resok;
  527. REMOVE3resfail resfail;
  528. } REMOVE3res_u;
  529. };
  530. typedef struct REMOVE3res REMOVE3res;
  531. struct RMDIR3args {
  532. diropargs3 object;
  533. };
  534. typedef struct RMDIR3args RMDIR3args;
  535. struct RMDIR3resok {
  536. wcc_data dir_wcc;
  537. };
  538. typedef struct RMDIR3resok RMDIR3resok;
  539. struct RMDIR3resfail {
  540. wcc_data dir_wcc;
  541. };
  542. typedef struct RMDIR3resfail RMDIR3resfail;
  543. struct RMDIR3res {
  544. nfsstat3 status;
  545. union {
  546. RMDIR3resok resok;
  547. RMDIR3resfail resfail;
  548. } RMDIR3res_u;
  549. };
  550. typedef struct RMDIR3res RMDIR3res;
  551. struct RENAME3args {
  552. diropargs3 from;
  553. diropargs3 to;
  554. };
  555. typedef struct RENAME3args RENAME3args;
  556. struct RENAME3resok {
  557. wcc_data fromdir_wcc;
  558. wcc_data todir_wcc;
  559. };
  560. typedef struct RENAME3resok RENAME3resok;
  561. struct RENAME3resfail {
  562. wcc_data fromdir_wcc;
  563. wcc_data todir_wcc;
  564. };
  565. typedef struct RENAME3resfail RENAME3resfail;
  566. struct RENAME3res {
  567. nfsstat3 status;
  568. union {
  569. RENAME3resok resok;
  570. RENAME3resfail resfail;
  571. } RENAME3res_u;
  572. };
  573. typedef struct RENAME3res RENAME3res;
  574. struct LINK3args {
  575. nfs_fh3 file;
  576. diropargs3 link;
  577. };
  578. typedef struct LINK3args LINK3args;
  579. struct LINK3resok {
  580. post_op_attr file_attributes;
  581. wcc_data linkdir_wcc;
  582. };
  583. typedef struct LINK3resok LINK3resok;
  584. struct LINK3resfail {
  585. post_op_attr file_attributes;
  586. wcc_data linkdir_wcc;
  587. };
  588. typedef struct LINK3resfail LINK3resfail;
  589. struct LINK3res {
  590. nfsstat3 status;
  591. union {
  592. LINK3resok resok;
  593. LINK3resfail resfail;
  594. } LINK3res_u;
  595. };
  596. typedef struct LINK3res LINK3res;
  597. struct READDIR3args {
  598. nfs_fh3 dir;
  599. cookie3 cookie;
  600. cookieverf3 cookieverf;
  601. count3 count;
  602. };
  603. typedef struct READDIR3args READDIR3args;
  604. struct entry3 {
  605. fileid3 fileid;
  606. filename3 name;
  607. cookie3 cookie;
  608. struct entry3 *nextentry;
  609. };
  610. typedef struct entry3 entry3;
  611. struct dirlist3 {
  612. entry3 *entries;
  613. bool_t eof;
  614. };
  615. typedef struct dirlist3 dirlist3;
  616. struct READDIR3resok {
  617. post_op_attr dir_attributes;
  618. cookieverf3 cookieverf;
  619. dirlist3 reply;
  620. };
  621. typedef struct READDIR3resok READDIR3resok;
  622. struct READDIR3resfail {
  623. post_op_attr dir_attributes;
  624. };
  625. typedef struct READDIR3resfail READDIR3resfail;
  626. struct READDIR3res {
  627. nfsstat3 status;
  628. union {
  629. READDIR3resok resok;
  630. READDIR3resfail resfail;
  631. } READDIR3res_u;
  632. };
  633. typedef struct READDIR3res READDIR3res;
  634. struct READDIRPLUS3args {
  635. nfs_fh3 dir;
  636. cookie3 cookie;
  637. cookieverf3 cookieverf;
  638. count3 dircount;
  639. count3 maxcount;
  640. };
  641. typedef struct READDIRPLUS3args READDIRPLUS3args;
  642. struct entryplus3 {
  643. fileid3 fileid;
  644. filename3 name;
  645. cookie3 cookie;
  646. post_op_attr name_attributes;
  647. post_op_fh3 name_handle;
  648. struct entryplus3 *nextentry;
  649. };
  650. typedef struct entryplus3 entryplus3;
  651. struct dirlistplus3 {
  652. entryplus3 *entries;
  653. bool_t eof;
  654. };
  655. typedef struct dirlistplus3 dirlistplus3;
  656. struct READDIRPLUS3resok {
  657. post_op_attr dir_attributes;
  658. cookieverf3 cookieverf;
  659. dirlistplus3 reply;
  660. };
  661. typedef struct READDIRPLUS3resok READDIRPLUS3resok;
  662. struct READDIRPLUS3resfail {
  663. post_op_attr dir_attributes;
  664. };
  665. typedef struct READDIRPLUS3resfail READDIRPLUS3resfail;
  666. struct READDIRPLUS3res {
  667. nfsstat3 status;
  668. union {
  669. READDIRPLUS3resok resok;
  670. READDIRPLUS3resfail resfail;
  671. } READDIRPLUS3res_u;
  672. };
  673. typedef struct READDIRPLUS3res READDIRPLUS3res;
  674. struct FSSTAT3args {
  675. nfs_fh3 fsroot;
  676. };
  677. typedef struct FSSTAT3args FSSTAT3args;
  678. struct FSSTAT3resok {
  679. post_op_attr obj_attributes;
  680. size3 tbytes;
  681. size3 fbytes;
  682. size3 abytes;
  683. size3 tfiles;
  684. size3 ffiles;
  685. size3 afiles;
  686. uint32 invarsec;
  687. };
  688. typedef struct FSSTAT3resok FSSTAT3resok;
  689. struct FSSTAT3resfail {
  690. post_op_attr obj_attributes;
  691. };
  692. typedef struct FSSTAT3resfail FSSTAT3resfail;
  693. struct FSSTAT3res {
  694. nfsstat3 status;
  695. union {
  696. FSSTAT3resok resok;
  697. FSSTAT3resfail resfail;
  698. } FSSTAT3res_u;
  699. };
  700. typedef struct FSSTAT3res FSSTAT3res;
  701. struct FSINFO3args {
  702. nfs_fh3 fsroot;
  703. };
  704. typedef struct FSINFO3args FSINFO3args;
  705. struct FSINFO3resok {
  706. post_op_attr obj_attributes;
  707. uint32 rtmax;
  708. uint32 rtpref;
  709. uint32 rtmult;
  710. uint32 wtmax;
  711. uint32 wtpref;
  712. uint32 wtmult;
  713. uint32 dtpref;
  714. size3 maxfilesize;
  715. nfstime3 time_delta;
  716. uint32 properties;
  717. };
  718. typedef struct FSINFO3resok FSINFO3resok;
  719. struct FSINFO3resfail {
  720. post_op_attr obj_attributes;
  721. };
  722. typedef struct FSINFO3resfail FSINFO3resfail;
  723. struct FSINFO3res {
  724. nfsstat3 status;
  725. union {
  726. FSINFO3resok resok;
  727. FSINFO3resfail resfail;
  728. } FSINFO3res_u;
  729. };
  730. typedef struct FSINFO3res FSINFO3res;
  731. struct PATHCONF3args {
  732. nfs_fh3 object;
  733. };
  734. typedef struct PATHCONF3args PATHCONF3args;
  735. struct PATHCONF3resok {
  736. post_op_attr obj_attributes;
  737. uint32 linkmax;
  738. uint32 name_max;
  739. bool_t no_trunc;
  740. bool_t chown_restricted;
  741. bool_t case_insensitive;
  742. bool_t case_preserving;
  743. };
  744. typedef struct PATHCONF3resok PATHCONF3resok;
  745. struct PATHCONF3resfail {
  746. post_op_attr obj_attributes;
  747. };
  748. typedef struct PATHCONF3resfail PATHCONF3resfail;
  749. struct PATHCONF3res {
  750. nfsstat3 status;
  751. union {
  752. PATHCONF3resok resok;
  753. PATHCONF3resfail resfail;
  754. } PATHCONF3res_u;
  755. };
  756. typedef struct PATHCONF3res PATHCONF3res;
  757. struct COMMIT3args {
  758. nfs_fh3 file;
  759. offset3 offset;
  760. count3 count;
  761. };
  762. typedef struct COMMIT3args COMMIT3args;
  763. struct COMMIT3resok {
  764. wcc_data file_wcc;
  765. writeverf3 verf;
  766. };
  767. typedef struct COMMIT3resok COMMIT3resok;
  768. struct COMMIT3resfail {
  769. wcc_data file_wcc;
  770. };
  771. typedef struct COMMIT3resfail COMMIT3resfail;
  772. struct COMMIT3res {
  773. nfsstat3 status;
  774. union {
  775. COMMIT3resok resok;
  776. COMMIT3resfail resfail;
  777. } COMMIT3res_u;
  778. };
  779. typedef struct COMMIT3res COMMIT3res;
  780. #define NFS_PROGRAM 100003
  781. #define NFS_V3 3
  782. #define NFSPROC3_NULL 0
  783. extern enum clnt_stat nfsproc3_null_3(void *, CLIENT *);
  784. #define NFSPROC3_GETATTR 1
  785. extern enum clnt_stat nfsproc3_getattr_3(GETATTR3args , GETATTR3res *, CLIENT *);
  786. #define NFSPROC3_SETATTR 2
  787. extern enum clnt_stat nfsproc3_setattr_3(SETATTR3args , SETATTR3res *, CLIENT *);
  788. #define NFSPROC3_LOOKUP 3
  789. extern enum clnt_stat nfsproc3_lookup_3(LOOKUP3args , LOOKUP3res *, CLIENT *);
  790. #define NFSPROC3_ACCESS 4
  791. extern enum clnt_stat nfsproc3_access_3(ACCESS3args , ACCESS3res *, CLIENT *);
  792. #define NFSPROC3_READLINK 5
  793. extern enum clnt_stat nfsproc3_readlink_3(READLINK3args , READLINK3res *, CLIENT *);
  794. #define NFSPROC3_READ 6
  795. extern enum clnt_stat nfsproc3_read_3(READ3args , READ3res *, CLIENT *);
  796. #define NFSPROC3_WRITE 7
  797. extern enum clnt_stat nfsproc3_write_3(WRITE3args , WRITE3res *, CLIENT *);
  798. #define NFSPROC3_CREATE 8
  799. extern enum clnt_stat nfsproc3_create_3(CREATE3args , CREATE3res *, CLIENT *);
  800. #define NFSPROC3_MKDIR 9
  801. extern enum clnt_stat nfsproc3_mkdir_3(MKDIR3args , MKDIR3res *, CLIENT *);
  802. #define NFSPROC3_SYMLINK 10
  803. extern enum clnt_stat nfsproc3_symlink_3(SYMLINK3args , SYMLINK3res *, CLIENT *);
  804. #define NFSPROC3_MKNOD 11
  805. extern enum clnt_stat nfsproc3_mknod_3(MKNOD3args , MKNOD3res *, CLIENT *);
  806. #define NFSPROC3_REMOVE 12
  807. extern enum clnt_stat nfsproc3_remove_3(REMOVE3args , REMOVE3res *, CLIENT *);
  808. #define NFSPROC3_RMDIR 13
  809. extern enum clnt_stat nfsproc3_rmdir_3(RMDIR3args , RMDIR3res *, CLIENT *);
  810. #define NFSPROC3_RENAME 14
  811. extern enum clnt_stat nfsproc3_rename_3(RENAME3args , RENAME3res *, CLIENT *);
  812. #define NFSPROC3_LINK 15
  813. extern enum clnt_stat nfsproc3_link_3(LINK3args , LINK3res *, CLIENT *);
  814. #define NFSPROC3_READDIR 16
  815. extern enum clnt_stat nfsproc3_readdir_3(READDIR3args , READDIR3res *, CLIENT *);
  816. #define NFSPROC3_READDIRPLUS 17
  817. extern enum clnt_stat nfsproc3_readdirplus_3(READDIRPLUS3args , READDIRPLUS3res *, CLIENT *);
  818. #define NFSPROC3_FSSTAT 18
  819. extern enum clnt_stat nfsproc3_fsstat_3(FSSTAT3args , FSSTAT3res *, CLIENT *);
  820. #define NFSPROC3_FSINFO 19
  821. extern enum clnt_stat nfsproc3_fsinfo_3(FSINFO3args , FSINFO3res *, CLIENT *);
  822. #define NFSPROC3_PATHCONF 20
  823. extern enum clnt_stat nfsproc3_pathconf_3(PATHCONF3args , PATHCONF3res *, CLIENT *);
  824. #define NFSPROC3_COMMIT 21
  825. extern enum clnt_stat nfsproc3_commit_3(COMMIT3args , COMMIT3res *, CLIENT *);
  826. /* the xdr functions */
  827. extern bool_t xdr_uint64(XDR *, uint64*);
  828. extern bool_t xdr_int64(XDR *, int64*);
  829. extern bool_t xdr_uint32(XDR *, uint32*);
  830. extern bool_t xdr_int32(XDR *, int32*);
  831. extern bool_t xdr_filename3(XDR *, filename3*);
  832. extern bool_t xdr_nfspath3(XDR *, nfspath3*);
  833. extern bool_t xdr_fileid3(XDR *, fileid3*);
  834. extern bool_t xdr_cookie3(XDR *, cookie3*);
  835. extern bool_t xdr_cookieverf3(XDR *, cookieverf3);
  836. extern bool_t xdr_createverf3(XDR *, createverf3);
  837. extern bool_t xdr_writeverf3(XDR *, writeverf3);
  838. extern bool_t xdr_uid3(XDR *, uid3*);
  839. extern bool_t xdr_gid3(XDR *, gid3*);
  840. extern bool_t xdr_size3(XDR *, size3*);
  841. extern bool_t xdr_offset3(XDR *, offset3*);
  842. extern bool_t xdr_mode3(XDR *, mode3*);
  843. extern bool_t xdr_count3(XDR *, count3*);
  844. extern bool_t xdr_nfsstat3(XDR *, nfsstat3*);
  845. extern bool_t xdr_ftype3(XDR *, ftype3*);
  846. extern bool_t xdr_stable_how(XDR *, stable_how*);
  847. extern bool_t xdr_createmode3(XDR *, createmode3*);
  848. extern bool_t xdr_specdata3(XDR *, specdata3*);
  849. extern bool_t xdr_nfs_fh3(XDR *, nfs_fh3*);
  850. extern bool_t xdr_nfstime3(XDR *, nfstime3*);
  851. extern bool_t xdr_fattr3(XDR *, fattr3*);
  852. extern bool_t xdr_post_op_attr(XDR *, post_op_attr*);
  853. extern bool_t xdr_wcc_attr(XDR *, wcc_attr*);
  854. extern bool_t xdr_pre_op_attr(XDR *, pre_op_attr*);
  855. extern bool_t xdr_wcc_data(XDR *, wcc_data*);
  856. extern bool_t xdr_post_op_fh3(XDR *, post_op_fh3*);
  857. extern bool_t xdr_time_how(XDR *, time_how*);
  858. extern bool_t xdr_set_mode3(XDR *, set_mode3*);
  859. extern bool_t xdr_set_uid3(XDR *, set_uid3*);
  860. extern bool_t xdr_set_gid3(XDR *, set_gid3*);
  861. extern bool_t xdr_set_size3(XDR *, set_size3*);
  862. extern bool_t xdr_set_atime(XDR *, set_atime*);
  863. extern bool_t xdr_set_mtime(XDR *, set_mtime*);
  864. extern bool_t xdr_sattr3(XDR *, sattr3*);
  865. extern bool_t xdr_diropargs3(XDR *, diropargs3*);
  866. extern bool_t xdr_GETATTR3args(XDR *, GETATTR3args*);
  867. extern bool_t xdr_GETATTR3resok(XDR *, GETATTR3resok*);
  868. extern bool_t xdr_GETATTR3res(XDR *, GETATTR3res*);
  869. extern bool_t xdr_sattrguard3(XDR *, sattrguard3*);
  870. extern bool_t xdr_SETATTR3args(XDR *, SETATTR3args*);
  871. extern bool_t xdr_SETATTR3resok(XDR *, SETATTR3resok*);
  872. extern bool_t xdr_SETATTR3resfail(XDR *, SETATTR3resfail*);
  873. extern bool_t xdr_SETATTR3res(XDR *, SETATTR3res*);
  874. extern bool_t xdr_LOOKUP3args(XDR *, LOOKUP3args*);
  875. extern bool_t xdr_LOOKUP3resok(XDR *, LOOKUP3resok*);
  876. extern bool_t xdr_LOOKUP3resfail(XDR *, LOOKUP3resfail*);
  877. extern bool_t xdr_LOOKUP3res(XDR *, LOOKUP3res*);
  878. extern bool_t xdr_ACCESS3args(XDR *, ACCESS3args*);
  879. extern bool_t xdr_ACCESS3resok(XDR *, ACCESS3resok*);
  880. extern bool_t xdr_ACCESS3resfail(XDR *, ACCESS3resfail*);
  881. extern bool_t xdr_ACCESS3res(XDR *, ACCESS3res*);
  882. extern bool_t xdr_READLINK3args(XDR *, READLINK3args*);
  883. extern bool_t xdr_READLINK3resok(XDR *, READLINK3resok*);
  884. extern bool_t xdr_READLINK3resfail(XDR *, READLINK3resfail*);
  885. extern bool_t xdr_READLINK3res(XDR *, READLINK3res*);
  886. extern bool_t xdr_READ3args(XDR *, READ3args*);
  887. extern bool_t xdr_READ3resok(XDR *, READ3resok*);
  888. extern bool_t xdr_READ3resfail(XDR *, READ3resfail*);
  889. extern bool_t xdr_READ3res(XDR *, READ3res*);
  890. extern bool_t xdr_WRITE3args(XDR *, WRITE3args*);
  891. extern bool_t xdr_WRITE3resok(XDR *, WRITE3resok*);
  892. extern bool_t xdr_WRITE3resfail(XDR *, WRITE3resfail*);
  893. extern bool_t xdr_WRITE3res(XDR *, WRITE3res*);
  894. extern bool_t xdr_createhow3(XDR *, createhow3*);
  895. extern bool_t xdr_CREATE3args(XDR *, CREATE3args*);
  896. extern bool_t xdr_CREATE3resok(XDR *, CREATE3resok*);
  897. extern bool_t xdr_CREATE3resfail(XDR *, CREATE3resfail*);
  898. extern bool_t xdr_CREATE3res(XDR *, CREATE3res*);
  899. extern bool_t xdr_MKDIR3args(XDR *, MKDIR3args*);
  900. extern bool_t xdr_MKDIR3resok(XDR *, MKDIR3resok*);
  901. extern bool_t xdr_MKDIR3resfail(XDR *, MKDIR3resfail*);
  902. extern bool_t xdr_MKDIR3res(XDR *, MKDIR3res*);
  903. extern bool_t xdr_symlinkdata3(XDR *, symlinkdata3*);
  904. extern bool_t xdr_SYMLINK3args(XDR *, SYMLINK3args*);
  905. extern bool_t xdr_SYMLINK3resok(XDR *, SYMLINK3resok*);
  906. extern bool_t xdr_SYMLINK3resfail(XDR *, SYMLINK3resfail*);
  907. extern bool_t xdr_SYMLINK3res(XDR *, SYMLINK3res*);
  908. extern bool_t xdr_devicedata3(XDR *, devicedata3*);
  909. extern bool_t xdr_mknoddata3(XDR *, mknoddata3*);
  910. extern bool_t xdr_MKNOD3args(XDR *, MKNOD3args*);
  911. extern bool_t xdr_MKNOD3resok(XDR *, MKNOD3resok*);
  912. extern bool_t xdr_MKNOD3resfail(XDR *, MKNOD3resfail*);
  913. extern bool_t xdr_MKNOD3res(XDR *, MKNOD3res*);
  914. extern bool_t xdr_REMOVE3args(XDR *, REMOVE3args*);
  915. extern bool_t xdr_REMOVE3resok(XDR *, REMOVE3resok*);
  916. extern bool_t xdr_REMOVE3resfail(XDR *, REMOVE3resfail*);
  917. extern bool_t xdr_REMOVE3res(XDR *, REMOVE3res*);
  918. extern bool_t xdr_RMDIR3args(XDR *, RMDIR3args*);
  919. extern bool_t xdr_RMDIR3resok(XDR *, RMDIR3resok*);
  920. extern bool_t xdr_RMDIR3resfail(XDR *, RMDIR3resfail*);
  921. extern bool_t xdr_RMDIR3res(XDR *, RMDIR3res*);
  922. extern bool_t xdr_RENAME3args(XDR *, RENAME3args*);
  923. extern bool_t xdr_RENAME3resok(XDR *, RENAME3resok*);
  924. extern bool_t xdr_RENAME3resfail(XDR *, RENAME3resfail*);
  925. extern bool_t xdr_RENAME3res(XDR *, RENAME3res*);
  926. extern bool_t xdr_LINK3args(XDR *, LINK3args*);
  927. extern bool_t xdr_LINK3resok(XDR *, LINK3resok*);
  928. extern bool_t xdr_LINK3resfail(XDR *, LINK3resfail*);
  929. extern bool_t xdr_LINK3res(XDR *, LINK3res*);
  930. extern bool_t xdr_READDIR3args(XDR *, READDIR3args*);
  931. extern bool_t xdr_entry3(XDR *, entry3*);
  932. extern bool_t xdr_dirlist3(XDR *, dirlist3*);
  933. extern bool_t xdr_READDIR3resok(XDR *, READDIR3resok*);
  934. extern bool_t xdr_READDIR3resfail(XDR *, READDIR3resfail*);
  935. extern bool_t xdr_READDIR3res(XDR *, READDIR3res*);
  936. extern bool_t xdr_READDIRPLUS3args(XDR *, READDIRPLUS3args*);
  937. extern bool_t xdr_entryplus3(XDR *, entryplus3*);
  938. extern bool_t xdr_dirlistplus3(XDR *, dirlistplus3*);
  939. extern bool_t xdr_READDIRPLUS3resok(XDR *, READDIRPLUS3resok*);
  940. extern bool_t xdr_READDIRPLUS3resfail(XDR *, READDIRPLUS3resfail*);
  941. extern bool_t xdr_READDIRPLUS3res(XDR *, READDIRPLUS3res*);
  942. extern bool_t xdr_FSSTAT3args(XDR *, FSSTAT3args*);
  943. extern bool_t xdr_FSSTAT3resok(XDR *, FSSTAT3resok*);
  944. extern bool_t xdr_FSSTAT3resfail(XDR *, FSSTAT3resfail*);
  945. extern bool_t xdr_FSSTAT3res(XDR *, FSSTAT3res*);
  946. extern bool_t xdr_FSINFO3args(XDR *, FSINFO3args*);
  947. extern bool_t xdr_FSINFO3resok(XDR *, FSINFO3resok*);
  948. extern bool_t xdr_FSINFO3resfail(XDR *, FSINFO3resfail*);
  949. extern bool_t xdr_FSINFO3res(XDR *, FSINFO3res*);
  950. extern bool_t xdr_PATHCONF3args(XDR *, PATHCONF3args*);
  951. extern bool_t xdr_PATHCONF3resok(XDR *, PATHCONF3resok*);
  952. extern bool_t xdr_PATHCONF3resfail(XDR *, PATHCONF3resfail*);
  953. extern bool_t xdr_PATHCONF3res(XDR *, PATHCONF3res*);
  954. extern bool_t xdr_COMMIT3args(XDR *, COMMIT3args*);
  955. extern bool_t xdr_COMMIT3resok(XDR *, COMMIT3resok*);
  956. extern bool_t xdr_COMMIT3resfail(XDR *, COMMIT3resfail*);
  957. extern bool_t xdr_COMMIT3res(XDR *, COMMIT3res*);
  958. #ifdef __cplusplus
  959. }
  960. #endif
  961. #endif /* !_NFS_H_RPCGEN */