Open Ethernet Networking (OpEN) API Guide and Reference Manual  3.11.1.2
openapi_mvr.h
Go to the documentation of this file.
1 
9 /**********************************************************************
10 *
11 * Copyright 2022 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_mvr.h
28 *
29 * @purpose This code implements the OpEN MVR API
30 *
31 * @component OPEN
32 *
33 * @create 11/30/2022
34 *
35 * @end
36 *
37 *********************************************************************/
38 #ifndef OPENAPI_MVR_H_INCLUDED
39 #define OPENAPI_MVR_H_INCLUDED
40 
41 #include "openapi_common.h"
42 
43 typedef enum
44 {
45  OPEN_MVR_NONE_MODE = 0,
46  OPEN_MVR_COMPATIBLE_MODE,
47  OPEN_MVR_DYNAMIC_MODE
48 } OPEN_MVR_MODE_TYPE_t;
49 
50 typedef enum
51 {
52  OPEN_MVR_NONE_TYPE = 0,
53  OPEN_MVR_STATIC_TYPE,
54  OPEN_MVR_DYNAMIC_TYPE
55 } OPEN_MVR_ENTRY_TYPE_t;
56 
57 typedef enum
58 {
59  OPEN_MVR_NONE_PORT_TYPE = 0,
60  OPEN_MVR_SOURCE_PORT_TYPE,
61  OPEN_MVR_RECEIVER_PORT_TYPE,
62  OPEN_MVR_LAST_TYPE
63 } OPEN_MVR_INTF_TYPE_t;
64 
65 typedef enum
66 {
67  OPEN_MVR_PKT_IGMP_QUERY_RX_COUNTER = 0,
68  OPEN_MVR_PKT_IGMP_REPORT_V1_RX_COUNTER,
69  OPEN_MVR_PKT_IGMP_REPORT_V2_RX_COUNTER,
70  OPEN_MVR_PKT_IGMP_LEAVE_RX_COUNTER,
71  OPEN_MVR_PKT_IGMP_QUERY_TX_COUNTER,
72  OPEN_MVR_PKT_IGMP_REPORT_V1_TX_COUNTER,
73  OPEN_MVR_PKT_IGMP_REPORT_V2_TX_COUNTER,
74  OPEN_MVR_PKT_IGMP_LEAVE_TX_COUNTER,
75  OPEN_MVR_PKT_RX_FAILURE_COUNTER,
76  OPEN_MVR_PKT_TX_FAILURE_COUNTER,
77  OPEN_MVR_PKT_COUNTER_LAST
78 } OPEN_MVR_PDU_COUNTER_t;
79 
80 #define OPEN_MVR_QUERY_TIME_MIN 1
81 #define OPEN_MVR_QUERY_TIME_MAX 100
82 #define OPEN_MVR_MULT_IP_ADDR_MIN 0xe0000100
83 #define OPEN_MVR_MULT_IP_ADDR_MAX 0xefffffff
84 /*************************************************************************/
100  OPEN_CONTROL_t *adminMode);
101 
102 /*************************************************************************/
119  OPEN_CONTROL_t adminMode);
120 
121 /*************************************************************************/
137  uint32_t *queryTime);
138 
139 /*************************************************************************/
156  uint32_t queryTime);
157 
158 /*************************************************************************/
174  OPEN_MVR_MODE_TYPE_t *modeType);
175 
176 /*************************************************************************/
192  OPEN_MVR_MODE_TYPE_t modeType);
193 
194 /*************************************************************************/
210  uint32_t *multicastVlan);
211 
212 /*************************************************************************/
229  uint32_t multicastVlan);
230 
231 /*************************************************************************/
250  uint32_t vlanId,
251  OPEN_BOOL_t *rxVlanParticipationStatus);
252 
253 /*************************************************************************/
270  uint32_t ifNum,
271  OPEN_CONTROL_t *intfMode);
272 
273 /*************************************************************************/
291  uint32_t ifNum,
292  OPEN_CONTROL_t intfMode);
293 
294 /*************************************************************************/
311  uint32_t ifNum,
312  OPEN_MVR_INTF_TYPE_t *intfMvrType);
313 
314 /*************************************************************************/
331  uint32_t ifNum,
332  OPEN_MVR_INTF_TYPE_t intfMvrType);
333 
334 /*************************************************************************/
351  uint32_t ifNum,
352  OPEN_CONTROL_t *immediateMode);
353 
354 /*************************************************************************/
371  uint32_t ifNum,
372  OPEN_CONTROL_t immediateMode);
373 
374 /*************************************************************************/
390  uint32_t groupIp);
391 
392 /*************************************************************************/
408  uint32_t groupIp);
409 
410 /*************************************************************************/
427  uint32_t ifNum, uint32_t groupIp);
428 
429 /*************************************************************************/
446  uint32_t ifNum, uint32_t groupIp);
447 
448 /*************************************************************************/
465  uint32_t groupId, uint32_t *nextGroupId);
466 
467 /*************************************************************************/
484  uint32_t groupIp, uint32_t *nextGroupIp);
485 
486 /*************************************************************************/
503  uint32_t groupId, uint32_t *groupIp);
504 
505 /*************************************************************************/
523  uint32_t ifNum, uint32_t groupId,
524  OPEN_MVR_ENTRY_TYPE_t *type);
525 
526 /*************************************************************************/
544  uint32_t groupId, uint32_t ifNum,
545  uint32_t *nextIfNum);
546 
547 /*************************************************************************/
564  uint32_t ifNum, uint32_t *nextIfNum);
565 
566 /*************************************************************************/
581  uint32_t *groupEntries);
582 
583 /*************************************************************************/
600  uint32_t groupId, OPEN_BOOL_t *status);
601 
602 /*************************************************************************/
619  uint32_t groupIp, uint32_t *groupId);
620 
621 /*************************************************************************/
640  uint32_t ifNum, uint32_t groupId,
641  uint32_t *nextGroupId);
642 
643 /*************************************************************************/
662  uint32_t ifNum, uint32_t groupIp,
663  uint32_t *nextGroupIp);
664 
665 /*************************************************************************/
682  OPEN_MVR_PDU_COUNTER_t counterType,
683  uint32_t *counterValue);
684 
685 
686 #endif /* OPENAPI_MVR_H_INCLUDED */
687 
688 
open_error_t openapiMvrIntfGroupIpAdd(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t groupIp)
Add specified interface to the group.
open_error_t openapiMvrIntfGroupIdGetNext(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t groupId, uint32_t *nextGroupId)
Get next group registered on specified interface.
open_error_t openapiMvrIntfMvrTypeSet(openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_MVR_INTF_TYPE_t intfMvrType)
Sets the interface MVR type of a specified interface.
open_error_t openapiMvrGroupIpDelete(openapiClientHandle_t *client_handle, uint32_t groupIp)
Delete static group IP address.
open_error_t openapiMvrMulticastVlanSet(openapiClientHandle_t *client_handle, uint32_t multicastVlan)
Sets the MVR multicast vlan.
open_error_t openapiMvrPduCounterGet(openapiClientHandle_t *client_handle, OPEN_MVR_PDU_COUNTER_t counterType, uint32_t *counterValue)
Get the global pdu counter values.
open_error_t openapiMvrGroupStatusGet(openapiClientHandle_t *client_handle, uint32_t groupId, OPEN_BOOL_t *status)
Get the group status whether active or not.
open_error_t openapiMvrAdminModeGet(openapiClientHandle_t *client_handle, OPEN_CONTROL_t *adminMode)
Gets the MVR admin mode.
open_error_t openapiMvrGroupIpAdd(openapiClientHandle_t *client_handle, uint32_t groupIp)
Add static group IP address.
open_error_t openapiMvrAdminModeSet(openapiClientHandle_t *client_handle, OPEN_CONTROL_t adminMode)
Sets the MVR admin mode.
open_error_t openapiMvrQueryTimeGet(openapiClientHandle_t *client_handle, uint32_t *queryTime)
Gets the MVR query time.
open_error_t openapiMvrIntfImmediateModeGet(openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t *immediateMode)
Gets the immediate leave mode of a specified interface.
open_error_t openapiMvrIsReceiversInVlan(openapiClientHandle_t *client_handle, uint32_t vlanId, OPEN_BOOL_t *rxVlanParticipationStatus)
Check if receivers participate in specific vlan.
open_error_t
OPEN uses these enumerators to indicate the error codes.
open_error_t openapiMvrModeTypeGet(openapiClientHandle_t *client_handle, OPEN_MVR_MODE_TYPE_t *modeType)
Gets the MVR mode type.
open_error_t openapiMvrIntfStaticGroupIpGetNext(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t groupIp, uint32_t *nextGroupIp)
Get next group IP statically registered on specified interface.
open_error_t openapiMvrIntfEntryTypeGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t groupId, OPEN_MVR_ENTRY_TYPE_t *type)
Get the interface type static or dynamic.
open_error_t openapiMvrIntfModeGet(openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t *intfMode)
Gets the MVR interface mode.
open_error_t openapiMvrGroupNumGet(openapiClientHandle_t *client_handle, uint32_t *groupEntries)
Get the number of the group entries.
open_error_t openapiMvrMulticastVlanGet(openapiClientHandle_t *client_handle, uint32_t *multicastVlan)
Gets the MVR multicast vlan.
open_error_t openapiMvrIntfImmediateModeSet(openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t immediateMode)
Sets the immediate leave mode of a specified interface.
open_error_t openapiMvrGroupEntryGetNext(openapiClientHandle_t *client_handle, uint32_t groupId, uint32_t *nextGroupId)
Get next group ID.
open_error_t openapiMvrIntfGroupIpDelete(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t groupIp)
Delete specified interface from the group.
open_error_t openapiMvrModeTypeSet(openapiClientHandle_t *client_handle, OPEN_MVR_MODE_TYPE_t modeType)
Sets the MVR mode type.
open_error_t openapiMvrGroupIdGet(openapiClientHandle_t *client_handle, uint32_t groupIp, uint32_t *groupId)
Get the group ID of the given IP address.
open_error_t openapiMvrIntfGroupGetNext(openapiClientHandle_t *client_handle, uint32_t groupId, uint32_t ifNum, uint32_t *nextIfNum)
Get next interface from the group with specified ID.
OPEN_CONTROL_t
OPEN uses these enumerators to indicate enable or disable for a given config or status parameter...
open_error_t openapiMvrEntryGetNext(openapiClientHandle_t *client_handle, uint32_t groupIp, uint32_t *nextGroupIp)
Get next group IP address.
open_error_t openapiMvrQueryTimeSet(openapiClientHandle_t *client_handle, uint32_t queryTime)
Sets the MVR query time.
OPEN_BOOL_t
OPEN uses these enumerators to indicate true or false for a given config or status parameter...
open_error_t openapiMvrIntfMvrTypeGet(openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_MVR_INTF_TYPE_t *intfMvrType)
Gets the interface MVR type of a specified interface.
open_error_t openapiMvrIntfGetNext(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t *nextIfNum)
Get next MVR interface.
open_error_t openapiMvrIntfModeSet(openapiClientHandle_t *client_handle, uint32_t ifNum, OPEN_CONTROL_t intfMode)
Sets the MVR interface mode.
open_error_t openapiMvrGroupIpGet(openapiClientHandle_t *client_handle, uint32_t groupId, uint32_t *groupIp)
Get the ip address of the group with specified ID.