Open Ethernet Networking (OpEN) API Guide and Reference Manual  3.12.0.1
openapi_mfdb.h
Go to the documentation of this file.
1 
9 /********************************************************************************
10 *
11 * Copyright 2016-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 ********************************************************************************
26 *
27 * @filename openapi_mfdb.h
28 *
29 * @purpose Provide interface to Switch MFDB
30 *
31 * @component OpEN
32 *
33 * @create 06/18/2015
34 *
35 * @end
36 *
37 ********************************************************************************/
38 #ifndef OPENAPI_MFDB_H_INCLUDED
39 #define OPENAPI_MFDB_H_INCLUDED
40 
41 #include "openapi_common.h"
42 
43 #define OPEN_MFDB_INTF_LIST_LENGTH 4096
44 #define OPEN_MFDB_VIDMAC_LENGTH 24
45 #define OPEN_MFDB_MAC_LENGTH 18
46 #define OPENAPI_MFDB_DESCR_LEN 16
47 
49 typedef enum
50 {
51  OPEN_MFDB_PROTOCOL_STATIC = 1,
59  OPEN_MFDB_PROTOCOL_RESERVED_MCAST = 9,
63 
65 typedef enum
66 {
67  OPEN_MFDB_TYPE_STATIC = 0,
70 
71 /*************************************************************************************************/
89  open_buffdesc * vidMac,
91 
92 /*************************************************************************************************/
112  open_buffdesc * vidMac,
114 
115 /*************************************************************************************************/
135  open_buffdesc * vidMac,
136  OPEN_MFDB_PROTOCOL_TYPE_t * nextProt);
137 
138 /*************************************************************************************************/
174  open_buffdesc * vidMac,
175  OPEN_MFDB_PROTOCOL_TYPE_t nextProt,
176  open_buffdesc * mac,
177  uint32_t * vlanId,
178  OPEN_MFDB_PROTOCOL_TYPE_t * compId,
179  OPEN_MFDB_ENTRY_TYPE_t * type,
180  open_buffdesc * desc,
181  open_buffdesc * frwdIntMask,
182  open_buffdesc * fltIntMask,
183  open_buffdesc * absPortMask);
184 
185 /*************************************************************************************************/
216  open_buffdesc * vidMac,
218  OPEN_MFDB_PROTOCOL_TYPE_t * nextCompId,
219  OPEN_MFDB_ENTRY_TYPE_t * type,
220  open_buffdesc * desc,
221  open_buffdesc * frwdPortMask,
222  open_buffdesc * fltPortMask);
223 
224 /*************************************************************************************************/
241  open_buffdesc * vidMac);
242 
243 /*************************************************************************************************/
268  open_buffdesc * vidMac,
269  uint32_t matchType,
270  open_buffdesc * absMask);
271 
272 /*************************************************************************************************/
297  open_buffdesc * vidMac,
298  uint32_t matchType,
299  open_buffdesc * absMask);
300 
301 /*************************************************************************************************/
316  uint32_t * maxEntries);
317 
318 /*************************************************************************************************/
333  uint32_t * mostEntries);
334 
335 /*************************************************************************************************/
350  uint32_t * currEntries);
351 #endif /* OPENAPI_MFDB_H_INCLUDED */
352 
OPEN_MFDB_PROTOCOL_TYPE_t
OpEN uses this enumeration to define type of MFDB protocol.
Definition: openapi_mfdb.h:49
OPEN_MPLS_LFDB_PROTOCOL_t protocol
Protocol by which the label is created.
Definition: openapi_mpls.h:105
MFDB potocol type is MMRP.
Definition: openapi_mfdb.h:57
MFDB potocol type is MVR.
Definition: openapi_mfdb.h:56
open_error_t openapiMfdbEntryDataGet(openapiClientHandle_t *client_handle, open_buffdesc *vidMac, OPEN_MFDB_PROTOCOL_TYPE_t nextProt, open_buffdesc *mac, uint32_t *vlanId, OPEN_MFDB_PROTOCOL_TYPE_t *compId, OPEN_MFDB_ENTRY_TYPE_t *type, open_buffdesc *desc, open_buffdesc *frwdIntMask, open_buffdesc *fltIntMask, open_buffdesc *absPortMask)
Returns the MFDB Entry data.
open_error_t
OPEN uses these enumerators to indicate the error codes.
open_error_t openapiMfdbEntryLearntIntfGetNext(openapiClientHandle_t *client_handle, open_buffdesc *vidMac, uint32_t matchType, open_buffdesc *absMask)
Returns the forwarding interfaces of the next learned VLANID-MAC entry.
open_error_t openapiMfdbEntryProtocolGetExact(openapiClientHandle_t *client_handle, open_buffdesc *vidMac, OPEN_MFDB_PROTOCOL_TYPE_t protocol)
Checks if a VLANID-MAC entry, that uses a specific protocol, exists in the MFDB table.
MFDB potocol type is static.
Definition: openapi_mfdb.h:52
MFDB potocol type is MSRP.
Definition: openapi_mfdb.h:58
total number of protocols
Definition: openapi_mfdb.h:60
open_error_t openapiMfdbEntryGetNext(openapiClientHandle_t *client_handle, open_buffdesc *vidMac, OPEN_MFDB_PROTOCOL_TYPE_t *nextProt)
Returns the next VLANID-MAC entry.
open_error_t openapiMfdbMostEntriesGet(openapiClientHandle_t *client_handle, uint32_t *mostEntries)
Returns the most number of entries ever in the MFDB table.
MFDB potocol type is GMRP.
Definition: openapi_mfdb.h:53
open_error_t openapiMfdbCurrEntriesGet(openapiClientHandle_t *client_handle, uint32_t *currEntries)
Returns the number of current entries in the MFDB table.
OPEN_MFDB_ENTRY_TYPE_t
OpEN uses this enumeration to define type of MFDB entry.
Definition: openapi_mfdb.h:65
open_error_t openapiMfdbEntryGetFirst(openapiClientHandle_t *client_handle, open_buffdesc *vidMac, OPEN_MFDB_PROTOCOL_TYPE_t *prot)
Returns the first VLANID-MAC entry.
open_error_t openapiMfdbEntryFwdIntfGetExact(openapiClientHandle_t *client_handle, open_buffdesc *vidMac)
Checks if a VLANID-MAC entry exists in the MFDB table.
MFDB entry type is static.
Definition: openapi_mfdb.h:68
open_error_t openapiMfdbMaxTableEntriesGet(openapiClientHandle_t *client_handle, uint32_t *maxEntries)
Returns the maximum number of entries that the MFDB table can hold.
MFDB potocol type is MLD.
Definition: openapi_mfdb.h:55
open_error_t openapiMfdbEntryFwdIntfGetNext(openapiClientHandle_t *client_handle, open_buffdesc *vidMac, uint32_t matchType, open_buffdesc *absMask)
Returns the forwarding interfaces of the next VLANID-MAC entry.
MFDB potocol type is IGMP.
Definition: openapi_mfdb.h:54
open_error_t openapiMfdbComponentEntryGetNext(openapiClientHandle_t *client_handle, open_buffdesc *vidMac, OPEN_MFDB_PROTOCOL_TYPE_t compId, OPEN_MFDB_PROTOCOL_TYPE_t *nextCompId, OPEN_MFDB_ENTRY_TYPE_t *type, open_buffdesc *desc, open_buffdesc *frwdPortMask, open_buffdesc *fltPortMask)
Returns the next VLANID-MAC entry of the same user.