4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
22 * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
23 * Use is subject to license terms.
29 #include <sys/types.h>
36 typedef struct dladm_ether_spdx_s
{
38 link_duplex_t lesd_duplex
;
41 typedef struct dladm_ether_attr_s
{
44 boolean_t le_asmpause
;
47 dladm_ether_spdx_t
*le_spdx
;
51 * Supported PTYPE values
58 /* Names of the lei_attr[] PTYPE slots for use in arrays */
59 #define LEI_ATTR_NAMES "current", "capable", "adv", "peeradv"
61 typedef struct dladm_ether_info
{
62 datalink_id_t lei_linkid
;
63 char lei_linkname
[MAXLINKNAMELEN
];
64 link_state_t lei_state
;
65 dladm_ether_attr_t lei_attr
[PEERADV
+1];
68 extern dladm_status_t
dladm_ether_info(dladm_handle_t
, datalink_id_t
,
69 dladm_ether_info_t
*);
70 extern char *dladm_ether_autoneg2str(char *, size_t,
71 dladm_ether_info_t
*, int);
72 extern char *dladm_ether_pause2str(char *, size_t,
73 dladm_ether_info_t
*, int);
74 extern char *dladm_ether_spdx2str(char *, size_t,
75 dladm_ether_info_t
*, int);
76 extern void dladm_ether_info_done(dladm_ether_info_t
*);
82 #endif /* _LIBDLETHER_H */