df940c5f131505b2796229be28431dee7766e9ab
2 Copyright (C) 2010 by Ronnie Sahlberg <ronniesahlberg@gmail.com>
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU Lesser General Public License as published by
6 the Free Software Foundation; either version 2.1 of the License, or
7 (at your option) any later version.
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU Lesser General Public License for more details.
14 You should have received a copy of the GNU Lesser General Public License
15 along with this program; if not, see <http://www.gnu.org/licenses/>.
18 * This is the lowlevel interface to access NFS resources.
19 * Through this interface you have access to the full gamut of nfs and nfs related
20 * protocol as well as the XDR encoded/decoded structures.
32 struct rpc_context
*rpc_init_context(void);
33 void rpc_destroy_context(struct rpc_context
*rpc
);
35 void rpc_set_auth(struct rpc_context
*rpc
, AUTH
*auth
);
37 int rpc_get_fd(struct rpc_context
*rpc
);
38 int rpc_which_events(struct rpc_context
*rpc
);
39 int rpc_service(struct rpc_context
*rpc
, int revents
);
40 char *rpc_get_error(struct rpc_context
*rpc
);
41 int rpc_queue_length(struct rpc_context
*rpc
);
44 #define RPC_STATUS_SUCCESS 0
45 #define RPC_STATUS_ERROR 1
46 #define RPC_STATUS_CANCEL 2
49 * Async connection to the tcp port at server:port.
51 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
52 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
54 * When the callback is invoked, status indicates the result:
55 * RPC_STATUS_SUCCESS : The tcp connection was successfully established.
57 * RPC_STATUS_ERROR : The connection failed to establish.
58 * data is the erro string.
59 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
62 int rpc_connect_async(struct rpc_context
*rpc
, const char *server
, int port
, rpc_cb cb
, void *private_data
);
64 * When disconnecting a connection in flight. All commands in flight will be called with the callback
65 * and status RPC_STATUS_ERROR. Data will be the error string for the disconnection.
67 int rpc_disconnect(struct rpc_context
*rpc
, char *error
);
75 * Call PORTMAPPER/NULL
77 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
78 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
80 * When the callback is invoked, status indicates the result:
81 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon.
83 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
84 * data is the error string.
85 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
88 int rpc_pmap_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
92 * Call PORTMAPPER/GETPORT.
94 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
95 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
97 * When the callback is invoked, status indicates the result:
98 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon.
99 * data is a (uint32_t *), containing the port returned.
100 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
101 * data is the error string.
102 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
105 int rpc_pmap_getport_async(struct rpc_context
*rpc
, int program
, int version
, int protocol
, rpc_cb cb
, void *private_data
);
108 * Call PORTMAPPER/SET
110 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
111 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
113 * When the callback is invoked, status indicates the result:
114 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon.
115 * data is a (uint32_t *), containing status
116 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
117 * data is the error string.
118 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
121 int rpc_pmap_set_async(struct rpc_context
*rpc
, int program
, int version
, int protocol
, int port
, rpc_cb cb
, void *private_data
);
124 * Call PORTMAPPER/UNSET
126 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
127 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
129 * When the callback is invoked, status indicates the result:
130 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon.
131 * data is a (uint32_t *), containing status
132 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
133 * data is the error string.
134 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
137 int rpc_pmap_unset_async(struct rpc_context
*rpc
, int program
, int version
, int protocol
, int port
, rpc_cb cb
, void *private_data
);
140 * Call PORTMAPPER/CALLIT.
142 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
143 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
145 * When the callback is invoked, status indicates the result:
146 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon
147 * data is a 'pmap_call_result' pointer.
148 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
149 * data is the error string.
150 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
153 int rpc_pmap_callit_async(struct rpc_context
*rpc
, int program
, int version
, int procedure
, const char *data
, int datalen
, rpc_cb cb
, void *private_data
);
158 char *mountstat3_to_str(int stat
);
159 int mountstat3_to_errno(int error
);
164 * 0 : The call was initiated. The callback will be invoked when the call completes.
165 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
167 * When the callback is invoked, status indicates the result:
168 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
170 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
171 * data is the error string.
172 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
175 int rpc_mount_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
180 * 0 : The call was initiated. The callback will be invoked when the call completes.
181 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
183 * When the callback is invoked, status indicates the result:
184 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
185 * data is union mountres3.
186 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
187 * data is the error string.
188 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
191 int rpc_mount_mnt_async(struct rpc_context
*rpc
, rpc_cb cb
, char *export
, void *private_data
);
196 * 0 : The call was initiated. The callback will be invoked when the call completes.
197 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
199 * When the callback is invoked, status indicates the result:
200 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
201 * data is a mountlist.
202 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
203 * data is the error string.
204 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
207 int rpc_mount_dump_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
212 * 0 : The call was initiated. The callback will be invoked when the call completes.
213 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
215 * When the callback is invoked, status indicates the result:
216 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
218 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
219 * data is the error string.
220 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
223 int rpc_mount_umnt_async(struct rpc_context
*rpc
, rpc_cb cb
, char *export
, void *private_data
);
228 * 0 : The call was initiated. The callback will be invoked when the call completes.
229 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
231 * When the callback is invoked, status indicates the result:
232 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
234 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
235 * data is the error string.
236 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
239 int rpc_mount_umntall_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
243 * NOTE: You must include 'libnfs-raw-mount.h' to get the definitions of the
244 * returned structures.
247 * 0 : The call was initiated. The callback will be invoked when the call completes.
248 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
250 * When the callback is invoked, status indicates the result:
251 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
252 * data is a pointer to an exports pointer:
253 * exports export = *(exports *)data;
254 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
255 * data is the error string.
256 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
259 int rpc_mount_export_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
268 char *nfsstat3_to_str(int error
);
269 int nfsstat3_to_errno(int error
);
274 * 0 : The call was initiated. The callback will be invoked when the call completes.
275 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
277 * When the callback is invoked, status indicates the result:
278 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
280 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
281 * data is the error string.
282 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
285 int rpc_nfs_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
290 * 0 : The call was initiated. The callback will be invoked when the call completes.
291 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
293 * When the callback is invoked, status indicates the result:
294 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
295 * data is GETATTR3res
296 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
297 * data is the error string.
298 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
301 int rpc_nfs_getattr_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, void *private_data
);
306 * 0 : The call was initiated. The callback will be invoked when the call completes.
307 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
309 * When the callback is invoked, status indicates the result:
310 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
312 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
313 * data is the error string.
314 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
317 int rpc_nfs_lookup_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, char *name
, void *private_data
);
322 * 0 : The call was initiated. The callback will be invoked when the call completes.
323 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
325 * When the callback is invoked, status indicates the result:
326 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
328 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
329 * data is the error string.
330 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
333 int rpc_nfs_access_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, int access
, void *private_data
);
338 * 0 : The call was initiated. The callback will be invoked when the call completes.
339 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
341 * When the callback is invoked, status indicates the result:
342 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
344 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
345 * data is the error string.
346 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
349 int rpc_nfs_read_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, uint64_t offset
, uint64_t count
, void *private_data
);
354 * 0 : The call was initiated. The callback will be invoked when the call completes.
355 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
357 * When the callback is invoked, status indicates the result:
358 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
359 * data is WRITE3res *
360 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
361 * data is the error string.
362 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
365 int rpc_nfs_write_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, char *buf
, uint64_t offset
, uint64_t count
, int stable_how
, void *private_data
);
370 * 0 : The call was initiated. The callback will be invoked when the call completes.
371 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
373 * When the callback is invoked, status indicates the result:
374 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
375 * data is COMMIT3res *
376 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
377 * data is the error string.
378 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
381 int rpc_nfs_commit_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, void *private_data
);
387 * 0 : The call was initiated. The callback will be invoked when the call completes.
388 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
390 * When the callback is invoked, status indicates the result:
391 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
392 * data is SETATTR3res *
393 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
394 * data is the error string.
395 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
399 int rpc_nfs_setattr_async(struct rpc_context
*rpc
, rpc_cb cb
, struct SETATTR3args
*args
, void *private_data
);
406 * 0 : The call was initiated. The callback will be invoked when the call completes.
407 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
409 * When the callback is invoked, status indicates the result:
410 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
411 * data is MKDIR3res *
412 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
413 * data is the error string.
414 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
417 int rpc_nfs_mkdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, char *dir
, void *private_data
);
426 * 0 : The call was initiated. The callback will be invoked when the call completes.
427 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
429 * When the callback is invoked, status indicates the result:
430 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
431 * data is RMDIR3res *
432 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
433 * data is the error string.
434 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
437 int rpc_nfs_rmdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, char *dir
, void *private_data
);
445 * 0 : The call was initiated. The callback will be invoked when the call completes.
446 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
448 * When the callback is invoked, status indicates the result:
449 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
450 * data is CREATE3res *
451 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
452 * data is the error string.
453 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
457 int rpc_nfs_create_async(struct rpc_context
*rpc
, rpc_cb cb
, struct CREATE3args
*args
, void *private_data
);
463 * 0 : The call was initiated. The callback will be invoked when the call completes.
464 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
466 * When the callback is invoked, status indicates the result:
467 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
468 * data is MKNOD3res *
469 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
470 * data is the error string.
471 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
474 int rpc_nfs_mknod_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, char *file
, int mode
, int major
, int minor
, void *private_data
);
480 * 0 : The call was initiated. The callback will be invoked when the call completes.
481 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
483 * When the callback is invoked, status indicates the result:
484 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
485 * data is REMOVE3res *
486 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
487 * data is the error string.
488 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
491 int rpc_nfs_remove_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, char *name
, void *private_data
);
498 * 0 : The call was initiated. The callback will be invoked when the call completes.
499 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
501 * When the callback is invoked, status indicates the result:
502 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
503 * data is READDIR3res *
504 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
505 * data is the error string.
506 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
509 int rpc_nfs_readdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, uint64_t cookie
, char *cookieverf
, int count
, void *private_data
);
512 * Call NFS/READDIRPLUS
514 * 0 : The call was initiated. The callback will be invoked when the call completes.
515 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
517 * When the callback is invoked, status indicates the result:
518 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
519 * data is READDIRPLUS3res *
520 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
521 * data is the error string.
522 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
525 int rpc_nfs_readdirplus_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, uint64_t cookie
, char *cookieverf
, int count
, void *private_data
);
530 * 0 : The call was initiated. The callback will be invoked when the call completes.
531 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
533 * When the callback is invoked, status indicates the result:
534 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
536 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
537 * data is the error string.
538 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
541 int rpc_nfs_fsstat_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, void *private_data
);
548 * 0 : The call was initiated. The callback will be invoked when the call completes.
549 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
551 * When the callback is invoked, status indicates the result:
552 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
554 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
555 * data is the error string.
556 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
559 int rpc_nfs_fsinfo_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, void *private_data
);
566 * 0 : The call was initiated. The callback will be invoked when the call completes.
567 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
569 * When the callback is invoked, status indicates the result:
570 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
571 * data is READLINK3res *
572 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
573 * data is the error string.
574 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
577 int rpc_nfs_readlink_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, void *private_data
);
584 * 0 : The call was initiated. The callback will be invoked when the call completes.
585 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
587 * When the callback is invoked, status indicates the result:
588 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
589 * data is SYMLINK3res *
590 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
591 * data is the error string.
592 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
595 int rpc_nfs_symlink_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, char *newname
, char *oldpath
, void *private_data
);
601 * 0 : The call was initiated. The callback will be invoked when the call completes.
602 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
604 * When the callback is invoked, status indicates the result:
605 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
606 * data is RENAME3res *
607 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
608 * data is the error string.
609 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
612 int rpc_nfs_rename_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*olddir
, char *oldname
, struct nfs_fh3
*newdir
, char *newname
, void *private_data
);
619 * 0 : The call was initiated. The callback will be invoked when the call completes.
620 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
622 * When the callback is invoked, status indicates the result:
623 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
625 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
626 * data is the error string.
627 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
630 int rpc_nfs_link_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*file
, struct nfs_fh3
*newdir
, char *newname
, void *private_data
);
638 char *rquotastat_to_str(int error
);
639 int rquotastat_to_errno(int error
);
644 * 0 : The call was initiated. The callback will be invoked when the call completes.
645 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
647 * When the callback is invoked, status indicates the result:
648 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
650 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
651 * data is the error string.
652 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
655 int rpc_rquota1_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
658 * Call RQUOTA1/GETQUOTA
660 * 0 : The call was initiated. The callback will be invoked when the call completes.
661 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
663 * When the callback is invoked, status indicates the result:
664 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
665 * data is a RQUOTA1res structure.
666 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
667 * data is the error string.
668 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
671 int rpc_rquota1_getquota_async(struct rpc_context
*rpc
, rpc_cb cb
, char *export
, int uid
, void *private_data
);
674 * Call RQUOTA1/GETACTIVEQUOTA
676 * 0 : The call was initiated. The callback will be invoked when the call completes.
677 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
679 * When the callback is invoked, status indicates the result:
680 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
681 * data is a RQUOTA1res structure.
682 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
683 * data is the error string.
684 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
687 int rpc_rquota1_getactivequota_async(struct rpc_context
*rpc
, rpc_cb cb
, char *export
, int uid
, void *private_data
);
695 * 0 : The call was initiated. The callback will be invoked when the call completes.
696 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
698 * When the callback is invoked, status indicates the result:
699 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
701 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
702 * data is the error string.
703 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
706 int rpc_rquota2_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
709 * Call RQUOTA2/GETQUOTA
711 * 0 : The call was initiated. The callback will be invoked when the call completes.
712 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
714 * When the callback is invoked, status indicates the result:
715 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
716 * data is a RQUOTA1res structure.
717 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
718 * data is the error string.
719 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
722 int rpc_rquota2_getquota_async(struct rpc_context
*rpc
, rpc_cb cb
, char *export
, int type
, int uid
, void *private_data
);
725 * Call RQUOTA2/GETACTIVEQUOTA
727 * 0 : The call was initiated. The callback will be invoked when the call completes.
728 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
730 * When the callback is invoked, status indicates the result:
731 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
732 * data is a RQUOTA1res structure.
733 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
734 * data is the error string.
735 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
738 int rpc_rquota2_getactivequota_async(struct rpc_context
*rpc
, rpc_cb cb
, char *export
, int type
, int uid
, void *private_data
);
744 * Call the NULL procedure for the NFSACL
747 * 0 : The call was initiated. The callback will be invoked when the call completes.
748 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
750 * When the callback is invoked, status indicates the result:
751 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
753 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
754 * data is the error string.
755 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
758 int rpc_nfsacl_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
764 * 0 : The call was initiated. The callback will be invoked when the call completes.
765 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
767 * When the callback is invoked, status indicates the result:
768 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
769 * data is a GETACL3res pointer
770 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
771 * data is the error string.
772 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
775 int rpc_nfsacl_getacl_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, uint32_t mask
, void *private_data
);