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.
22 #ifndef _LIBNFS_RAW_H_
23 #define _LIBNFS_RAW_H_
26 #include <nfsc/libnfs-zdr.h>
38 struct rpc_context
*rpc_init_context(void);
39 void rpc_destroy_context(struct rpc_context
*rpc
);
41 void rpc_set_auth(struct rpc_context
*rpc
, struct AUTH
*auth
);
43 int rpc_get_fd(struct rpc_context
*rpc
);
44 int rpc_which_events(struct rpc_context
*rpc
);
45 int rpc_service(struct rpc_context
*rpc
, int revents
);
46 char *rpc_get_error(struct rpc_context
*rpc
);
47 int rpc_queue_length(struct rpc_context
*rpc
);
49 /* Utility function to get an RPC context from a NFS context. Useful for doing low level NFSACL
50 * calls on a NFS context.
52 struct rpc_context
*nfs_get_rpc_context(struct nfs_context
*nfs
);
54 /* This function returns the nfs_fh3 structure from a nfsfh structure.
55 This allows to use a file onened with nfs_open() together with low-level
56 rpc functions that thake a nfs filehandle
58 struct nfs_fh3
*nfs_get_fh(struct nfsfh
*nfsfh
);
60 /* Control what the next XID value to be used on the context will be.
61 This can be used when multiple contexts are used to the same server
62 to avoid that the two contexts have xid collissions.
64 void rpc_set_next_xid(struct rpc_context
*rpc
, uint32_t xid
);
66 /* This function can be used to set the file descriptor used for
67 * the RPC context. It is primarily useful when emulating dup2()
68 * and similar or where you want full control of the filedescriptor numbers
69 * used by the rpc socket.
72 * oldfd = rpc_get_fd(rpc);
74 * rpc_set_fd(rpc, newfd);
78 void rpc_set_fd(struct rpc_context
*rpc
, int fd
);
80 #define RPC_STATUS_SUCCESS 0
81 #define RPC_STATUS_ERROR 1
82 #define RPC_STATUS_CANCEL 2
85 * Async connection to the tcp port at server:port.
87 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
88 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
90 * When the callback is invoked, status indicates the result:
91 * RPC_STATUS_SUCCESS : The tcp connection was successfully established.
93 * RPC_STATUS_ERROR : The connection failed to establish.
94 * data is the erro string.
95 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
98 int rpc_connect_async(struct rpc_context
*rpc
, const char *server
, int port
, rpc_cb cb
, void *private_data
);
100 * Async function to connect to a specific RPC program/version
102 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
103 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
105 * When the callback is invoked, status indicates the result:
106 * RPC_STATUS_SUCCESS : The tcp connection was successfully established.
108 * RPC_STATUS_ERROR : The connection failed to establish.
109 * data is the erro string.
110 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
113 int rpc_connect_program_async(struct rpc_context
*rpc
, char *server
, int program
, int version
, rpc_cb cb
, void *private_data
);
115 * When disconnecting a connection in flight. All commands in flight will be called with the callback
116 * and status RPC_STATUS_ERROR. Data will be the error string for the disconnection.
118 int rpc_disconnect(struct rpc_context
*rpc
, char *error
);
122 * PORTMAP v2 FUNCTIONS
126 * Call PORTMAPPER2/NULL
128 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
129 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
131 * When the callback is invoked, status indicates the result:
132 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon.
134 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
135 * data is the error string.
136 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
139 EXTERN
int rpc_pmap2_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
143 * Call PORTMAPPER2/GETPORT.
145 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
146 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
148 * When the callback is invoked, status indicates the result:
149 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon.
150 * data is a (uint32_t *), containing the port returned.
151 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
152 * data is the error string.
153 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
156 EXTERN
int rpc_pmap2_getport_async(struct rpc_context
*rpc
, int program
, int version
, int protocol
, rpc_cb cb
, void *private_data
);
159 * Call PORTMAPPER2/SET
161 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
162 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
164 * When the callback is invoked, status indicates the result:
165 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon.
166 * data is a (uint32_t *), containing status
167 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
168 * data is the error string.
169 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
172 EXTERN
int rpc_pmap2_set_async(struct rpc_context
*rpc
, int program
, int version
, int protocol
, int port
, rpc_cb cb
, void *private_data
);
175 * Call PORTMAPPER2/UNSET
177 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
178 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
180 * When the callback is invoked, status indicates the result:
181 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon.
182 * data is a (uint32_t *), containing status
183 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
184 * data is the error string.
185 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
188 EXTERN
int rpc_pmap2_unset_async(struct rpc_context
*rpc
, int program
, int version
, int protocol
, int port
, rpc_cb cb
, void *private_data
);
191 * Call PORTMAPPER2/DUMP.
193 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
194 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
196 * When the callback is invoked, status indicates the result:
197 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon.
198 * data is struct pmap_dump_result.
199 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
200 * data is the error string.
201 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
204 EXTERN
int rpc_pmap2_dump_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
207 * Call PORTMAPPER2/CALLIT.
209 * 0 : The connection was initiated. Once the connection establish finishes, the callback will be invoked.
210 * <0 : An error occured when trying to set up the connection. The callback will not be invoked.
212 * When the callback is invoked, status indicates the result:
213 * RPC_STATUS_SUCCESS : We got a successful response from the portmapper daemon
214 * data is a 'pmap_call_result' pointer.
215 * RPC_STATUS_ERROR : An error occured when trying to contact the portmapper.
216 * data is the error string.
217 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
220 EXTERN
int rpc_pmap2_callit_async(struct rpc_context
*rpc
, int program
, int version
, int procedure
, char *data
, int datalen
, rpc_cb cb
, void *private_data
);
225 char *mountstat3_to_str(int stat
);
226 int mountstat3_to_errno(int error
);
231 * 0 : The call was initiated. The callback will be invoked when the call completes.
232 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
234 * When the callback is invoked, status indicates the result:
235 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
237 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
238 * data is the error string.
239 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
242 EXTERN
int rpc_mount3_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
243 EXTERN
int rpc_mount_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
248 * 0 : The call was initiated. The callback will be invoked when the call completes.
249 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
251 * When the callback is invoked, status indicates the result:
252 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
253 * data is union mountres3.
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 EXTERN
int rpc_mount3_mnt_async(struct rpc_context
*rpc
, rpc_cb cb
, char *exportname
, void *private_data
);
260 EXTERN
int rpc_mount_mnt_async(struct rpc_context
*rpc
, rpc_cb cb
, char *exportname
, void *private_data
);
265 * 0 : The call was initiated. The callback will be invoked when the call completes.
266 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
268 * When the callback is invoked, status indicates the result:
269 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
270 * data is a mountlist.
271 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
272 * data is the error string.
273 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
276 EXTERN
int rpc_mount3_dump_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
277 EXTERN
int rpc_mount_dump_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
282 * 0 : The call was initiated. The callback will be invoked when the call completes.
283 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
285 * When the callback is invoked, status indicates the result:
286 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
288 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
289 * data is the error string.
290 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
293 EXTERN
int rpc_mount3_umnt_async(struct rpc_context
*rpc
, rpc_cb cb
, char *exportname
, void *private_data
);
294 EXTERN
int rpc_mount_umnt_async(struct rpc_context
*rpc
, rpc_cb cb
, char *exportname
, void *private_data
);
297 * Call MOUNT3/UMNTALL
299 * 0 : The call was initiated. The callback will be invoked when the call completes.
300 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
302 * When the callback is invoked, status indicates the result:
303 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
305 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
306 * data is the error string.
307 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
310 EXTERN
int rpc_mount3_umntall_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
311 EXTERN
int rpc_mount_umntall_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
315 * NOTE: You must include 'libnfs-raw-mount.h' to get the definitions of the
316 * returned structures.
319 * 0 : The call was initiated. The callback will be invoked when the call completes.
320 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
322 * When the callback is invoked, status indicates the result:
323 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
324 * data is a pointer to an exports pointer:
325 * exports export = *(exports *)data;
326 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
327 * data is the error string.
328 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
331 EXTERN
int rpc_mount3_export_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
332 EXTERN
int rpc_mount_export_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
335 * MOUNT v1 FUNCTIONS (Used with NFSv2)
340 * 0 : The call was initiated. The callback will be invoked when the call completes.
341 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
343 * When the callback is invoked, status indicates the result:
344 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
346 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
347 * data is the error string.
348 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
351 EXTERN
int rpc_mount1_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
356 * 0 : The call was initiated. The callback will be invoked when the call completes.
357 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
359 * When the callback is invoked, status indicates the result:
360 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
361 * data is union mountres1.
362 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
363 * data is the error string.
364 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
367 EXTERN
int rpc_mount1_mnt_async(struct rpc_context
*rpc
, rpc_cb cb
, char *exportname
, void *private_data
);
372 * 0 : The call was initiated. The callback will be invoked when the call completes.
373 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
375 * When the callback is invoked, status indicates the result:
376 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
377 * data is a mountlist.
378 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
379 * data is the error string.
380 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
383 EXTERN
int rpc_mount1_dump_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
388 * 0 : The call was initiated. The callback will be invoked when the call completes.
389 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
391 * When the callback is invoked, status indicates the result:
392 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
394 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
395 * data is the error string.
396 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
399 EXTERN
int rpc_mount1_umnt_async(struct rpc_context
*rpc
, rpc_cb cb
, char *exportname
, void *private_data
);
402 * Call MOUNT1/UMNTALL
404 * 0 : The call was initiated. The callback will be invoked when the call completes.
405 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
407 * When the callback is invoked, status indicates the result:
408 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
410 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
411 * data is the error string.
412 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
415 EXTERN
int rpc_mount1_umntall_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
419 * NOTE: You must include 'libnfs-raw-mount.h' to get the definitions of the
420 * returned structures.
423 * 0 : The call was initiated. The callback will be invoked when the call completes.
424 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
426 * When the callback is invoked, status indicates the result:
427 * RPC_STATUS_SUCCESS : We got a successful response from the mount daemon.
428 * data is a pointer to an exports pointer:
429 * exports export = *(exports *)data;
430 * RPC_STATUS_ERROR : An error occured when trying to contact the mount daemon.
431 * data is the error string.
432 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
435 EXTERN
int rpc_mount1_export_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
442 char *nfsstat3_to_str(int error
);
443 int nfsstat3_to_errno(int error
);
448 * 0 : The call was initiated. The callback will be invoked when the call completes.
449 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
451 * When the callback is invoked, status indicates the result:
452 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
454 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
455 * data is the error string.
456 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
459 EXTERN
int rpc_nfs3_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
460 EXTERN
int rpc_nfs_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
465 * 0 : The call was initiated. The callback will be invoked when the call completes.
466 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
468 * When the callback is invoked, status indicates the result:
469 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
470 * data is GETATTR3res
471 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
472 * data is the error string.
473 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
477 EXTERN
int rpc_nfs3_getattr_async(struct rpc_context
*rpc
, rpc_cb cb
, struct GETATTR3args
*args
, void *private_data
);
478 EXTERN
int rpc_nfs_getattr_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, void *private_data
);
483 * 0 : The call was initiated. The callback will be invoked when the call completes.
484 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
486 * When the callback is invoked, status indicates the result:
487 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
488 * data is PATHCONF3res
489 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
490 * data is the error string.
491 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
494 struct PATHCONF3args
;
495 EXTERN
int rpc_nfs3_pathconf_async(struct rpc_context
*rpc
, rpc_cb cb
, struct PATHCONF3args
*args
, void *private_data
);
496 EXTERN
int rpc_nfs_pathconf_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, void *private_data
);
501 * 0 : The call was initiated. The callback will be invoked when the call completes.
502 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
504 * When the callback is invoked, status indicates the result:
505 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
507 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
508 * data is the error string.
509 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
513 EXTERN
int rpc_nfs3_lookup_async(struct rpc_context
*rpc
, rpc_cb cb
, struct LOOKUP3args
*args
, void *private_data
);
514 EXTERN
int rpc_nfs_lookup_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, char *name
, void *private_data
);
519 * 0 : The call was initiated. The callback will be invoked when the call completes.
520 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
522 * When the callback is invoked, status indicates the result:
523 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
525 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
526 * data is the error string.
527 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
531 EXTERN
int rpc_nfs3_access_async(struct rpc_context
*rpc
, rpc_cb cb
, struct ACCESS3args
*args
, void *private_data
);
532 EXTERN
int rpc_nfs_access_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, int access
, void *private_data
);
537 * 0 : The call was initiated. The callback will be invoked when the call completes.
538 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
540 * When the callback is invoked, status indicates the result:
541 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
543 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
544 * data is the error string.
545 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
549 EXTERN
int rpc_nfs3_read_async(struct rpc_context
*rpc
, rpc_cb cb
, struct READ3args
*args
, void *private_data
);
550 EXTERN
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
);
555 * 0 : The call was initiated. The callback will be invoked when the call completes.
556 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
558 * When the callback is invoked, status indicates the result:
559 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
560 * data is WRITE3res *
561 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
562 * data is the error string.
563 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
567 EXTERN
int rpc_nfs3_write_async(struct rpc_context
*rpc
, rpc_cb cb
, struct WRITE3args
*args
, void *private_data
);
568 EXTERN
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
);
573 * 0 : The call was initiated. The callback will be invoked when the call completes.
574 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
576 * When the callback is invoked, status indicates the result:
577 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
578 * data is COMMIT3res *
579 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
580 * data is the error string.
581 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
585 EXTERN
int rpc_nfs3_commit_async(struct rpc_context
*rpc
, rpc_cb cb
, struct COMMIT3args
*args
, void *private_data
);
586 EXTERN
int rpc_nfs_commit_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, void *private_data
);
591 * 0 : The call was initiated. The callback will be invoked when the call completes.
592 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
594 * When the callback is invoked, status indicates the result:
595 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
596 * data is SETATTR3res *
597 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
598 * data is the error string.
599 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
603 EXTERN
int rpc_nfs3_setattr_async(struct rpc_context
*rpc
, rpc_cb cb
, struct SETATTR3args
*args
, void *private_data
);
604 EXTERN
int rpc_nfs_setattr_async(struct rpc_context
*rpc
, rpc_cb cb
, struct SETATTR3args
*args
, void *private_data
);
609 * 0 : The call was initiated. The callback will be invoked when the call completes.
610 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
612 * When the callback is invoked, status indicates the result:
613 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
614 * data is MKDIR3res *
615 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
616 * data is the error string.
617 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
621 EXTERN
int rpc_nfs3_mkdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct MKDIR3args
*args
, void *private_data
);
622 EXTERN
int rpc_nfs_mkdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct MKDIR3args
*args
, void *private_data
);
627 * 0 : The call was initiated. The callback will be invoked when the call completes.
628 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
630 * When the callback is invoked, status indicates the result:
631 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
632 * data is RMDIR3res *
633 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
634 * data is the error string.
635 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
639 EXTERN
int rpc_nfs3_rmdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct RMDIR3args
*args
, void *private_data
);
640 EXTERN
int rpc_nfs_rmdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, char *dir
, void *private_data
);
645 * 0 : The call was initiated. The callback will be invoked when the call completes.
646 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
648 * When the callback is invoked, status indicates the result:
649 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
650 * data is CREATE3res *
651 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
652 * data is the error string.
653 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
657 EXTERN
int rpc_nfs3_create_async(struct rpc_context
*rpc
, rpc_cb cb
, struct CREATE3args
*args
, void *private_data
);
658 EXTERN
int rpc_nfs_create_async(struct rpc_context
*rpc
, rpc_cb cb
, struct CREATE3args
*args
, void *private_data
);
663 * 0 : The call was initiated. The callback will be invoked when the call completes.
664 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
666 * When the callback is invoked, status indicates the result:
667 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
668 * data is MKNOD3res *
669 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
670 * data is the error string.
671 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
675 EXTERN
int rpc_nfs3_mknod_async(struct rpc_context
*rpc
, rpc_cb cb
, struct MKNOD3args
*args
, void *private_data
);
676 EXTERN
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
);
681 * 0 : The call was initiated. The callback will be invoked when the call completes.
682 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
684 * When the callback is invoked, status indicates the result:
685 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
686 * data is REMOVE3res *
687 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
688 * data is the error string.
689 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
693 EXTERN
int rpc_nfs3_remove_async(struct rpc_context
*rpc
, rpc_cb cb
, struct REMOVE3args
*args
, void *private_data
);
694 EXTERN
int rpc_nfs_remove_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, char *name
, void *private_data
);
699 * 0 : The call was initiated. The callback will be invoked when the call completes.
700 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
702 * When the callback is invoked, status indicates the result:
703 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
704 * data is READDIR3res *
705 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
706 * data is the error string.
707 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
711 EXTERN
int rpc_nfs3_readdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct READDIR3args
*args
, void *private_data
);
712 EXTERN
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
);
715 * Call NFS3/READDIRPLUS
717 * 0 : The call was initiated. The callback will be invoked when the call completes.
718 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
720 * When the callback is invoked, status indicates the result:
721 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
722 * data is READDIRPLUS3res *
723 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
724 * data is the error string.
725 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
728 struct READDIRPLUS3args
;
729 EXTERN
int rpc_nfs3_readdirplus_async(struct rpc_context
*rpc
, rpc_cb cb
, struct READDIRPLUS3args
*args
, void *private_data
);
730 EXTERN
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
);
735 * 0 : The call was initiated. The callback will be invoked when the call completes.
736 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
738 * When the callback is invoked, status indicates the result:
739 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
741 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
742 * data is the error string.
743 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
747 EXTERN
int rpc_nfs3_fsstat_async(struct rpc_context
*rpc
, rpc_cb cb
, struct FSSTAT3args
*args
, void *private_data
);
748 EXTERN
int rpc_nfs_fsstat_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, void *private_data
);
753 * 0 : The call was initiated. The callback will be invoked when the call completes.
754 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
756 * When the callback is invoked, status indicates the result:
757 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
759 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
760 * data is the error string.
761 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
765 EXTERN
int rpc_nfs3_fsinfo_async(struct rpc_context
*rpc
, rpc_cb cb
, struct FSINFO3args
*args
, void *private_data
);
766 EXTERN
int rpc_nfs_fsinfo_async(struct rpc_context
*rpc
, rpc_cb cb
, struct nfs_fh3
*fh
, void *private_data
);
771 * 0 : The call was initiated. The callback will be invoked when the call completes.
772 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
774 * When the callback is invoked, status indicates the result:
775 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
776 * data is READLINK3res *
777 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
778 * data is the error string.
779 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
782 struct READLINK3args
;
783 EXTERN
int rpc_nfs3_readlink_async(struct rpc_context
*rpc
, rpc_cb cb
, struct READLINK3args
*args
, void *private_data
);
784 EXTERN
int rpc_nfs_readlink_async(struct rpc_context
*rpc
, rpc_cb cb
, struct READLINK3args
*args
, void *private_data
);
789 * 0 : The call was initiated. The callback will be invoked when the call completes.
790 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
792 * When the callback is invoked, status indicates the result:
793 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
794 * data is SYMLINK3res *
795 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
796 * data is the error string.
797 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
801 EXTERN
int rpc_nfs3_symlink_async(struct rpc_context
*rpc
, rpc_cb cb
, struct SYMLINK3args
*args
, void *private_data
);
802 EXTERN
int rpc_nfs_symlink_async(struct rpc_context
*rpc
, rpc_cb cb
, struct SYMLINK3args
*args
, void *private_data
);
807 * 0 : The call was initiated. The callback will be invoked when the call completes.
808 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
810 * When the callback is invoked, status indicates the result:
811 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
812 * data is RENAME3res *
813 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
814 * data is the error string.
815 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
819 EXTERN
int rpc_nfs3_rename_async(struct rpc_context
*rpc
, rpc_cb cb
, struct RENAME3args
*args
, void *private_data
);
820 EXTERN
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
);
825 * 0 : The call was initiated. The callback will be invoked when the call completes.
826 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
828 * When the callback is invoked, status indicates the result:
829 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
831 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
832 * data is the error string.
833 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
837 EXTERN
int rpc_nfs3_link_async(struct rpc_context
*rpc
, rpc_cb cb
, struct LINK3args
*args
, void *private_data
);
838 EXTERN
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
);
847 * 0 : The call was initiated. The callback will be invoked when the call completes.
848 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
850 * When the callback is invoked, status indicates the result:
851 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
853 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
854 * data is the error string.
855 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
858 EXTERN
int rpc_nfs2_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
863 * 0 : The call was initiated. The callback will be invoked when the call completes.
864 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
866 * When the callback is invoked, status indicates the result:
867 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
868 * data is GETATTR2res
869 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
870 * data is the error string.
871 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
875 EXTERN
int rpc_nfs2_getattr_async(struct rpc_context
*rpc
, rpc_cb cb
, struct GETATTR2args
*args
, void *private_data
);
880 * 0 : The call was initiated. The callback will be invoked when the call completes.
881 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
883 * When the callback is invoked, status indicates the result:
884 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
885 * data is SETATTR2res *
886 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
887 * data is the error string.
888 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
892 EXTERN
int rpc_nfs2_setattr_async(struct rpc_context
*rpc
, rpc_cb cb
, struct SETATTR2args
*args
, void *private_data
);
897 * 0 : The call was initiated. The callback will be invoked when the call completes.
898 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
900 * When the callback is invoked, status indicates the result:
901 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
903 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
904 * data is the error string.
905 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
909 EXTERN
int rpc_nfs2_lookup_async(struct rpc_context
*rpc
, rpc_cb cb
, struct LOOKUP2args
*args
, void *private_data
);
914 * 0 : The call was initiated. The callback will be invoked when the call completes.
915 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
917 * When the callback is invoked, status indicates the result:
918 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
919 * data is READLINK2res *
920 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
921 * data is the error string.
922 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
925 struct READLINK2args
;
926 EXTERN
int rpc_nfs32_readlink_async(struct rpc_context
*rpc
, rpc_cb cb
, struct READLINK2args
*args
, void *private_data
);
931 * 0 : The call was initiated. The callback will be invoked when the call completes.
932 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
934 * When the callback is invoked, status indicates the result:
935 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
937 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
938 * data is the error string.
939 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
943 EXTERN
int rpc_nfs2_read_async(struct rpc_context
*rpc
, rpc_cb cb
, struct READ2args
*args
, void *private_data
);
948 * 0 : The call was initiated. The callback will be invoked when the call completes.
949 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
951 * When the callback is invoked, status indicates the result:
952 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
953 * data is WRITE2res *
954 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
955 * data is the error string.
956 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
960 EXTERN
int rpc_nfs2_write_async(struct rpc_context
*rpc
, rpc_cb cb
, struct WRITE2args
*args
, void *private_data
);
965 * 0 : The call was initiated. The callback will be invoked when the call completes.
966 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
968 * When the callback is invoked, status indicates the result:
969 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
970 * data is CREATE2res *
971 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
972 * data is the error string.
973 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
977 EXTERN
int rpc_nfs2_create_async(struct rpc_context
*rpc
, rpc_cb cb
, struct CREATE2args
*args
, void *private_data
);
982 * 0 : The call was initiated. The callback will be invoked when the call completes.
983 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
985 * When the callback is invoked, status indicates the result:
986 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
987 * data is REMOVE2res *
988 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
989 * data is the error string.
990 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
994 EXTERN
int rpc_nfs2_remove_async(struct rpc_context
*rpc
, rpc_cb cb
, struct REMOVE2args
*args
, void *private_data
);
999 * 0 : The call was initiated. The callback will be invoked when the call completes.
1000 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1002 * When the callback is invoked, status indicates the result:
1003 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
1004 * data is RENAME2res *
1005 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
1006 * data is the error string.
1007 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1011 EXTERN
int rpc_nfs2_rename_async(struct rpc_context
*rpc
, rpc_cb cb
, struct RENAME2args
*args
, void *private_data
);
1016 * 0 : The call was initiated. The callback will be invoked when the call completes.
1017 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1019 * When the callback is invoked, status indicates the result:
1020 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
1021 * data is LINK2res *
1022 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
1023 * data is the error string.
1024 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1028 EXTERN
int rpc_nfs2_link_async(struct rpc_context
*rpc
, rpc_cb cb
, struct LINK2args
*args
, void *private_data
);
1033 * 0 : The call was initiated. The callback will be invoked when the call completes.
1034 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1036 * When the callback is invoked, status indicates the result:
1037 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
1038 * data is SYMLINK2res *
1039 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
1040 * data is the error string.
1041 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1044 struct SYMLINK2args
;
1045 EXTERN
int rpc_nfs2_symlink_async(struct rpc_context
*rpc
, rpc_cb cb
, struct SYMLINK2args
*args
, void *private_data
);
1050 * 0 : The call was initiated. The callback will be invoked when the call completes.
1051 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1053 * When the callback is invoked, status indicates the result:
1054 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
1055 * data is MKDIR2res *
1056 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
1057 * data is the error string.
1058 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1062 EXTERN
int rpc_nfs2_mkdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct MKDIR2args
*args
, void *private_data
);
1067 * 0 : The call was initiated. The callback will be invoked when the call completes.
1068 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1070 * When the callback is invoked, status indicates the result:
1071 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
1072 * data is RMDIR2res *
1073 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
1074 * data is the error string.
1075 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1079 EXTERN
int rpc_nfs2_rmdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct RMDIR2args
*args
, void *private_data
);
1084 * 0 : The call was initiated. The callback will be invoked when the call completes.
1085 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1087 * When the callback is invoked, status indicates the result:
1088 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
1089 * data is READDIR2res *
1090 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
1091 * data is the error string.
1092 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1095 struct READDIR2args
;
1096 EXTERN
int rpc_nfs2_readdir_async(struct rpc_context
*rpc
, rpc_cb cb
, struct READDIR2args
*args
, void *private_data
);
1101 * 0 : The call was initiated. The callback will be invoked when the call completes.
1102 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1104 * When the callback is invoked, status indicates the result:
1105 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
1106 * data is STATFS2res *
1107 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
1108 * data is the error string.
1109 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1113 EXTERN
int rpc_nfs2_statfs_async(struct rpc_context
*rpc
, rpc_cb cb
, struct STATFS2args
*args
, void *private_data
);
1118 char *rquotastat_to_str(int error
);
1119 int rquotastat_to_errno(int error
);
1124 * 0 : The call was initiated. The callback will be invoked when the call completes.
1125 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1127 * When the callback is invoked, status indicates the result:
1128 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
1130 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
1131 * data is the error string.
1132 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1135 EXTERN
int rpc_rquota1_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
1138 * Call RQUOTA1/GETQUOTA
1140 * 0 : The call was initiated. The callback will be invoked when the call completes.
1141 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1143 * When the callback is invoked, status indicates the result:
1144 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
1145 * data is a RQUOTA1res structure.
1146 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
1147 * data is the error string.
1148 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1151 EXTERN
int rpc_rquota1_getquota_async(struct rpc_context
*rpc
, rpc_cb cb
, char *exportname
, int uid
, void *private_data
);
1154 * Call RQUOTA1/GETACTIVEQUOTA
1156 * 0 : The call was initiated. The callback will be invoked when the call completes.
1157 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1159 * When the callback is invoked, status indicates the result:
1160 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
1161 * data is a RQUOTA1res structure.
1162 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
1163 * data is the error string.
1164 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1167 EXTERN
int rpc_rquota1_getactivequota_async(struct rpc_context
*rpc
, rpc_cb cb
, char *exportname
, int uid
, void *private_data
);
1175 * 0 : The call was initiated. The callback will be invoked when the call completes.
1176 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1178 * When the callback is invoked, status indicates the result:
1179 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
1181 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
1182 * data is the error string.
1183 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1186 int rpc_rquota2_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
1189 * Call RQUOTA2/GETQUOTA
1191 * 0 : The call was initiated. The callback will be invoked when the call completes.
1192 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1194 * When the callback is invoked, status indicates the result:
1195 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
1196 * data is a RQUOTA1res structure.
1197 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
1198 * data is the error string.
1199 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1202 int rpc_rquota2_getquota_async(struct rpc_context
*rpc
, rpc_cb cb
, char *exportname
, int type
, int uid
, void *private_data
);
1205 * Call RQUOTA2/GETACTIVEQUOTA
1207 * 0 : The call was initiated. The callback will be invoked when the call completes.
1208 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1210 * When the callback is invoked, status indicates the result:
1211 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
1212 * data is a RQUOTA1res structure.
1213 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
1214 * data is the error string.
1215 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1218 int rpc_rquota2_getactivequota_async(struct rpc_context
*rpc
, rpc_cb cb
, char *exportname
, int type
, int uid
, void *private_data
);
1231 * Call the NULL procedure for the NFSACL
1234 * 0 : The call was initiated. The callback will be invoked when the call completes.
1235 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1237 * When the callback is invoked, status indicates the result:
1238 * RPC_STATUS_SUCCESS : We got a successful response from the rquota daemon.
1240 * RPC_STATUS_ERROR : An error occured when trying to contact the rquota daemon.
1241 * data is the error string.
1242 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1245 EXTERN
int rpc_nfsacl_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
1248 * Call NFSACL/GETACL
1251 * 0 : The call was initiated. The callback will be invoked when the call completes.
1252 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1254 * When the callback is invoked, status indicates the result:
1255 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
1256 * data is a GETACL3res pointer
1257 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
1258 * data is the error string.
1259 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1263 EXTERN
int rpc_nfsacl_getacl_async(struct rpc_context
*rpc
, rpc_cb cb
, struct GETACL3args
*args
, void *private_data
);
1268 * Call NFSACL/SETACL
1271 * 0 : The call was initiated. The callback will be invoked when the call completes.
1272 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1274 * When the callback is invoked, status indicates the result:
1275 * RPC_STATUS_SUCCESS : We got a successful response from the nfs daemon.
1276 * data is a SETACL3res pointer
1277 * RPC_STATUS_ERROR : An error occured when trying to contact the nfs daemon.
1278 * data is the error string.
1279 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1283 EXTERN
int rpc_nfsacl_setacl_async(struct rpc_context
*rpc
, rpc_cb cb
, struct SETACL3args
*args
, void *private_data
);
1291 char *nlmstat4_to_str(int stat
);
1295 * Call the NULL procedure for the NLM protocol
1298 * 0 : The call was initiated. The callback will be invoked when the call completes.
1299 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1301 * When the callback is invoked, status indicates the result:
1302 * RPC_STATUS_SUCCESS : We got a successful response from the nlm daemon.
1304 * RPC_STATUS_ERROR : An error occured when trying to contact the nlm daemon.
1305 * data is the error string.
1306 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1309 EXTERN
int rpc_nlm4_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
1313 * Call the TEST procedure for the NLM protocol
1316 * 0 : The call was initiated. The callback will be invoked when the call completes.
1317 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1319 * When the callback is invoked, status indicates the result:
1320 * RPC_STATUS_SUCCESS : We got a successful response from the nlm daemon.
1321 * data is NLM4_TESTres
1322 * RPC_STATUS_ERROR : An error occured when trying to contact the nlm daemon.
1323 * data is the error string.
1324 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1327 struct NLM4_TESTargs
;
1328 EXTERN
int rpc_nlm4_test_async(struct rpc_context
*rpc
, rpc_cb cb
, struct NLM4_TESTargs
*args
, void *private_data
);
1332 * Call the LOCK procedure for the NLM protocol
1335 * 0 : The call was initiated. The callback will be invoked when the call completes.
1336 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1338 * When the callback is invoked, status indicates the result:
1339 * RPC_STATUS_SUCCESS : We got a successful response from the nlm daemon.
1340 * data is NLM4_LOCKres
1341 * RPC_STATUS_ERROR : An error occured when trying to contact the nlm daemon.
1342 * data is the error string.
1343 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1346 struct NLM4_LOCKargs
;
1347 EXTERN
int rpc_nlm4_lock_async(struct rpc_context
*rpc
, rpc_cb cb
, struct NLM4_LOCKargs
*args
, void *private_data
);
1351 * Call the CANCEL procedure for the NLM protocol
1354 * 0 : The call was initiated. The callback will be invoked when the call completes.
1355 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1357 * When the callback is invoked, status indicates the result:
1358 * RPC_STATUS_SUCCESS : We got a successful response from the nlm daemon.
1359 * data is NLM4_CANCres
1360 * RPC_STATUS_ERROR : An error occured when trying to contact the nlm daemon.
1361 * data is the error string.
1362 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1365 struct NLM4_CANCargs
;
1366 EXTERN
int rpc_nlm4_cancel_async(struct rpc_context
*rpc
, rpc_cb cb
, struct NLM4_CANCargs
*args
, void *private_data
);
1370 * Call the UNLOCK procedure for the NLM protocol
1373 * 0 : The call was initiated. The callback will be invoked when the call completes.
1374 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1376 * When the callback is invoked, status indicates the result:
1377 * RPC_STATUS_SUCCESS : We got a successful response from the nlm daemon.
1378 * data is NLM4_UNLOCKres
1379 * RPC_STATUS_ERROR : An error occured when trying to contact the nlm daemon.
1380 * data is the error string.
1381 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1384 struct NLM4_UNLOCKargs
;
1385 EXTERN
int rpc_nlm4_unlock_async(struct rpc_context
*rpc
, rpc_cb cb
, struct NLM4_UNLOCKargs
*args
, void *private_data
);
1390 char *nsmstat1_to_str(int stat
);
1394 * Call the NULL procedure for the NSM protocol
1397 * 0 : The call was initiated. The callback will be invoked when the call completes.
1398 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1400 * When the callback is invoked, status indicates the result:
1401 * RPC_STATUS_SUCCESS : We got a successful response from the nsm daemon.
1403 * RPC_STATUS_ERROR : An error occured when trying to contact the nsm daemon.
1404 * data is the error string.
1405 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1408 EXTERN
int rpc_nsm1_null_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
1412 * Call the STAT procedure for the NSM protocol
1415 * 0 : The call was initiated. The callback will be invoked when the call completes.
1416 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1418 * When the callback is invoked, status indicates the result:
1419 * RPC_STATUS_SUCCESS : We got a successful response from the nsm daemon.
1420 * data is NSM1_STATres
1421 * RPC_STATUS_ERROR : An error occured when trying to contact the nsm daemon.
1422 * data is the error string.
1423 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1426 struct NSM1_STATargs
;
1427 EXTERN
int rpc_nsm1_stat_async(struct rpc_context
*rpc
, rpc_cb cb
, struct NSM1_STATargs
*args
, void *private_data
);
1431 * Call the MON procedure for the NSM protocol
1434 * 0 : The call was initiated. The callback will be invoked when the call completes.
1435 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1437 * When the callback is invoked, status indicates the result:
1438 * RPC_STATUS_SUCCESS : We got a successful response from the nsm daemon.
1439 * data is NSM1_MONres
1440 * RPC_STATUS_ERROR : An error occured when trying to contact the nsm daemon.
1441 * data is the error string.
1442 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1445 struct NSM1_MONargs
;
1446 EXTERN
int rpc_nsm1_mon_async(struct rpc_context
*rpc
, rpc_cb cb
, struct NSM1_MONargs
*args
, void *private_data
);
1450 * Call the UNMON procedure for the NSM protocol
1453 * 0 : The call was initiated. The callback will be invoked when the call completes.
1454 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1456 * When the callback is invoked, status indicates the result:
1457 * RPC_STATUS_SUCCESS : We got a successful response from the nsm daemon.
1458 * data is NSM1_UNMONres
1459 * RPC_STATUS_ERROR : An error occured when trying to contact the nsm daemon.
1460 * data is the error string.
1461 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1464 struct NSM1_UNMONargs
;
1465 EXTERN
int rpc_nsm1_unmon_async(struct rpc_context
*rpc
, rpc_cb cb
, struct NSM1_UNMONargs
*args
, void *private_data
);
1469 * Call the UNMONALL procedure for the NSM protocol
1472 * 0 : The call was initiated. The callback will be invoked when the call completes.
1473 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1475 * When the callback is invoked, status indicates the result:
1476 * RPC_STATUS_SUCCESS : We got a successful response from the nsm daemon.
1477 * data is NSM1_UNMONALLres
1478 * RPC_STATUS_ERROR : An error occured when trying to contact the nsm daemon.
1479 * data is the error string.
1480 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1483 struct NSM1_UNMONALLargs
;
1484 EXTERN
int rpc_nsm1_unmonall_async(struct rpc_context
*rpc
, rpc_cb cb
, struct NSM1_UNMONALLargs
*args
, void *private_data
);
1487 * Call NSM/SIMUCRASH
1488 * Call the SIMUCRASH procedure for the NSM protocol
1491 * 0 : The call was initiated. The callback will be invoked when the call completes.
1492 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1494 * When the callback is invoked, status indicates the result:
1495 * RPC_STATUS_SUCCESS : We got a successful response from the nsm daemon.
1497 * RPC_STATUS_ERROR : An error occured when trying to contact the nsm daemon.
1498 * data is the error string.
1499 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1502 EXTERN
int rpc_nsm1_simucrash_async(struct rpc_context
*rpc
, rpc_cb cb
, void *private_data
);
1506 * Call the NOTIFY procedure for the NSM protocol
1509 * 0 : The call was initiated. The callback will be invoked when the call completes.
1510 * <0 : An error occured when trying to set up the call. The callback will not be invoked.
1512 * When the callback is invoked, status indicates the result:
1513 * RPC_STATUS_SUCCESS : We got a successful response from the nsm daemon.
1515 * RPC_STATUS_ERROR : An error occured when trying to contact the nsm daemon.
1516 * data is the error string.
1517 * RPC_STATUS_CANCEL : The connection attempt was aborted before it could complete.
1520 struct NSM1_NOTIFYargs
;
1521 EXTERN
int rpc_nsm1_notify_async(struct rpc_context
*rpc
, rpc_cb cb
, struct NSM1_NOTIFYargs
*args
, void *private_data
);