FD.io VPP  v21.06-3-gbb25fbf28
Vector Packet Processing
ip6_mfib.h File Reference
+ Include dependency graph for ip6_mfib.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  ip6_mfib_table_instance_t_
 A representation of a single IP6 mfib table. More...
 

Macros

#define IP6_MFIB_DEFAULT_HASH_NUM_BUCKETS   (64 * 1024)
 The IPv4 Multicast-FIB. More...
 
#define IP6_MFIB_DEFAULT_HASH_MEMORY_SIZE   (32<<20)
 

Typedefs

typedef struct ip6_mfib_table_instance_t_ ip6_mfib_table_instance_t
 A representation of a single IP6 mfib table. More...
 

Functions

fib_node_index_t ip6_mfib_table_lookup (const ip6_mfib_t *fib, const ip6_address_t *src, const ip6_address_t *grp, u32 len)
 
fib_node_index_t ip6_mfib_table_fwd_lookup (const ip6_mfib_t *fib, const ip6_address_t *src, const ip6_address_t *grp)
 
fib_node_index_t ip6_mfib_table_lookup_exact_match (const ip6_mfib_t *fib, const ip6_address_t *grp, const ip6_address_t *src, u32 len)
 
fib_node_index_t ip6_mfib_table_get_less_specific (const ip6_mfib_t *mfib, const ip6_address_t *src, const ip6_address_t *grp, u32 len)
 
void ip6_mfib_table_entry_remove (ip6_mfib_t *fib, const ip6_address_t *grp, const ip6_address_t *src, u32 len)
 
void ip6_mfib_table_entry_insert (ip6_mfib_t *fib, const ip6_address_t *grp, const ip6_address_t *src, u32 len, fib_node_index_t fib_entry_index)
 
void ip6_mfib_table_destroy (ip6_mfib_t *fib)
 
void ip6_mfib_interface_enable_disable (u32 sw_if_index, int is_enable)
 Add/remove the interface from the accepting list of the special MFIB entries. More...
 
static ip6_mfib_tip6_mfib_get (u32 index)
 Get the FIB at the given index. More...
 
u32 ip6_mfib_table_find_or_create_and_lock (u32 table_id, mfib_source_t src)
 Get or create an IPv4 fib. More...
 
u32 ip6_mfib_table_create_and_lock (mfib_source_t src)
 
static u32 ip6_mfib_index_from_table_id (u32 table_id)
 
u32 ip6_mfib_table_get_index_for_sw_if_index (u32 sw_if_index)
 
fib_node_index_t ip6_mfib_table_lookup2 (const ip6_mfib_t *mfib, const ip6_address_t *src, const ip6_address_t *grp)
 Data-plane lookup function. More...
 
void ip6_mfib_table_walk (ip6_mfib_t *mfib, mfib_table_walk_fn_t fn, void *ctx)
 Walk the IP6 mfib table. More...
 
u8format_ip6_mfib_table_memory (u8 *s, va_list *args)
 format (display) ipv6 MFIB mempry usage More...
 

Variables

ip6_mfib_table_instance_t ip6_mfib_table
 the single MFIB table More...
 

Macro Definition Documentation

◆ IP6_MFIB_DEFAULT_HASH_MEMORY_SIZE

#define IP6_MFIB_DEFAULT_HASH_MEMORY_SIZE   (32<<20)

Definition at line 40 of file ip6_mfib.h.

◆ IP6_MFIB_DEFAULT_HASH_NUM_BUCKETS

#define IP6_MFIB_DEFAULT_HASH_NUM_BUCKETS   (64 * 1024)

The IPv4 Multicast-FIB.

FIXME

This IPv4 FIB is used by the protocol independent FIB. So directly using this APIs in client code is not encouraged. However, this IPv4 FIB can be used if all the client wants is an IPv4 prefix data-base

Definition at line 39 of file ip6_mfib.h.

Typedef Documentation

◆ ip6_mfib_table_instance_t

A representation of a single IP6 mfib table.

Function Documentation

◆ format_ip6_mfib_table_memory()

u8* format_ip6_mfib_table_memory ( u8 s,
va_list *  args 
)

format (display) ipv6 MFIB mempry usage

Definition at line 524 of file ip6_mfib.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ip6_mfib_get()

static ip6_mfib_t* ip6_mfib_get ( u32  index)
inlinestatic

