/*
 * Please do not edit this file.
 * It was generated using rpcgen.
 */

#ifndef _KLM_PROT_H_RPCGEN
#define _KLM_PROT_H_RPCGEN

#include <rpc/rpc.h>

/*
 * Sun RPC is a product of Sun Microsystems, Inc. and is provided for
 * unrestricted use provided that this legend is included on all tape
 * media and as a part of the software program in whole or part.  Users
 * may copy or modify Sun RPC without charge, but are not authorized
 * to license or distribute it to anyone else except as part of a product or
 * program developed by the user or with the express written consent of
 * Sun Microsystems, Inc.
 *
 * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
 * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
 * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
 *
 * Sun RPC is provided with no support and without any obligation on the
 * part of Sun Microsystems, Inc. to assist in its use, correction,
 * modification or enhancement.
 *
 * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
 * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
 * OR ANY PART THEREOF.
 *
 * In no event will Sun Microsystems, Inc. be liable for any lost revenue
 * or profits or other special, indirect and consequential damages, even if
 * Sun has been advised of the possibility of such damages.
 *
 * Sun Microsystems, Inc.
 * 2550 Garcia Avenue
 * Mountain View, California  94043
 */
/*
 * Copyright (c) 1986, 1990 by Sun Microsystems, Inc.
 */

/* from @(#)klm_prot.x	1.4 91/03/11 TIRPC 1.0 */
#ifndef _rpcsvc_klm_prot_h
#define _rpcsvc_klm_prot_h 
#define LM_MAXSTRLEN 1024

enum klm_stats {
	klm_granted = 0,
	klm_denied = 1,
	klm_denied_nolocks = 2,
	klm_working = 3,
};
typedef enum klm_stats klm_stats;
#ifdef __cplusplus 
extern "C" bool_t xdr_klm_stats(XDR *, klm_stats*);
#elif __STDC__ 
extern  bool_t xdr_klm_stats(XDR *, klm_stats*);
#else /* Old Style C */ 
bool_t xdr_klm_stats();
#endif /* Old Style C */ 


struct klm_lock {
	char *server_name;
	netobj fh;
	int pid;
	u_int l_offset;
	u_int l_len;
};
typedef struct klm_lock klm_lock;
#ifdef __cplusplus 
extern "C" bool_t xdr_klm_lock(XDR *, klm_lock*);
#elif __STDC__ 
extern  bool_t xdr_klm_lock(XDR *, klm_lock*);
#else /* Old Style C */ 
bool_t xdr_klm_lock();
#endif /* Old Style C */ 


struct klm_holder {
	bool_t exclusive;
	int svid;
	u_int l_offset;
	u_int l_len;
};
typedef struct klm_holder klm_holder;
#ifdef __cplusplus 
extern "C" bool_t xdr_klm_holder(XDR *, klm_holder*);
#elif __STDC__ 
extern  bool_t xdr_klm_holder(XDR *, klm_holder*);
#else /* Old Style C */ 
bool_t xdr_klm_holder();
#endif /* Old Style C */ 


struct klm_stat {
	klm_stats stat;
};
typedef struct klm_stat klm_stat;
#ifdef __cplusplus 
extern "C" bool_t xdr_klm_stat(XDR *, klm_stat*);
#elif __STDC__ 
extern  bool_t xdr_klm_stat(XDR *, klm_stat*);
#else /* Old Style C */ 
bool_t xdr_klm_stat();
#endif /* Old Style C */ 


struct klm_testrply {
	klm_stats stat;
	union {
		struct klm_holder holder;
	} klm_testrply_u;
};
typedef struct klm_testrply klm_testrply;
#ifdef __cplusplus 
extern "C" bool_t xdr_klm_testrply(XDR *, klm_testrply*);
#elif __STDC__ 
extern  bool_t xdr_klm_testrply(XDR *, klm_testrply*);
#else /* Old Style C */ 
bool_t xdr_klm_testrply();
#endif /* Old Style C */ 


