Open Ethernet Networking (OpEN) API Guide and Reference Manual
3.9.0.2
Welcome
ADK Documentation
API Reference
Files
File List
Globals
api
include
openapi_storm_control.h
Go to the documentation of this file.
1
9
/*********************************************************************
10
*
11
* Copyright 2016-2018 Broadcom.
12
*
13
* Licensed under the Apache License, Version 2.0 (the "License");
14
* you may not use this file except in compliance with the License.
15
* You may obtain a copy of the License at
16
*
17
* http://www.apache.org/licenses/LICENSE-2.0
18
*
19
* Unless required by applicable law or agreed to in writing, software
20
* distributed under the License is distributed on an "AS IS" BASIS,
21
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
22
* See the License for the specific language governing permissions and
23
* limitations under the License.
24
*
25
**********************************************************************
26
*
27
* @filename openapi_storm_control.h
28
*
29
* @purpose Storm Control Configuration and Status
30
*
31
* @component OPEN
32
*
33
* @create 30/01/2013
34
*
35
* @end
36
*
37
**********************************************************************/
38
#ifndef OPENAPI_STORM_CONTROL_H_INCLUDED
39
#define OPENAPI_STORM_CONTROL_H_INCLUDED
40
41
#include "
openapi_common.h
"
42
44
typedef
enum
45
{
46
OPEN_STORM_CTRL_MODE_NONE
= 0,
47
OPEN_STORM_CTRL_MODE_UNICAST
= 1,
48
OPEN_STORM_CTRL_MODE_BROADCAST
= 2,
49
OPEN_STORM_CTRL_MODE_MULTICAST
= 3
50
}
OPEN_STORM_CTRL_MODE_t
;
51
53
typedef
enum
54
{
55
OPEN_POLICY_PORT_ACTION_NONE = 0,
56
OPEN_POLICY_PORT_ACTION_SHUTDOWN
= 1,
57
OPEN_POLICY_PORT_ACTION_RATELIMIT
= 2,
58
OPEN_POLICY_PORT_ACTION_TRAP
= 3
59
}
OPEN_POLICY_PORT_ACTION_t
;
60
61
/*****************************************************************/
81
open_error_t
openapiStormControlModeSet
(
openapiClientHandle_t
*client_handle,
82
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
83
OPEN_CONTROL_t
state);
84
85
/*****************************************************************/
100
open_error_t
openapiStormControlModeGet
(
openapiClientHandle_t
*client_handle,
101
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
102
OPEN_CONTROL_t
*state);
103
104
/*****************************************************************/
125
open_error_t
openapiStormControlThresholdSet
(
openapiClientHandle_t
*client_handle,
126
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
127
OPEN_RATE_UNIT_t
rateUnit,
128
uint32_t threshold);
129
130
/*****************************************************************/
148
open_error_t
openapiStormControlThresholdDefaultSet
(
openapiClientHandle_t
*client_handle,
149
OPEN_STORM_CTRL_MODE_t
stormCtrlMode);
150
151
/*****************************************************************/
167
open_error_t
openapiStormControlThresholdGet
(
openapiClientHandle_t
*client_handle,
168
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
169
OPEN_RATE_UNIT_t
*rateUnit,
170
uint32_t *threshold);
171
172
/*****************************************************************/
190
open_error_t
openapiStormControlIntfModeSet
(
openapiClientHandle_t
*client_handle,
191
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
192
uint32_t interface,
193
OPEN_CONTROL_t
state);
194
195
/*****************************************************************/
212
open_error_t
openapiStormControlIntfModeGet
(
openapiClientHandle_t
*client_handle,
213
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
214
uint32_t interface,
215
OPEN_CONTROL_t
*state);
216
217
/*****************************************************************/
243
open_error_t
openapiStormControlIntfThresholdSet
(
openapiClientHandle_t
*client_handle,
244
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
245
uint32_t interface,
246
OPEN_RATE_UNIT_t
rateUnit,
247
uint32_t threshold);
248
249
/*****************************************************************/
269
open_error_t
openapiStormControlIntfThresholdDefaultSet
(
openapiClientHandle_t
*client_handle,
270
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
271
uint32_t interface);
272
273
/*****************************************************************/
292
open_error_t
openapiStormControlIntfThresholdGet
(
openapiClientHandle_t
*client_handle,
293
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
294
uint32_t interface,
295
OPEN_RATE_UNIT_t
*rateUnit,
296
uint32_t *threshold);
297
298
/*****************************************************************/
315
open_error_t
openapiStormControlThresholdMinMaxGet
(
openapiClientHandle_t
*client_handle,
316
OPEN_RATE_UNIT_t
rateUnit,
317
uint32_t *minThreshold,
318
uint32_t *maxThreshold);
319
320
/*****************************************************************/
338
open_error_t
openapiStormControlActionSet
(
openapiClientHandle_t
*client_handle,
339
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
340
OPEN_POLICY_PORT_ACTION_t
action);
341
342
/*****************************************************************/
357
open_error_t
openapiStormControlActionGet
(
openapiClientHandle_t
*client_handle,
358
OPEN_STORM_CTRL_MODE_t
stormCtrlMode,
359
OPEN_POLICY_PORT_ACTION_t
*action);
360
361
#endif
362
© 2022 by Broadcom. All rights reserved.