Get the FIB at the given index.

Definition at line 101 of file ip6_mfib.h.

+ Here is the caller graph for this function:

◆ ip6_mfib_index_from_table_id()

static u32 ip6_mfib_index_from_table_id ( u32  table_id)
inlinestatic

Definition at line 124 of file ip6_mfib.h.

+ Here is the caller graph for this function:

◆ ip6_mfib_interface_enable_disable()

void ip6_mfib_interface_enable_disable ( u32  sw_if_index,
int  is_enable 
)

Add/remove the interface from the accepting list of the special MFIB entries.

Definition at line 234 of file ip6_mfib.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ip6_mfib_table_create_and_lock()

u32 ip6_mfib_table_create_and_lock ( mfib_source_t  src)

◆ ip6_mfib_table_destroy()

void ip6_mfib_table_destroy ( ip6_mfib_t fib)

Definition at line 193 of file ip6_mfib.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ip6_mfib_table_entry_insert()

void ip6_mfib_table_entry_insert ( ip6_mfib_t fib,
const ip6_address_t *  grp,
const ip6_address_t *  src,
u32  len,
fib_node_index_t  fib_entry_index 
)

Definition at line 467 of file ip6_mfib.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ip6_mfib_table_entry_remove()

void ip6_mfib_table_entry_remove ( ip6_mfib_t fib,
const ip6_address_t *  grp,
const ip6_address_t *  src,
u32  len 
)

Definition at line 492 of file ip6_mfib.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ip6_mfib_table_find_or_create_and_lock()

u32 ip6_mfib_table_find_or_create_and_lock ( u32  table_id,
mfib_source_t  src 
)

Get or create an IPv4 fib.

Get or create an IPv4 fib with the provided table ID.

Parameters
table_idWhen set to ~0, an arbitrary and unused fib ID is picked and can be retrieved with ret->table_id. Otherwise, the fib ID to be used to retrieve or create the desired fib.
Returns
A pointer to the retrieved or created fib.

Definition at line 275 of file ip6_mfib.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ip6_mfib_table_fwd_lookup()

fib_node_index_t ip6_mfib_table_fwd_lookup ( const ip6_mfib_t fib,
const ip6_address_t *  src,
const ip6_address_t *  grp 
)

Definition at line 352 of file ip6_mfib.c.

+ Here is the caller graph for this function:

◆ ip6_mfib_table_get_index_for_sw_if_index()

u32 ip6_mfib_table_get_index_for_sw_if_index ( u32  sw_if_index)

Definition at line 289 of file ip6_mfib.c.

+ Here is the caller graph for this function:

◆ ip6_mfib_table_get_less_specific()

fib_node_index_t ip6_mfib_table_get_less_specific ( const ip6_mfib_t mfib,
const ip6_address_t *  src,
const ip6_address_t *  grp,
u32  len 
)

Definition at line 380 of file ip6_mfib.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ip6_mfib_table_lookup()

fib_node_index_t ip6_mfib_table_lookup ( const ip6_mfib_t fib,
const ip6_address_t *  src,
const ip6_address_t *  grp,
u32  len 
)

Definition at line 417 of file ip6_mfib.c.

+ Here is the caller graph for this function:

◆ ip6_mfib_table_lookup2()

fib_node_index_t ip6_mfib_table_lookup2 ( const ip6_mfib_t mfib,
const ip6_address_t *  src,
const ip6_address_t *  grp 
)

Data-plane lookup function.

◆ ip6_mfib_table_lookup_exact_match()

fib_node_index_t ip6_mfib_table_lookup_exact_match ( const ip6_mfib_t fib,
const ip6_address_t *  grp,
const ip6_address_t *  src,
u32  len 
)

Definition at line 328 of file ip6_mfib.c.

+ Here is the caller graph for this function:

◆ ip6_mfib_table_walk()

void ip6_mfib_table_walk ( ip6_mfib_t mfib,
mfib_table_walk_fn_t  fn,
void *  ctx 
)

Walk the IP6 mfib table.

Parameters
mfibthe table to walk
fnThe function to invoke on each entry visited
ctxA context passed in the visit function

Definition at line 628 of file ip6_mfib.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Variable Documentation

◆ ip6_mfib_table

ip6_mfib_table_instance_t ip6_mfib_table

the single MFIB table

Definition at line 22 of file ip6_mfib.c.