diff options
author | Chuck Lever <chuck.lever@oracle.com> | 2010-01-14 12:24:39 -0500 |
---|---|---|
committer | Steve Dickson <steved@redhat.com> | 2010-01-15 14:55:52 -0500 |
commit | 7dd134204d88c22b414a4ecfcd986efb57fedebf (patch) | |
tree | 6bd69aac2d908848a019394121de166b9fa7548a /support/include/rpcmisc.h | |
parent | e2446fda6e7cdb1b9462162b81b0e50fd6efaf56 (diff) | |
download | nfs-utils-7dd134204d88c22b414a4ecfcd986efb57fedebf.tar.gz nfs-utils-7dd134204d88c22b414a4ecfcd986efb57fedebf.tar.xz nfs-utils-7dd134204d88c22b414a4ecfcd986efb57fedebf.zip |
statd: Support TI-RPC statd listener
If TI-RPC is available, use it to create statd's svc listener. If
not, use the old function, rpc_init(), to create statd's listener.
IPv6 can be supported if TI-RPC is available. In this case,
/etc/netconfig is searched to determine which transports to advertise.
Add the new listener creation API in libnfs.a since other components
of nfs-utils (such as rpc.mountd) will eventually want to share it.
A little re-arrangement of when the statd listener is created is done
to make unregistration of the statd service more reliable. As it is
now, the statd service is never unregistered when it exits. After it
is gone, other programs usually hang when trying to access statd or
see if it's running, since the registration is still there but statd
itself does not respond.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Diffstat (limited to 'support/include/rpcmisc.h')
-rw-r--r-- | support/include/rpcmisc.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/support/include/rpcmisc.h b/support/include/rpcmisc.h index f551a85..1b8f411 100644 --- a/support/include/rpcmisc.h +++ b/support/include/rpcmisc.h @@ -41,7 +41,12 @@ struct rpc_dtable { (xdrproc_t)xdr_##res_type, sizeof(res_type), \ } - +void nfs_svc_unregister(const rpcprog_t program, + const rpcvers_t version); +unsigned int nfs_svc_create(char *name, const rpcprog_t program, + const rpcvers_t version, + void (*dispatch)(struct svc_req *, SVCXPRT *), + const uint16_t port); void rpc_init(char *name, int prog, int vers, void (*dispatch)(struct svc_req *, SVCXPRT *), int defport); |