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 /* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
23 /* All Rights Reserved */
24
25
26 /*
27 * Copyright 2014 Garrett D'Amore <garrett@damore.org>
28 *
29 * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
30 * Use is subject to license terms.
31 */
32
33 #ifndef _SYS_NETCONFIG_H
34 #define _SYS_NETCONFIG_H
35
36 #ifdef __cplusplus
37 extern "C" {
38 #endif
39
40 #define NETCONFIG "/etc/netconfig"
41 #define NETPATH "NETPATH"
42
43 struct netconfig {
44 char *nc_netid; /* network identifier */
45 unsigned int nc_semantics; /* defined below */
46 unsigned int nc_flag; /* defined below */
47 char *nc_protofmly; /* protocol family name */
48 char *nc_proto; /* protocol name */
49 char *nc_device; /* device name for network id */
50 unsigned int nc_nlookups; /* # of entries in nc_lookups */
130 #define NC_UDP "udp"
131 #define NC_ICMP "icmp"
132
133 /*
134 * Values for nc_proto for "rdma" protofmly
135 */
136 #define NC_KVIPL "kvipl"
137 #define NC_IBTF "ibtf"
138 #define NC_KDAPL "kdapl"
139
140 extern void *setnetconfig(void);
141 extern int endnetconfig(void *);
142 extern struct netconfig *getnetconfig(void *);
143 extern struct netconfig *getnetconfigent(const char *);
144 extern void freenetconfigent(struct netconfig *);
145 extern void *setnetpath(void);
146 extern int endnetpath(void *);
147 extern struct netconfig *getnetpath(void *);
148 extern void nc_perror(const char *);
149 extern char *nc_sperror(void);
150
151 #ifdef __cplusplus
152 }
153 #endif
154
155 #endif /* _SYS_NETCONFIG_H */
|
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 /* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
23 /* All Rights Reserved */
24
25
26 /*
27 * Copyright 2014 Garrett D'Amore <garrett@damore.org>
28 *
29 * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
30 * Use is subject to license terms.
31 * Copyright 2015 Joyent, Inc.
32 */
33
34 #ifndef _SYS_NETCONFIG_H
35 #define _SYS_NETCONFIG_H
36
37 #ifdef __cplusplus
38 extern "C" {
39 #endif
40
41 #define NETCONFIG "/etc/netconfig"
42 #define NETPATH "NETPATH"
43
44 struct netconfig {
45 char *nc_netid; /* network identifier */
46 unsigned int nc_semantics; /* defined below */
47 unsigned int nc_flag; /* defined below */
48 char *nc_protofmly; /* protocol family name */
49 char *nc_proto; /* protocol name */
50 char *nc_device; /* device name for network id */
51 unsigned int nc_nlookups; /* # of entries in nc_lookups */
131 #define NC_UDP "udp"
132 #define NC_ICMP "icmp"
133
134 /*
135 * Values for nc_proto for "rdma" protofmly
136 */
137 #define NC_KVIPL "kvipl"
138 #define NC_IBTF "ibtf"
139 #define NC_KDAPL "kdapl"
140
141 extern void *setnetconfig(void);
142 extern int endnetconfig(void *);
143 extern struct netconfig *getnetconfig(void *);
144 extern struct netconfig *getnetconfigent(const char *);
145 extern void freenetconfigent(struct netconfig *);
146 extern void *setnetpath(void);
147 extern int endnetpath(void *);
148 extern struct netconfig *getnetpath(void *);
149 extern void nc_perror(const char *);
150 extern char *nc_sperror(void);
151 extern void _nsl_brand_set_hooks(int (*)(void),
152 struct netconfig *(*)(int));
153
154 #ifdef __cplusplus
155 }
156 #endif
157
158 #endif /* _SYS_NETCONFIG_H */
|