struct klm_lockargs {
	bool_t block;
	bool_t exclusive;
	struct klm_lock alock;
};
typedef struct klm_lockargs klm_lockargs;
#ifdef __cplusplus 
extern "C" bool_t xdr_klm_lockargs(XDR *, klm_lockargs*);
#elif __STDC__ 
extern  bool_t xdr_klm_lockargs(XDR *, klm_lockargs*);
#else /* Old Style C */ 
bool_t xdr_klm_lockargs();
#endif /* Old Style C */ 


struct klm_testargs {
	bool_t exclusive;
	struct klm_lock alock;
};
typedef struct klm_testargs klm_testargs;
#ifdef __cplusplus 
extern "C" bool_t xdr_klm_testargs(XDR *, klm_testargs*);
#elif __STDC__ 
extern  bool_t xdr_klm_testargs(XDR *, klm_testargs*);
#else /* Old Style C */ 
bool_t xdr_klm_testargs();
#endif /* Old Style C */ 


struct klm_unlockargs {
	struct klm_lock alock;
};
typedef struct klm_unlockargs klm_unlockargs;
#ifdef __cplusplus 
extern "C" bool_t xdr_klm_unlockargs(XDR *, klm_unlockargs*);
#elif __STDC__ 
extern  bool_t xdr_klm_unlockargs(XDR *, klm_unlockargs*);
#else /* Old Style C */ 
bool_t xdr_klm_unlockargs();
#endif /* Old Style C */ 

#endif /*!_rpcsvc_klm_prot_h*/

#define KLM_PROG ((u_long)100020)
#define KLM_VERS ((u_long)1)

#ifdef __cplusplus
#define KLM_TEST ((u_long)1)
extern "C" klm_testrply * klm_test_1(struct klm_testargs *, CLIENT *);
extern "C" klm_testrply * klm_test_1_svc(struct klm_testargs *, struct svc_req *);
#define KLM_LOCK ((u_long)2)
extern "C" klm_stat * klm_lock_1(struct klm_lockargs *, CLIENT *);
extern "C" klm_stat * klm_lock_1_svc(struct klm_lockargs *, struct svc_req *);
#define KLM_CANCEL ((u_long)3)
extern "C" klm_stat * klm_cancel_1(struct klm_lockargs *, CLIENT *);
extern "C" klm_stat * klm_cancel_1_svc(struct klm_lockargs *, struct svc_req *);
#define KLM_UNLOCK ((u_long)4)
extern "C" klm_stat * klm_unlock_1(struct klm_unlockargs *, CLIENT *);
extern "C" klm_stat * klm_unlock_1_svc(struct klm_unlockargs *, struct svc_req *);

#elif __STDC__
#define KLM_TEST ((u_long)1)
extern  klm_testrply * klm_test_1(struct klm_testargs *, CLIENT *);
extern  klm_testrply * klm_test_1_svc(struct klm_testargs *, struct svc_req *);
#define KLM_LOCK ((u_long)2)
extern  klm_stat * klm_lock_1(struct klm_lockargs *, CLIENT *);
extern  klm_stat * klm_lock_1_svc(struct klm_lockargs *, struct svc_req *);
#define KLM_CANCEL ((u_long)3)
extern  klm_stat * klm_cancel_1(struct klm_lockargs *, CLIENT *);
extern  klm_stat * klm_cancel_1_svc(struct klm_lockargs *, struct svc_req *);
#define KLM_UNLOCK ((u_long)4)
extern  klm_stat * klm_unlock_1(struct klm_unlockargs *, CLIENT *);
extern  klm_stat * klm_unlock_1_svc(struct klm_unlockargs *, struct svc_req *);

#else /* Old Style C */ 
#define KLM_TEST ((u_long)1)
extern  klm_testrply * klm_test_1();
extern  klm_testrply * klm_test_1_svc();
#define KLM_LOCK ((u_long)2)
extern  klm_stat * klm_lock_1();
extern  klm_stat * klm_lock_1_svc();
#define KLM_CANCEL ((u_long)3)
extern  klm_stat * klm_cancel_1();
extern  klm_stat * klm_cancel_1_svc();
#define KLM_UNLOCK ((u_long)4)
extern  klm_stat * klm_unlock_1();
extern  klm_stat * klm_unlock_1_svc();
#endif /* Old Style C */ 

#endif /* !_KLM_PROT_H_RPCGEN */
