xref: /titanic_51/usr/src/lib/libdladm/common/libdlvlan.h (revision d62bc4badc1c1f1549c961cfb8b420e650e1272b)
1*d62bc4baSyz147064 /*
2*d62bc4baSyz147064  * CDDL HEADER START
3*d62bc4baSyz147064  *
4*d62bc4baSyz147064  * The contents of this file are subject to the terms of the
5*d62bc4baSyz147064  * Common Development and Distribution License (the "License").
6*d62bc4baSyz147064  * You may not use this file except in compliance with the License.
7*d62bc4baSyz147064  *
8*d62bc4baSyz147064  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9*d62bc4baSyz147064  * or http://www.opensolaris.org/os/licensing.
10*d62bc4baSyz147064  * See the License for the specific language governing permissions
11*d62bc4baSyz147064  * and limitations under the License.
12*d62bc4baSyz147064  *
13*d62bc4baSyz147064  * When distributing Covered Code, include this CDDL HEADER in each
14*d62bc4baSyz147064  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15*d62bc4baSyz147064  * If applicable, add the following below this CDDL HEADER, with the
16*d62bc4baSyz147064  * fields enclosed by brackets "[]" replaced with your own identifying
17*d62bc4baSyz147064  * information: Portions Copyright [yyyy] [name of copyright owner]
18*d62bc4baSyz147064  *
19*d62bc4baSyz147064  * CDDL HEADER END
20*d62bc4baSyz147064  */
21*d62bc4baSyz147064 /*
22*d62bc4baSyz147064  * Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
23*d62bc4baSyz147064  * Use is subject to license terms.
24*d62bc4baSyz147064  */
25*d62bc4baSyz147064 
26*d62bc4baSyz147064 #ifndef _LIBDLVLAN_H
27*d62bc4baSyz147064 #define	_LIBDLVLAN_H
28*d62bc4baSyz147064 
29*d62bc4baSyz147064 #pragma ident	"%Z%%M%	%I%	%E% SMI"
30*d62bc4baSyz147064 
31*d62bc4baSyz147064 /*
32*d62bc4baSyz147064  * This file includes structures, macros and routines used by VLAN link
33*d62bc4baSyz147064  * administration.
34*d62bc4baSyz147064  */
35*d62bc4baSyz147064 
36*d62bc4baSyz147064 #include <libdladm.h>
37*d62bc4baSyz147064 
38*d62bc4baSyz147064 #ifdef	__cplusplus
39*d62bc4baSyz147064 extern "C" {
40*d62bc4baSyz147064 #endif
41*d62bc4baSyz147064 
42*d62bc4baSyz147064 typedef struct dladm_vlan_attr {
43*d62bc4baSyz147064 	uint16_t	dv_vid;
44*d62bc4baSyz147064 	datalink_id_t	dv_linkid;
45*d62bc4baSyz147064 	boolean_t	dv_force;
46*d62bc4baSyz147064 	boolean_t	dv_implicit;
47*d62bc4baSyz147064 } dladm_vlan_attr_t;
48*d62bc4baSyz147064 
49*d62bc4baSyz147064 extern dladm_status_t	dladm_vlan_info(datalink_id_t, dladm_vlan_attr_t *,
50*d62bc4baSyz147064 			    uint32_t);
51*d62bc4baSyz147064 extern dladm_status_t	dladm_vlan_create(const char *, datalink_id_t,
52*d62bc4baSyz147064 			    uint16_t, uint32_t);
53*d62bc4baSyz147064 extern dladm_status_t	dladm_vlan_delete(datalink_id_t, uint32_t);
54*d62bc4baSyz147064 extern dladm_status_t	dladm_vlan_up(datalink_id_t);
55*d62bc4baSyz147064 
56*d62bc4baSyz147064 #ifdef	__cplusplus
57*d62bc4baSyz147064 }
58*d62bc4baSyz147064 #endif
59*d62bc4baSyz147064 
60*d62bc4baSyz147064 #endif	/* _LIBDLVLAN_H */
61