RTEMS: cpukit/libfs/src/nfsclient/proto/mount_prot.h Source File

| RTEMS 5.4-rc2

Loading...
Searching...
No Matches
mount_prot.h
Go to the documentation of this file.
1
9#ifndef _MOUNT_PROT_H_RPCGEN
10#define _MOUNT_PROT_H_RPCGEN
11
12#include <rpc/rpc.h>
13
20#ifdef __cplusplus
21extern "C" {
22#endif
23
24#define MNTPATHLEN 1024
25#define MNTNAMLEN 255
26#define FHSIZE 32
27
28typedef char fhandle[FHSIZE];
29
30 struct fhstatus {
31 u_int fhs_status;
32 union {
33 fhandle fhs_fhandle;
34 } fhstatus_u;
35};
36typedef struct fhstatus fhstatus;
37
38typedef char *dirpath;
39
40typedef char *name;
41
42typedef struct mountbody *mountlist;
43
44 struct mountbody {
45 name ml_hostname;
46 dirpath ml_directory;
47 mountlist ml_next;
48};
49typedef struct mountbody mountbody;
50
51typedef struct groupnode *groups;
52
53 struct groupnode {
54 name gr_name;
55 groups gr_next;
56};
57typedef struct groupnode groupnode;
58
59typedef struct exportnode *exports;
60
61 struct exportnode {
62 dirpath ex_dir;
63 groups ex_groups;
64 exports ex_next;
65};
66typedef struct exportnode exportnode;
67
68#define MOUNTPROG 100005
69#define MOUNTVERS 1
70
71#if defined(__STDC__) || defined(__cplusplus)
72#define MOUNTPROC_NULL 0
73extern void * mountproc_null_1(void *, CLIENT *);
74extern void * mountproc_null_1_svc(void *, struct svc_req *);
75#define MOUNTPROC_MNT 1
76extern fhstatus * mountproc_mnt_1(dirpath *, CLIENT *);
77extern fhstatus * mountproc_mnt_1_svc(dirpath *, struct svc_req *);
78#define MOUNTPROC_DUMP 2
79extern mountlist * mountproc_dump_1(void *, CLIENT *);
80extern mountlist * mountproc_dump_1_svc(void *, struct svc_req *);
81#define MOUNTPROC_UMNT 3
82extern void * mountproc_umnt_1(dirpath *, CLIENT *);
83extern void * mountproc_umnt_1_svc(dirpath *, struct svc_req *);
84#define MOUNTPROC_UMNTALL 4
85extern void * mountproc_umntall_1(void *, CLIENT *);
86extern void * mountproc_umntall_1_svc(void *, struct svc_req *);
87#define MOUNTPROC_EXPORT 5
88extern exports * mountproc_export_1(void *, CLIENT *);
89extern exports * mountproc_export_1_svc(void *, struct svc_req *);
90#define MOUNTPROC_EXPORTALL 6
91extern exports * mountproc_exportall_1(void *, CLIENT *);
92extern exports * mountproc_exportall_1_svc(void *, struct svc_req *);
93extern int mountprog_1_freeresult (SVCXPRT *, xdrproc_t, caddr_t);
94
95#else /* K&R C */
96#define MOUNTPROC_NULL 0
97extern void * mountproc_null_1();
98extern void * mountproc_null_1_svc();
99#define MOUNTPROC_MNT 1
100extern fhstatus * mountproc_mnt_1();
101extern fhstatus * mountproc_mnt_1_svc();
102#define MOUNTPROC_DUMP 2
103extern mountlist * mountproc_dump_1();
104extern mountlist * mountproc_dump_1_svc();
105#define MOUNTPROC_UMNT 3
106extern void * mountproc_umnt_1();
107extern void * mountproc_umnt_1_svc();
108#define MOUNTPROC_UMNTALL 4
109extern void * mountproc_umntall_1();
110extern void * mountproc_umntall_1_svc();
111#define MOUNTPROC_EXPORT 5
112extern exports * mountproc_export_1();
113extern exports * mountproc_export_1_svc();
114#define MOUNTPROC_EXPORTALL 6
115extern exports * mountproc_exportall_1();
116extern exports * mountproc_exportall_1_svc();
117extern int mountprog_1_freeresult ();
118#endif /* K&R C */
119
120/* the xdr functions */
121
122#if defined(__STDC__) || defined(__cplusplus)
123extern bool_t xdr_fhandle (XDR *, fhandle);
124extern bool_t xdr_fhstatus (XDR *, fhstatus*);
125extern bool_t xdr_dirpath (XDR *, dirpath*);
126extern bool_t xdr_name (XDR *, name*);
127extern bool_t xdr_mountlist (XDR *, mountlist*);
128extern bool_t xdr_mountbody (XDR *, mountbody*);
129extern bool_t xdr_groups (XDR *, groups*);
130extern bool_t xdr_groupnode (XDR *, groupnode*);
131extern bool_t xdr_exports (XDR *, exports*);
132extern bool_t xdr_exportnode (XDR *, exportnode*);
133
134#else /* K&R C */
135extern bool_t xdr_fhandle ();
136extern bool_t xdr_fhstatus ();
137extern bool_t xdr_dirpath ();
138extern bool_t xdr_name ();
139extern bool_t xdr_mountlist ();
140extern bool_t xdr_mountbody ();
141extern bool_t xdr_groups ();
142extern bool_t xdr_groupnode ();
143extern bool_t xdr_exports ();
144extern bool_t xdr_exportnode ();
145
146#endif /* K&R C */
147
148#ifdef __cplusplus
149}
150#endif
152#endif /* !_MOUNT_PROT_H_RPCGEN */
exportnode
Definition: mount_prot.h:61
fhstatus
Definition: mount_prot.h:30
groupnode
Definition: mount_prot.h:53
mountbody
Definition: mount_prot.h:44