OpenNSL API Guide and Reference Manual
port.h
Go to the documentation of this file.
1 /*********************************************************************
2  *
3  * (C) Copyright Broadcom Corporation 2013-2017
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  ********************************************************************
18  * File: port.h
19  * Details: This file defines common network port parameters.
20  *
21  * Its contents are not used directly by applications;
22  * it is used only by header files of parent APIs
23  * which need to define port parameters.
24  * *******************************************************************/
25 
26 #ifndef _SHR_PORT_H
27 #define _SHR_PORT_H
28 
29 /*
30  * Typedef:
31  * _shr_port_t
32  * Purpose:
33  * Port number type for shared definitions
34  */
35 #include <sal/types.h>
36 
37 typedef int _shr_port_t;
38 
39 /*
40  * Defines:
41  * _SHR_PORT_DUPLEX_*
42  * Purpose:
43  * Defines duplexity of a port
44  */
45 
46 typedef enum _shr_port_duplex_e {
49  _SHR_PORT_DUPLEX_COUNT /* last, please */
51 /* __doxy_func_body_end__ */
52 
53 /*
54  * Defines:
55  * _SHR_PORT_IF_*
56  * Purpose:
57  * Defines interface type between MAC and PHY.
58  */
59 
60 typedef enum _shr_port_if_e {
61  _SHR_PORT_IF_NOCXN, /* No physical connection */
62  _SHR_PORT_IF_NULL, /* Pass-through connection without PHY */
127  _SHR_PORT_IF_COUNT /* last, please */
129 /* __doxy_func_body_end__ */
130 
131 /*
132  * Defines:
133  * _SHR_PORT_STP_*
134  * Purpose:
135  * Defines the spanning tree states of a port.
136  */
137 
138 typedef enum _shr_port_stp_e {
144  _SHR_PORT_STP_COUNT = 5 /* last, please */
146 /* __doxy_func_body_end__ */
147 
148 /*
149  * Defines:
150  * _SHR_PORT_MDIX_*
151  * Purpose:
152  * Defines the MDI crossover (MDIX) modes for the port
153  */
154 typedef enum _shr_port_mdix_e {
159  _SHR_PORT_MDIX_COUNT /* last, please */
161 /* __doxy_func_body_end__ */
162 
163 /*
164  * Defines:
165  * _SHR_PORT_MDIX_STATUS_*
166  * Purpose:
167  * Defines the MDI crossover state
168  */
172  _SHR_PORT_MDIX_STATUS_COUNT /* last, please */
174 /* __doxy_func_body_end__ */
175 
176 /*
177  * Defines:
178  * _SHR_PORT_MEDIUM_*
179  * Purpose:
180  * Supported physical mediums
181  */
182 typedef enum _shr_port_medium_e {
186  _SHR_PORT_MEDIUM_COUNT /* last, please */
188 /* __doxy_func_body_end__ */
189 
190 /*
191  * Defines:
192  * _SHR_PORT_MCAST_FLOOD_*
193  * Purpose:
194  * Multicast packet flooding mode
195  */
200  _SHR_PORT_MCAST_FLOOD_COUNT /* last, please */
202 /* __doxy_func_body_end__ */
203 
204 /*
205  * Defines:
206  * _SHR_PORT_PHY_CONTROL_*
207  * Purpose:
208  * PHY specific control settings
209  */
216 /* __doxy_func_body_end__ */
217 
218 /*
219  * Defines:
220  * _SHR_PORT_PRBS_POLYNOMIAL_*
221  * Purpose:
222  * PRBS polynomial type
223  */
233 /* __doxy_func_body_end__ */
234 
235 /*
236  * Defines:
237  * _SHR_PORT_PHY_CONTROL_FEC_*
238  * Purpose:
239  * PHY specific values for _SHR_PORT_PHY_CONTROL_FORWARD_ERROR_CORRECTION
240  */
246 /* __doxy_func_body_end__ */
247 
253 /* __doxy_func_body_end__ */
254 
255 #endif /* !_SHR_PORT_H */