1 /*
2  * CDDL HEADER START
3  *
4  * The contents of this file are subject to the terms of the
5  * Common Development and Distribution License, Version 1.0 only
6  * (the "License").  You may not use this file except in compliance
7  * with the License.
8  *
9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10  * or http://www.opensolaris.org/os/licensing.
11  * See the License for the specific language governing permissions
12  * and limitations under the License.
13  *
14  * When distributing Covered Code, include this CDDL HEADER in each
15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16  * If applicable, add the following below this CDDL HEADER, with the
17  * fields enclosed by brackets "[]" replaced with your own identifying
18  * information: Portions Copyright [yyyy] [name of copyright owner]
19  *
20  * CDDL HEADER END
21  */
22 /*
23  * Copyright 2003 Sun Microsystems, Inc.  All rights reserved.
24  * Use is subject to license terms.
25  */
26 
27 #ifndef _SOLARIS_NFSMOUNT_H
28 #define	_SOLARIS_NFSMOUNT_H
29 
30 #pragma ident	"%Z%%M%	%I%	%E% SMI"
31 
32 #ifdef __cplusplus
33 extern "C" {
34 #endif
35 
36 #include <cimapi.h>
37 #include <cp_required.h>
38 #include <cp_instance.h>
39 #include <cp_associator.h>
40 #include <cp_method.h>
41 #include <cp_property.h>
42 #include <cimomhandle.h>
43 #include <cimeventsvc.h>
44 #include <cimlogsvc.h>
45 #include "nfsprov_include.h"
46 #include "nfs_mount_attr.h"
47 
48 #define	PROPCOUNT 39
49 
50 static nfs_prov_prop_plus_optVals_t nfsMountProps[] = {
51 #define	ANT 0
52 	{"Antecedent", cim_true, reference, NULL, NULL, NULL},
53 
54 #define	ATTRCACHE (ANT + 1)
55 	{"AttributeCaching", cim_false, boolean, NULL, NFS_ATTRCACHE_FALSE,
56 	NULL},
57 
58 #define	ATTRCACHEDIRMAX (ATTRCACHE + 1)
59 	{"AttributeCachingForDirectoriesMax", cim_false, uint16, NULL, NULL,
60 	NFS_ATTRCACHEDIRMAX},
61 
62 #define	ATTRCACHEDIRMIN (ATTRCACHEDIRMAX + 1)
63 	{"AttributeCachingForDirectoriesMin", cim_false, uint16, NULL, NULL,
64 	NFS_ATTRCACHEDIRMIN},
65 
66 #define	ATTRCACHEFILESMAX (ATTRCACHEDIRMIN + 1)
67 	{"AttributeCachingForRegularFilesMax", cim_false, uint16, NULL, NULL,
68 	NFS_ATTRCACHEFILESMAX},
69 
70 #define	ATTRCACHEFILESMIN (ATTRCACHEFILESMAX + 1)
71 	{"AttributeCachingForRegularFilesMin", cim_false, uint16, NULL, NULL,
72 	NFS_ATTRCACHEFILESMIN},
73 
74 #define	DEP (ATTRCACHEFILESMIN + 1)
75 	{"Dependent", cim_true, reference, NULL, NULL, NULL},
76 
77 #define	ENABLEQUOTA (DEP + 1)
78 	{"EnableQuotaChecking", cim_false, boolean, NFS_ENABLEQUOTA_TRUE,
79 	NFS_ENABLEQUOTA_FALSE, NULL},
80 
81 #define	FAILOVER (ENABLEQUOTA + 1)
82 	{"FailoverList", cim_false, string_array, NULL, NULL, NULL},
83 
84 #define	FORCEDIRECTIO (FAILOVER + 1)
85 	{"ForceDirectIO", cim_false, boolean, NFS_FORCEDIRECTIO_TRUE,
86 	NFS_FORCEDIRECTIO_FALSE, NULL},
87 
88 #define	FSTYPE (FORCEDIRECTIO + 1)
89 	{"FsType", cim_false, string, NULL, NULL, NULL},
90 
91 #define	GRPID (FSTYPE + 1)
92 	{"GroupId", cim_false, boolean, NFS_GRPID_TRUE, NULL, NULL},
93 
94 #define	HARDMNT (GRPID + 1)
95 	{"HardMount", cim_false, boolean, NFS_HARDMNT_TRUE, NFS_HARDMNT_FALSE,
96 	NULL},
97 
98 #define	INTR (HARDMNT + 1)
99 	{"Interrupt", cim_false, boolean, NFS_INTR_TRUE, NFS_INTR_FALSE, NULL},
100 
101 #define	MAXRETRANSATTEMPTS (INTR + 1)
102 	{"MaxRetransmissionAttempts", cim_false, uint16, NULL, NULL,
103 	NFS_MAXRETRANSATTEMPTS},
104 
105 #define	MNTATBOOTENTRY (MAXRETRANSATTEMPTS + 1)
106 	{"MountAtBootEntry", cim_false, boolean, NULL, NULL, NULL},
107 
108 #define	MNTOPTS (MNTATBOOTENTRY + 1)
109 	{"MountOptions", cim_false, string, NULL, NULL, NULL},
110 
111 #define	MNTFAILRETRIES (MNTOPTS + 1)
112 	{"MountFailureRetries", cim_false, uint16, NULL, NULL,
113 	NFS_MNTFAILRETRIES},
114 
115 #define	NOCTO (MNTFAILRETRIES + 1)
116 	{"NoCloseToOpenConsistency", cim_false, boolean, NFS_NOCTO_TRUE, NULL,
117 	NULL},
118 
119 #define	NOMNTTABENT (NOCTO + 1)
120 	{"NoMnttabEntry", cim_false, boolean, NULL, NULL, NULL},
121 
122 #define	NOSUID (NOMNTTABENT + 1)
123 	{"NoSuid", cim_false, boolean, NFS_NOSUID_TRUE, NFS_NOSUID_FALSE,
124 	NULL},
125 
126 #define	OVERLAY (NOSUID + 1)
127 	{"Overlay", cim_false, boolean, NULL, NULL, NULL},
128 
129 #define	OVERLAYED (OVERLAY + 1)
130 	{"Overlayed", cim_false, boolean, NULL, NULL, NULL},
131 
132 #define	POSIX (OVERLAYED + 1)
133 	{"Posix", cim_false, boolean, NFS_POSIX_TRUE, NULL, NULL},
134 
135 #define	PROTO (POSIX + 1)
136 	{"Protocol", cim_false, string, NULL, NULL, NFS_PROTO},
137 
138 #define	PUBLIC (PROTO + 1)
139 	{"Public", cim_false, boolean, NFS_PUBLIC_TRUE, NULL, NULL},
140 
141 #define	READBUFFSIZE (PUBLIC + 1)
142 	{"ReadBufferSize", cim_false, uint64, NULL, NULL, NFS_READBUFFSIZE},
143 
144 #define	READONLY (READBUFFSIZE + 1)
145 	{"ReadOnly", cim_false, boolean, NFS_READONLY_TRUE, NFS_READONLY_FALSE,
146 	NULL},
147 
148 #define	REPLRESOURCES (READONLY + 1)
149 	{"ReplicatedResources", cim_false, string_array, NULL, NULL, NULL},
150 
151 #define	RETRANSTIMEO (REPLRESOURCES + 1)
152 	{"RetransmissionTimeout", cim_false, uint32, NULL, NULL,
153 	NFS_RETRANSTIMEO},
154 
155 #define	FOREGROUND (RETRANSTIMEO + 1)
156 	{"RetryInForeground", cim_false, boolean, NFS_FOREGROUND_TRUE,
157 	NFS_FOREGROUND_FALSE, NULL},
158 
159 #define	SECMODE (FOREGROUND + 1)
160 	{"SecurityMode", cim_false, string, NULL, NULL, NFS_SECMODE},
161 
162 #define	SERVERCOMMPORT (SECMODE + 1)
163 	{"ServerCommunicationPort", cim_false, uint32, NULL, NULL,
164 	NFS_SERVERCOMMPORT},
165 
166 #define	SERVERNAME (SERVERCOMMPORT + 1)
167 	{"ServerName", cim_false, string, NULL, NULL, NULL},
168 
169 #define	SERVERPATH (SERVERNAME + 1)
170 	{"ServerPath", cim_false, string, NULL, NULL, NULL},
171 
172 #define	VERS (SERVERPATH + 1)
173 	{"Version", cim_false, string, NULL, NULL, NFS_VERS},
174 
175 #define	VFSTABENTRY (VERS + 1)
176 	{"VfstabEntry", cim_false, boolean, NULL, NULL, NULL},
177 
178 #define	WRITEBUFFSIZE (VFSTABENTRY + 1)
179 	{"WriteBufferSize", cim_false, uint64, NULL, NULL, NFS_WRITEBUFFSIZE},
180 
181 #define	XATTR (WRITEBUFFSIZE + 1)
182 	{"Xattr", cim_false, boolean, NFS_XATTR_TRUE, NFS_XATTR_FALSE, NULL}
183 };
184 
185 #ifdef __cplusplus
186 }
187 #endif
188 
189 #endif /* _SOLARIS_NFSMOUNT_H */
190