Open Ethernet Networking (OpEN) API Guide and Reference Manual  3.11.1.2
openapi_pml.h
Go to the documentation of this file.
1 
9 /*********************************************************************
10 *
11 * Copyright 2018-2023 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 * Licensed under the Apache License, Version 2.0 (the "License");
26 * you may not use this file except in compliance with the License.
27 * You may obtain a copy of the License at
28 *
29 * http://www.apache.org/licenses/LICENSE-2.0
30 *
31 * Unless required by applicable law or agreed to in writing, software
32 * distributed under the License is distributed on an "AS IS" BASIS,
33 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
34 * See the License for the specific language governing permissions and
35 * limitations under the License.
36 *
37 **********************************************************************
38 *
39 * @filename openapi_pml.h
40 *
41 * @purpose Port MAC Locking (PML) Configuration and Status
42 *
43 * @component OPEN
44 *
45 * @create 09/10/2018
46 *
47 * @end
48 *
49 **********************************************************************/
50 #ifndef OPENAPI_PML_H_INCLUDED
51 #define OPENAPI_PML_H_INCLUDED
52 
53 #include "openapi_common.h"
54 
55 /*****************************************************************/
70 
71 /*****************************************************************/
87 open_error_t openapiPmlIntfIsValid(openapiClientHandle_t *clientHandle, uint32_t ifNum, OPEN_BOOL_t *isValid);
88 
89 /*****************************************************************/
105 open_error_t openapiPmlIntfModeGet(openapiClientHandle_t *clientHandle, uint32_t ifNum, OPEN_CONTROL_t *mode);
106 
107 /*****************************************************************/
123 open_error_t openapiPmlIntfDynamicLimitGet(openapiClientHandle_t *clientHandle, uint32_t ifNum, uint32_t *limit);
124 
125 /*****************************************************************/
141 open_error_t openapiPmlIntfStaticLimitGet(openapiClientHandle_t *clientHandle, uint32_t ifNum, uint32_t *limit);
142 
143 /*****************************************************************/
160 
161 /*****************************************************************/
178 
179 /*****************************************************************/
195 open_error_t openapiPmlIntfStickyModeGet(openapiClientHandle_t *clientHandle, uint32_t ifNum, OPEN_CONTROL_t *stickyMode);
196 
197 /*****************************************************************/
217  uint32_t ifNum,
218  open_buffdesc *macAddr,
219  uint32_t *vlanId,
220  OPEN_BOOL_t *isSticky);
221 
222 /*****************************************************************/
244  uint32_t ifNum,
245  open_buffdesc *macAddr,
246  uint32_t vlanId,
247  open_buffdesc *nextMacAddr,
248  uint32_t *nextVlanId,
249  OPEN_BOOL_t *isnextEntrySticky);
250 
251 /*****************************************************************/
269  uint32_t ifNum,
270  open_buffdesc *macAddr,
271  uint32_t *vlanId);
272 
273 /*****************************************************************/
293  uint32_t ifNum,
294  open_buffdesc *macAddr,
295  uint32_t vlanId,
296  open_buffdesc *nextMacAddr,
297  uint32_t *nextVlanId);
298 
299 /*************************************************************************/
316  OPEN_CONTROL_t adminMode);
317 
318 /*************************************************************************/
335 open_error_t openapiPmlIntfModeSet(openapiClientHandle_t *client_handle, uint32_t ifNum,
336  OPEN_CONTROL_t intfMode);
337 
338 /*************************************************************************/
355  uint32_t ifNum, uint32_t *limit);
356 
357 /*************************************************************************/
375  uint32_t ifNum, uint32_t limit);
376 
377 /*************************************************************************/
394  uint32_t ifNum, uint32_t *limit);
395 
396 /*************************************************************************/
413  uint32_t ifNum, uint32_t *limit);
414 
415 /*************************************************************************/
433  uint32_t ifNum, uint32_t limit);
434 
435 /*************************************************************************/
452  uint32_t ifNum, uint32_t *interval);
453 
454 /*************************************************************************/
472  uint32_t ifNum, uint32_t interval);
473 
474 /*************************************************************************/
494  uint32_t ifNum, open_buffdesc *macAddr,
495  uint32_t vlanId, OPEN_BOOL_t sticky);
496 
497 /*************************************************************************/
516  uint32_t ifNum, open_buffdesc *macAddr,
517  uint32_t vlanId);
518 
519 /*************************************************************************/
537  uint32_t ifNum);
538 
539 /*************************************************************************/
557  uint32_t ifNum, OPEN_CONTROL_t sticky);
558 
559 /*************************************************************************/
577  uint32_t ifNum, open_buffdesc *macAddr,
578  uint32_t *vlanId);
579 
580 /*************************************************************************/
597  uint32_t ifNum, uint32_t *count);
598 
599 /*************************************************************************/
616  uint32_t ifNum, uint32_t *count);
617 
618 /*************************************************************************/
635  uint32_t vlanId, uint32_t *count);
636 
637 /*************************************************************************/
653  uint32_t *count);
654 
655 /*************************************************************************/
673  uint32_t ifNum, OPEN_CONTROL_t mode);
674 
675 /*************************************************************************/
691  OPEN_CONTROL_t *adminMode);
692 
693 /*************************************************************************/
710  OPEN_CONTROL_t adminMode);
711 
712 /*************************************************************************/
729  uint32_t vlanId, uint32_t *limit);
730 
731 /*************************************************************************/
749  uint32_t vlanId, uint32_t limit);
750 
751 /*************************************************************************/
768  uint32_t vlanId, uint32_t *limit);
769 
770 /*************************************************************************/
787  uint32_t vlanId, OPEN_BOOL_t *mode);
788 
789 /*************************************************************************/
807  uint32_t vlanId, OPEN_BOOL_t mode);
808 
809 /*************************************************************************/
826  uint32_t vlanId, OPEN_BOOL_t *mode);
827 
828 /*************************************************************************/
846  uint32_t vlanId, OPEN_BOOL_t mode);
847 
848 /*************************************************************************/
865  uint32_t vlanId, uint32_t *mode);
866 
867 /*************************************************************************/
885  uint32_t vlanId, uint32_t mode);
886 
887 /*************************************************************************/
905  uint32_t ifNum, uint32_t vlanId,
906  uint32_t *limit);
907 
908 /*************************************************************************/
927  uint32_t ifNum, uint32_t vlanId,
928  uint32_t limit);
929 
930 /*************************************************************************/
950  uint32_t ifNum, uint32_t vlanId,
951  uint32_t *count);
952 
953 /*************************************************************************/
970  uint32_t ifNum, uint32_t *ageTime);
971 
972 /*************************************************************************/
990  uint32_t ifNum, uint32_t ageTime);
991 
992 /*************************************************************************/
1009  uint32_t ifNum, uint32_t *nextIfNum);
1010 
1011 /*************************************************************************/
1029  uint32_t ifNum, open_buffdesc *macAddr,
1030  uint32_t *vlanId);
1031 
1032 /*************************************************************************/
1051  uint32_t ifNum, open_buffdesc *macAddr,
1052  open_buffdesc *nextMacAddr,
1053  uint32_t *vlanId);
1054 
1055 /*************************************************************************/
1075  uint32_t ifNum, open_buffdesc *macAddr,
1076  uint32_t vlanId, uint32_t streamID);
1077 
1078 /*************************************************************************/
1098  uint32_t ifNum, open_buffdesc *macAddr,
1099  uint32_t vlanId, uint32_t streamID);
1100 
1101 /*************************************************************************/
1120  uint32_t ifNum,
1121  open_buffdesc *macAddr, uint32_t vlanId,
1122  uint32_t *streamID);
1123 
1124 
1125 #endif /* OPENAPI_PML_H_INCLUDED */
1126 
open_error_t openapiPmlIntfIsValid(openapiClientHandle_t *clientHandle, uint32_t ifNum, OPEN_BOOL_t *isValid)
Get whether an interface is a valid PML interface or not.
open_error_t openapiPmlIntfVlanDynamicLimitGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t vlanId, uint32_t *limit)
Gets the Port MAC Locking vlan dynamic limit for the specified interface.
open_error_t openapiPmlGlobalAdminModeSet(openapiClientHandle_t *client_handle, OPEN_CONTROL_t adminMode)
Sets the PML global admin mode.
open_error_t openapiPmlIntfDynamicToStaticMove(openapiClientHandle_t *client_handle, uint32_t ifNum)
Converts dynamically locked entries to statically locked entries on this interface.
open_error_t openapiPmlVlanOperationalLimitGet(openapiClientHandle_t *client_handle, uint32_t vlanId, uint32_t *limit)
Gets operational vlan MAC locking limit.
open_error_t openapiPmlIntfVlanDynamicLimitSet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t vlanId, uint32_t limit)
Sets the Port MAC Locking vlan dynamic limit for the specified interface.
open_error_t openapiPmlIntfDynamicMaxLimitGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *limit)
Gets the Port MAC Locking maximum dynamic limit for the specified interface.
open_error_t openapiPmlIntfStaticEntryGetFirst(openapiClientHandle_t *clientHandle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t *vlanId, OPEN_BOOL_t *isSticky)
Gets the first static entry for an interface.
open_error_t
OPEN uses these enumerators to indicate the error codes.
open_error_t openapiPmlIntfDynamicLearnedAddrCountGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *count)
Gets the count of dynamcially learned mac Addresses.
open_error_t openapiPmlDot1qciStreamDelete(openapiClientHandle_t *client_handle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t vlanId, uint32_t streamID)
Deassociate the 802.1Qci stream with static PML entry.
open_error_t openapiPmlIntfTrapFrequencyGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *interval)
Gets the frequency interval between successive SNMP traps.
open_error_t openapiPmlIntfDynamicLimitSet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t limit)
Sets the Port MAC Locking dynamic limit for the specified interface.
open_error_t openapiPmlIntfStaticLimitGet(openapiClientHandle_t *clientHandle, uint32_t ifNum, uint32_t *limit)
Get the Port MAC Locking static limit for the specified interface.
open_error_t openapiPmlIntfStaticLimitSet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t limit)
Sets the Port MAC Locking static limit for the specified interface.
open_error_t openapiPmlIntfStaticMaxLimitGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *limit)
Gets the Port MAC Locking maximum static limit for the specified interface.
open_error_t openapiPmlDot1qciStreamGet(openapiClientHandle_t *client_handle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t vlanId, uint32_t *streamID)
Get the 802.1Qci stream ID associated with static PML entry.
open_error_t openapiPmlIntfStickyModeSet(openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t sticky)
Configures PML sticky mode on this interface.
open_error_t openapiPmlVlanViolationTrapModeSet(openapiClientHandle_t *client_handle, uint32_t vlanId, OPEN_BOOL_t mode)
Sets the MAC Locking violation trap mode for the specified vlan.
open_error_t openapiPmlIntfViolationTrapModeGet(openapiClientHandle_t *clientHandle, uint32_t ifNum, OPEN_CONTROL_t *trapMode)
Get the Port MAC Locking violation trap mode for the specified interface.
open_error_t openapiPmlVlanDynamicLimitSet(openapiClientHandle_t *client_handle, uint32_t vlanId, uint32_t limit)
Sets the vlan MAC Locking limit.
open_error_t openapiPmlIntfViolationDDisableModeSet(openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t mode)
Sets the port MAC locking violation D-Disable mode for the specified interface.
open_error_t openapiPmlIntfViolationDDisableModeGet(openapiClientHandle_t *clientHandle, uint32_t ifNum, OPEN_CONTROL_t *mode)
Get the Port MAC Locking violation D-Disable mode for the specified interface.
open_error_t openapiPmlIntfStaticEntryGetNext(openapiClientHandle_t *clientHandle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t vlanId, open_buffdesc *nextMacAddr, uint32_t *nextVlanId, OPEN_BOOL_t *isnextEntrySticky)
Gets the next static entry for an interface.
open_error_t openapiPmlVlanDynamicEntryGetNext(openapiClientHandle_t *client_handle, uint32_t ifNum, open_buffdesc *macAddr, open_buffdesc *nextMacAddr, uint32_t *vlanId)
Gets the next dynamic entry for a vlan on a given interface.
open_error_t openapiPmlIntfStaticEntryAdd(openapiClientHandle_t *client_handle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t vlanId, OPEN_BOOL_t sticky)
Adds a statically locked entry to an interface.
OPEN_CONTROL_t
OPEN uses these enumerators to indicate enable or disable for a given config or status parameter...
open_error_t openapiPmlIntfDynamicEntryGetNext(openapiClientHandle_t *clientHandle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t vlanId, open_buffdesc *nextMacAddr, uint32_t *nextVlanId)
Gets the next dynamic entry for an interface.
open_error_t openapiPmlIntfAgeTimeSet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t ageTime)
Sets secure MAC address aging time for the specified interface.
OPEN_BOOL_t
OPEN uses these enumerators to indicate true or false for a given config or status parameter...
open_error_t openapiPmlIntfStaticLearnedAddrCountGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *count)
Gets the count of statically learned mac Addresses.
open_error_t openapiPmlStaticAddrCountByVlanGet(openapiClientHandle_t *client_handle, uint32_t vlanId, uint32_t *count)
Gets the count of statically learned mac Addresses.
open_error_t openapiPmlIntfStaticEntryDelete(openapiClientHandle_t *client_handle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t vlanId)
Deletes a statically locked entry from an interface.
open_error_t openapiPmlVlanAdminModeGet(openapiClientHandle_t *client_handle, OPEN_CONTROL_t *adminMode)
Gets the PML vlan admin mode.
open_error_t openapiPmlNextValidIntfGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *nextIfNum)
Gets the next valid PML interface.
open_error_t openapiPmlIntfModeGet(openapiClientHandle_t *clientHandle, uint32_t ifNum, OPEN_CONTROL_t *mode)
Get the Port MAC Locking mode for the specified interface.
open_error_t openapiPmlDot1qciStreamSet(openapiClientHandle_t *client_handle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t vlanId, uint32_t streamID)
Associate the 802.1Qci stream with static PML entry.
open_error_t openapiPmlIntfAgeTimeGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *ageTime)
Gets secure MAC address aging time for the specified interface.
open_error_t openapiPmlVlanDynamicEntryGetFirst(openapiClientHandle_t *client_handle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t *vlanId)
Gets the first dynamic entry for a vlan on a given interface.
open_error_t openapiPmlIntfStaticCountGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *limit)
Gets the Port MAC Locking static count for the specified interface.
open_error_t openapiPmlGlobalAdminModeGet(openapiClientHandle_t *clientHandle, OPEN_CONTROL_t *adminMode)
Get the Port MAC Locking Global Admin mode.
open_error_t openapiPmlIntfStickyModeGet(openapiClientHandle_t *clientHandle, uint32_t ifNum, OPEN_CONTROL_t *stickyMode)
Get the Port MAC Locking sticky mode for the specified interface.
open_error_t openapiPmlIntfLastViolationAddrGet(openapiClientHandle_t *client_handle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t *vlanId)
Gets the last violation entry for an interface.
open_error_t openapiPmlIntfModeSet(openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t intfMode)
Set the Port MAC Locking mode for the specified interface.
open_error_t openapiPmlVlanDynamicLimitGet(openapiClientHandle_t *client_handle, uint32_t vlanId, uint32_t *limit)
Gets the MAC limit per Vlan.
open_error_t openapiPmlIntfDynamicEntryGetFirst(openapiClientHandle_t *clientHandle, uint32_t ifNum, open_buffdesc *macAddr, uint32_t *vlanId)
Gets the first dynamic entry for an interface.
open_error_t openapiPmlStaticAddrGlobalCountGet(openapiClientHandle_t *client_handle, uint32_t *count)
Gets the global count of statically learned mac Addresses.
open_error_t openapiPmlIntfTrapFrequencySet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t interval)
Sets the frequency interval between successive SNMP traps.
open_error_t openapiPmlVlanModeGet(openapiClientHandle_t *client_handle, uint32_t vlanId, uint32_t *mode)
Gets the MAC Locking mode for the specified vlan.
open_error_t openapiPmlVlanModeSet(openapiClientHandle_t *client_handle, uint32_t vlanId, uint32_t mode)
Sets the MAC Locking mode for the specified vlan.
open_error_t openapiPmlVlanViolationDDisableModeSet(openapiClientHandle_t *client_handle, uint32_t vlanId, OPEN_BOOL_t mode)
Sets the MAC Locking violation D-Disable mode for the specified vlan.
open_error_t openapiPmlVlanAdminModeSet(openapiClientHandle_t *client_handle, OPEN_CONTROL_t adminMode)
Sets the PML vlan admin mode.
open_error_t openapiPmlIntfDynamicLimitGet(openapiClientHandle_t *clientHandle, uint32_t ifNum, uint32_t *limit)
Get the Port MAC Locking dynamic limit for the specified interface.
open_error_t openapiPmlVlanViolationDDisableModeGet(openapiClientHandle_t *client_handle, uint32_t vlanId, OPEN_BOOL_t *mode)
Gets the MAC Locking violation D-Disable mode for the specified vlan.
open_error_t openapiPmlIntfVlanDynamicLearnedAddrCountGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t vlanId, uint32_t *count)
Gets the Port MAC Locking vlan dynamic learned address count for the specified interface and vlan...
open_error_t openapiPmlVlanViolationTrapModeGet(openapiClientHandle_t *client_handle, uint32_t vlanId, OPEN_BOOL_t *mode)
Gets the MAC Locking violation trap mode for the specified vlan.