1/*
2 * Please do not edit this file.
3 * It was generated using rpcgen.
4 */
5
6#ifndef _NLM_PROT_H_RPCGEN
7#define	_NLM_PROT_H_RPCGEN
8
9#include <rpc/rpc.h>
10
11#ifdef __cplusplus
12extern "C" {
13#endif
14
15#define LM_MAXSTRLEN 1024
16#define MAXNAMELEN LM_MAXSTRLEN+1
17
18enum nlm_stats {
19	nlm_granted = 0,
20	nlm_denied = 1,
21	nlm_denied_nolocks = 2,
22	nlm_blocked = 3,
23	nlm_denied_grace_period = 4,
24	nlm_deadlck = 5
25};
26typedef enum nlm_stats nlm_stats;
27
28struct nlm_holder {
29	bool_t exclusive;
30	int svid;
31	netobj oh;
32	u_int l_offset;
33	u_int l_len;
34};
35typedef struct nlm_holder nlm_holder;
36
37struct nlm_testrply {
38	nlm_stats stat;
39	union {
40		struct nlm_holder holder;
41	} nlm_testrply_u;
42};
43typedef struct nlm_testrply nlm_testrply;
44
45struct nlm_stat {
46	nlm_stats stat;
47};
48typedef struct nlm_stat nlm_stat;
49
50struct nlm_res {
51	netobj cookie;
52	nlm_stat stat;
53};
54typedef struct nlm_res nlm_res;
55
56struct nlm_testres {
57	netobj cookie;
58	nlm_testrply stat;
59};
60typedef struct nlm_testres nlm_testres;
61
62struct nlm_lock {
63	char *caller_name;
64	netobj fh;
65	netobj oh;
66	int svid;
67	u_int l_offset;
68	u_int l_len;
69};
70typedef struct nlm_lock nlm_lock;
71
72struct nlm_lockargs {
73	netobj cookie;
74	bool_t block;
75	bool_t exclusive;
76	struct nlm_lock alock;
77	bool_t reclaim;
78	int state;
79};
80typedef struct nlm_lockargs nlm_lockargs;
81
82struct nlm_cancargs {
83	netobj cookie;
84	bool_t block;
85	bool_t exclusive;
86	struct nlm_lock alock;
87};
88typedef struct nlm_cancargs nlm_cancargs;
89
90struct nlm_testargs {
91	netobj cookie;
92	bool_t exclusive;
93	struct nlm_lock alock;
94};
95typedef struct nlm_testargs nlm_testargs;
96
97struct nlm_unlockargs {
98	netobj cookie;
99	struct nlm_lock alock;
100};
101typedef struct nlm_unlockargs nlm_unlockargs;
102/*
103 * The following enums are actually bit encoded for efficient
104 * boolean algebra.... DON'T change them.....
105 */
106
107enum fsh_mode {
108	fsm_DN = 0,
109	fsm_DR = 1,
110	fsm_DW = 2,
111	fsm_DRW = 3
112};
113typedef enum fsh_mode fsh_mode;
114
115enum fsh_access {
116	fsa_NONE = 0,
117	fsa_R = 1,
118	fsa_W = 2,
119	fsa_RW = 3
120};
121typedef enum fsh_access fsh_access;
122
123struct nlm_share {
124	char *caller_name;
125	netobj fh;
126	netobj oh;
127	fsh_mode mode;
128	fsh_access access;
129};
130typedef struct nlm_share nlm_share;
131
132struct nlm_shareargs {
133	netobj cookie;
134	nlm_share share;
135	bool_t reclaim;
136};
137typedef struct nlm_shareargs nlm_shareargs;
138
139struct nlm_shareres {
140	netobj cookie;
141	nlm_stats stat;
142	int sequence;
143};
144typedef struct nlm_shareres nlm_shareres;
145
146struct nlm_notify {
147	char *name;
148	long state;
149};
150typedef struct nlm_notify nlm_notify;
151/* definitions for NLM version 4 */
152
153enum nlm4_stats {
154	nlm4_granted = 0,
155	nlm4_denied = 1,
156	nlm4_denied_nolocks = 2,
157	nlm4_blocked = 3,
158	nlm4_denied_grace_period = 4,
159	nlm4_deadlck = 5,
160	nlm4_rofs = 6,
161	nlm4_stale_fh = 7,
162	nlm4_fbig = 8,
163	nlm4_failed = 9
164};
165typedef enum nlm4_stats nlm4_stats;
166
167struct nlm4_stat {
168	nlm4_stats stat;
169};
170typedef struct nlm4_stat nlm4_stat;
171
172struct nlm4_holder {
173	bool_t exclusive;
174	uint32_t svid;
175	netobj oh;
176	uint64_t l_offset;
177	uint64_t l_len;
178};
179typedef struct nlm4_holder nlm4_holder;
180
181struct nlm4_lock {
182	char *caller_name;
183	netobj fh;
184	netobj oh;
185	uint32_t svid;
186	uint64_t l_offset;
187	uint64_t l_len;
188};
189typedef struct nlm4_lock nlm4_lock;
190
191struct nlm4_share {
192	char *caller_name;
193	netobj fh;
194	netobj oh;
195	fsh_mode mode;
196	fsh_access access;
197};
198typedef struct nlm4_share nlm4_share;
199
200struct nlm4_testrply {
201	nlm4_stats stat;
202	union {
203		struct nlm4_holder holder;
204	} nlm4_testrply_u;
205};
206typedef struct nlm4_testrply nlm4_testrply;
207
208struct nlm4_testres {
209	netobj cookie;
210	nlm4_testrply stat;
211};
212typedef struct nlm4_testres nlm4_testres;
213
214struct nlm4_testargs {
215	netobj cookie;
216	bool_t exclusive;
217	struct nlm4_lock alock;
218};
219typedef struct nlm4_testargs nlm4_testargs;
220
221struct nlm4_res {
222	netobj cookie;
223	nlm4_stat stat;
224};
225typedef struct nlm4_res nlm4_res;
226
227struct nlm4_lockargs {
228	netobj cookie;
229	bool_t block;
230	bool_t exclusive;
231	struct nlm4_lock alock;
232	bool_t reclaim;
233	int state;
234};
235typedef struct nlm4_lockargs nlm4_lockargs;
236
237struct nlm4_cancargs {
238	netobj cookie;
239	bool_t block;
240	bool_t exclusive;
241	struct nlm4_lock alock;
242};
243typedef struct nlm4_cancargs nlm4_cancargs;
244
245struct nlm4_unlockargs {
246	netobj cookie;
247	struct nlm4_lock alock;
248};
249typedef struct nlm4_unlockargs nlm4_unlockargs;
250
251struct nlm4_shareargs {
252	netobj cookie;
253	nlm4_share share;
254	bool_t reclaim;
255};
256typedef struct nlm4_shareargs nlm4_shareargs;
257
258struct nlm4_shareres {
259	netobj cookie;
260	nlm4_stats stat;
261	int sequence;
262};
263typedef struct nlm4_shareres nlm4_shareres;
264
265struct nlm_sm_status {
266	char *mon_name;
267	int state;
268	char priv[16];
269};
270typedef struct nlm_sm_status nlm_sm_status;
271
272struct nlm4_notify {
273	char *name;
274	int32_t state;
275};
276typedef struct nlm4_notify nlm4_notify;
277
278#define	NLM_PROG ((unsigned long)(100021))
279#define	NLM_SM ((unsigned long)(0))
280
281#define	NLM_SM_NOTIFY ((unsigned long)(1))
282extern  enum clnt_stat nlm_sm_notify_0(struct nlm_sm_status *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
283extern  bool_t nlm_sm_notify_0_svc(struct nlm_sm_status *, void *, struct svc_req *);
284#define	NLM_VERS ((unsigned long)(1))
285
286#define	NLM_TEST ((unsigned long)(1))
287extern  enum clnt_stat nlm_test_1(struct nlm_testargs *, nlm_testres *, CLIENT *, struct rpc_callextra *, struct timeval);
288extern  bool_t nlm_test_1_svc(struct nlm_testargs *, nlm_testres *, struct svc_req *);
289#define	NLM_LOCK ((unsigned long)(2))
290extern  enum clnt_stat nlm_lock_1(struct nlm_lockargs *, nlm_res *, CLIENT *, struct rpc_callextra *, struct timeval);
291extern  bool_t nlm_lock_1_svc(struct nlm_lockargs *, nlm_res *, struct svc_req *);
292#define	NLM_CANCEL ((unsigned long)(3))
293extern  enum clnt_stat nlm_cancel_1(struct nlm_cancargs *, nlm_res *, CLIENT *, struct rpc_callextra *, struct timeval);
294extern  bool_t nlm_cancel_1_svc(struct nlm_cancargs *, nlm_res *, struct svc_req *);
295#define	NLM_UNLOCK ((unsigned long)(4))
296extern  enum clnt_stat nlm_unlock_1(struct nlm_unlockargs *, nlm_res *, CLIENT *, struct rpc_callextra *, struct timeval);
297extern  bool_t nlm_unlock_1_svc(struct nlm_unlockargs *, nlm_res *, struct svc_req *);
298#define	NLM_GRANTED ((unsigned long)(5))
299extern  enum clnt_stat nlm_granted_1(struct nlm_testargs *, nlm_res *, CLIENT *, struct rpc_callextra *, struct timeval);
300extern  bool_t nlm_granted_1_svc(struct nlm_testargs *, nlm_res *, struct svc_req *);
301#define	NLM_TEST_MSG ((unsigned long)(6))
302extern  enum clnt_stat nlm_test_msg_1(struct nlm_testargs *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
303extern  bool_t nlm_test_msg_1_svc(struct nlm_testargs *, void *, struct svc_req *);
304#define	NLM_LOCK_MSG ((unsigned long)(7))
305extern  enum clnt_stat nlm_lock_msg_1(struct nlm_lockargs *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
306extern  bool_t nlm_lock_msg_1_svc(struct nlm_lockargs *, void *, struct svc_req *);
307#define	NLM_CANCEL_MSG ((unsigned long)(8))
308extern  enum clnt_stat nlm_cancel_msg_1(struct nlm_cancargs *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
309extern  bool_t nlm_cancel_msg_1_svc(struct nlm_cancargs *, void *, struct svc_req *);
310#define	NLM_UNLOCK_MSG ((unsigned long)(9))
311extern  enum clnt_stat nlm_unlock_msg_1(struct nlm_unlockargs *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
312extern  bool_t nlm_unlock_msg_1_svc(struct nlm_unlockargs *, void *, struct svc_req *);
313#define	NLM_GRANTED_MSG ((unsigned long)(10))
314extern  enum clnt_stat nlm_granted_msg_1(struct nlm_testargs *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
315extern  bool_t nlm_granted_msg_1_svc(struct nlm_testargs *, void *, struct svc_req *);
316#define	NLM_TEST_RES ((unsigned long)(11))
317extern  enum clnt_stat nlm_test_res_1(nlm_testres *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
318extern  bool_t nlm_test_res_1_svc(nlm_testres *, void *, struct svc_req *);
319#define	NLM_LOCK_RES ((unsigned long)(12))
320extern  enum clnt_stat nlm_lock_res_1(nlm_res *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
321extern  bool_t nlm_lock_res_1_svc(nlm_res *, void *, struct svc_req *);
322#define	NLM_CANCEL_RES ((unsigned long)(13))
323extern  enum clnt_stat nlm_cancel_res_1(nlm_res *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
324extern  bool_t nlm_cancel_res_1_svc(nlm_res *, void *, struct svc_req *);
325#define	NLM_UNLOCK_RES ((unsigned long)(14))
326extern  enum clnt_stat nlm_unlock_res_1(nlm_res *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
327extern  bool_t nlm_unlock_res_1_svc(nlm_res *, void *, struct svc_req *);
328#define	NLM_GRANTED_RES ((unsigned long)(15))
329extern  enum clnt_stat nlm_granted_res_1(nlm_res *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
330extern  bool_t nlm_granted_res_1_svc(nlm_res *, void *, struct svc_req *);
331extern int nlm_prog_1_freeresult(SVCXPRT *, xdrproc_t, caddr_t);
332#define	NLM_VERSX ((unsigned long)(3))
333
334#define	NLM_SHARE ((unsigned long)(20))
335extern  enum clnt_stat nlm_share_3(nlm_shareargs *, nlm_shareres *, CLIENT *, struct rpc_callextra *, struct timeval);
336extern  bool_t nlm_share_3_svc(nlm_shareargs *, nlm_shareres *, struct svc_req *);
337#define	NLM_UNSHARE ((unsigned long)(21))
338extern  enum clnt_stat nlm_unshare_3(nlm_shareargs *, nlm_shareres *, CLIENT *, struct rpc_callextra *, struct timeval);
339extern  bool_t nlm_unshare_3_svc(nlm_shareargs *, nlm_shareres *, struct svc_req *);
340#define	NLM_NM_LOCK ((unsigned long)(22))
341extern  enum clnt_stat nlm_nm_lock_3(nlm_lockargs *, nlm_res *, CLIENT *, struct rpc_callextra *, struct timeval);
342extern  bool_t nlm_nm_lock_3_svc(nlm_lockargs *, nlm_res *, struct svc_req *);
343#define	NLM_FREE_ALL ((unsigned long)(23))
344extern  enum clnt_stat nlm_free_all_3(nlm_notify *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
345extern  bool_t nlm_free_all_3_svc(nlm_notify *, void *, struct svc_req *);
346extern int nlm_prog_3_freeresult(SVCXPRT *, xdrproc_t, caddr_t);
347#define	NLM_VERS4 ((unsigned long)(4))
348
349#define	NLM4_TEST ((unsigned long)(1))
350extern  enum clnt_stat nlm4_test_4(nlm4_testargs *, nlm4_testres *, CLIENT *, struct rpc_callextra *, struct timeval);
351extern  bool_t nlm4_test_4_svc(nlm4_testargs *, nlm4_testres *, struct svc_req *);
352#define	NLM4_LOCK ((unsigned long)(2))
353extern  enum clnt_stat nlm4_lock_4(nlm4_lockargs *, nlm4_res *, CLIENT *, struct rpc_callextra *, struct timeval);
354extern  bool_t nlm4_lock_4_svc(nlm4_lockargs *, nlm4_res *, struct svc_req *);
355#define	NLM4_CANCEL ((unsigned long)(3))
356extern  enum clnt_stat nlm4_cancel_4(nlm4_cancargs *, nlm4_res *, CLIENT *, struct rpc_callextra *, struct timeval);
357extern  bool_t nlm4_cancel_4_svc(nlm4_cancargs *, nlm4_res *, struct svc_req *);
358#define	NLM4_UNLOCK ((unsigned long)(4))
359extern  enum clnt_stat nlm4_unlock_4(nlm4_unlockargs *, nlm4_res *, CLIENT *, struct rpc_callextra *, struct timeval);
360extern  bool_t nlm4_unlock_4_svc(nlm4_unlockargs *, nlm4_res *, struct svc_req *);
361#define	NLM4_GRANTED ((unsigned long)(5))
362extern  enum clnt_stat nlm4_granted_4(nlm4_testargs *, nlm4_res *, CLIENT *, struct rpc_callextra *, struct timeval);
363extern  bool_t nlm4_granted_4_svc(nlm4_testargs *, nlm4_res *, struct svc_req *);
364#define	NLM4_TEST_MSG ((unsigned long)(6))
365extern  enum clnt_stat nlm4_test_msg_4(nlm4_testargs *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
366extern  bool_t nlm4_test_msg_4_svc(nlm4_testargs *, void *, struct svc_req *);
367#define	NLM4_LOCK_MSG ((unsigned long)(7))
368extern  enum clnt_stat nlm4_lock_msg_4(nlm4_lockargs *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
369extern  bool_t nlm4_lock_msg_4_svc(nlm4_lockargs *, void *, struct svc_req *);
370#define	NLM4_CANCEL_MSG ((unsigned long)(8))
371extern  enum clnt_stat nlm4_cancel_msg_4(nlm4_cancargs *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
372extern  bool_t nlm4_cancel_msg_4_svc(nlm4_cancargs *, void *, struct svc_req *);
373#define	NLM4_UNLOCK_MSG ((unsigned long)(9))
374extern  enum clnt_stat nlm4_unlock_msg_4(nlm4_unlockargs *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
375extern  bool_t nlm4_unlock_msg_4_svc(nlm4_unlockargs *, void *, struct svc_req *);
376#define	NLM4_GRANTED_MSG ((unsigned long)(10))
377extern  enum clnt_stat nlm4_granted_msg_4(nlm4_testargs *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
378extern  bool_t nlm4_granted_msg_4_svc(nlm4_testargs *, void *, struct svc_req *);
379#define	NLM4_TEST_RES ((unsigned long)(11))
380extern  enum clnt_stat nlm4_test_res_4(nlm4_testres *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
381extern  bool_t nlm4_test_res_4_svc(nlm4_testres *, void *, struct svc_req *);
382#define	NLM4_LOCK_RES ((unsigned long)(12))
383extern  enum clnt_stat nlm4_lock_res_4(nlm4_res *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
384extern  bool_t nlm4_lock_res_4_svc(nlm4_res *, void *, struct svc_req *);
385#define	NLM4_CANCEL_RES ((unsigned long)(13))
386extern  enum clnt_stat nlm4_cancel_res_4(nlm4_res *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
387extern  bool_t nlm4_cancel_res_4_svc(nlm4_res *, void *, struct svc_req *);
388#define	NLM4_UNLOCK_RES ((unsigned long)(14))
389extern  enum clnt_stat nlm4_unlock_res_4(nlm4_res *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
390extern  bool_t nlm4_unlock_res_4_svc(nlm4_res *, void *, struct svc_req *);
391#define	NLM4_GRANTED_RES ((unsigned long)(15))
392extern  enum clnt_stat nlm4_granted_res_4(nlm4_res *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
393extern  bool_t nlm4_granted_res_4_svc(nlm4_res *, void *, struct svc_req *);
394#define	NLM4_SHARE ((unsigned long)(20))
395extern  enum clnt_stat nlm4_share_4(nlm4_shareargs *, nlm4_shareres *, CLIENT *, struct rpc_callextra *, struct timeval);
396extern  bool_t nlm4_share_4_svc(nlm4_shareargs *, nlm4_shareres *, struct svc_req *);
397#define	NLM4_UNSHARE ((unsigned long)(21))
398extern  enum clnt_stat nlm4_unshare_4(nlm4_shareargs *, nlm4_shareres *, CLIENT *, struct rpc_callextra *, struct timeval);
399extern  bool_t nlm4_unshare_4_svc(nlm4_shareargs *, nlm4_shareres *, struct svc_req *);
400#define	NLM4_NM_LOCK ((unsigned long)(22))
401extern  enum clnt_stat nlm4_nm_lock_4(nlm4_lockargs *, nlm4_res *, CLIENT *, struct rpc_callextra *, struct timeval);
402extern  bool_t nlm4_nm_lock_4_svc(nlm4_lockargs *, nlm4_res *, struct svc_req *);
403#define	NLM4_FREE_ALL ((unsigned long)(23))
404extern  enum clnt_stat nlm4_free_all_4(nlm4_notify *, void *, CLIENT *, struct rpc_callextra *, struct timeval);
405extern  bool_t nlm4_free_all_4_svc(nlm4_notify *, void *, struct svc_req *);
406extern int nlm_prog_4_freeresult(SVCXPRT *, xdrproc_t, caddr_t);
407
408/* the xdr functions */
409extern  bool_t xdr_nlm_stats(XDR *, nlm_stats*);
410extern  bool_t xdr_nlm_holder(XDR *, nlm_holder*);
411extern  bool_t xdr_nlm_testrply(XDR *, nlm_testrply*);
412extern  bool_t xdr_nlm_stat(XDR *, nlm_stat*);
413extern  bool_t xdr_nlm_res(XDR *, nlm_res*);
414extern  bool_t xdr_nlm_testres(XDR *, nlm_testres*);
415extern  bool_t xdr_nlm_lock(XDR *, nlm_lock*);
416extern  bool_t xdr_nlm_lockargs(XDR *, nlm_lockargs*);
417extern  bool_t xdr_nlm_cancargs(XDR *, nlm_cancargs*);
418extern  bool_t xdr_nlm_testargs(XDR *, nlm_testargs*);
419extern  bool_t xdr_nlm_unlockargs(XDR *, nlm_unlockargs*);
420extern  bool_t xdr_fsh_mode(XDR *, fsh_mode*);
421extern  bool_t xdr_fsh_access(XDR *, fsh_access*);
422extern  bool_t xdr_nlm_share(XDR *, nlm_share*);
423extern  bool_t xdr_nlm_shareargs(XDR *, nlm_shareargs*);
424extern  bool_t xdr_nlm_shareres(XDR *, nlm_shareres*);
425extern  bool_t xdr_nlm_notify(XDR *, nlm_notify*);
426extern  bool_t xdr_nlm4_stats(XDR *, nlm4_stats*);
427extern  bool_t xdr_nlm4_stat(XDR *, nlm4_stat*);
428extern  bool_t xdr_nlm4_holder(XDR *, nlm4_holder*);
429extern  bool_t xdr_nlm4_lock(XDR *, nlm4_lock*);
430extern  bool_t xdr_nlm4_share(XDR *, nlm4_share*);
431extern  bool_t xdr_nlm4_testrply(XDR *, nlm4_testrply*);
432extern  bool_t xdr_nlm4_testres(XDR *, nlm4_testres*);
433extern  bool_t xdr_nlm4_testargs(XDR *, nlm4_testargs*);
434extern  bool_t xdr_nlm4_res(XDR *, nlm4_res*);
435extern  bool_t xdr_nlm4_lockargs(XDR *, nlm4_lockargs*);
436extern  bool_t xdr_nlm4_cancargs(XDR *, nlm4_cancargs*);
437extern  bool_t xdr_nlm4_unlockargs(XDR *, nlm4_unlockargs*);
438extern  bool_t xdr_nlm4_shareargs(XDR *, nlm4_shareargs*);
439extern  bool_t xdr_nlm4_shareres(XDR *, nlm4_shareres*);
440extern  bool_t xdr_nlm_sm_status(XDR *, nlm_sm_status*);
441extern  bool_t xdr_nlm4_notify(XDR *, nlm4_notify*);
442
443#ifdef __cplusplus
444}
445#endif
446
447#endif /* !_NLM_PROT_H_RPCGEN */
448