FD.io VPP
v21.10.1-2-g0a485f517
Vector Packet Processing
|
Go to the source code of this file.
Macros | |
#define | FIB_SOURCES |
#define | FIB_SOURCE_BH_MAX (FIB_SOURCE_BH_ADJ+1) |
#define | FIB_SOURCE_BEHAVIOURS |
#define | foreach_fib_source |
The fixed source to priority mappings. More... | |
#define | FIB_SOURCE_PRIORITY_HI 0x10 |
Some priority values that plugins might use when they are not to concerned where in the list they'll go. More... | |
#define | FIB_SOURCE_PRIORITY_LOW 0xd0 |
Typedefs | |
typedef enum fib_source_t_ | fib_source_t |
The different sources that can create a route. More... | |
typedef u8 | fib_source_priority_t |
Each source is assigned a priority. More... | |
typedef enum fib_source_priority_cmp_t_ | fib_source_priority_cmp_t |
source comparison More... | |
typedef enum fib_source_behaviour_t_ | fib_source_behaviour_t |
Each source has a defined behaviour that controls how entries behave that have that source. More... | |
typedef walk_rc_t(* | fib_source_walk_t) (fib_source_t id, const char *name, fib_source_priority_t prio, fib_source_behaviour_t bh, void *ctx) |
Functions | |
STATIC_ASSERT (sizeof(fib_source_t)==1, "FIB too many sources") | |
u16 | fib_source_get_prio (fib_source_t src) |
fib_source_behaviour_t | fib_source_get_behaviour (fib_source_t src) |
fib_source_priority_cmp_t | fib_source_cmp (fib_source_t s1, fib_source_t s2) |
u8 * | format_fib_source (u8 *s, va_list *a) |
fib_source_t | fib_source_allocate (const char *name, fib_source_priority_t prio, fib_source_behaviour_t bh) |
void | fib_source_register (fib_source_t src, fib_source_priority_t prio, fib_source_behaviour_t bh) |
void | fib_source_walk (fib_source_walk_t fn, void *ctx) |
void | fib_source_module_init (void) |
#define FIB_SOURCE_BEHAVIOURS |
Definition at line 238 of file fib_source.h.
#define FIB_SOURCE_BH_MAX (FIB_SOURCE_BH_ADJ+1) |
Definition at line 236 of file fib_source.h.
#define FIB_SOURCE_PRIORITY_HI 0x10 |
Some priority values that plugins might use when they are not to concerned where in the list they'll go.
Definition at line 284 of file fib_source.h.
#define FIB_SOURCE_PRIORITY_LOW 0xd0 |
Definition at line 285 of file fib_source.h.
#define FIB_SOURCES |
Definition at line 151 of file fib_source.h.
#define foreach_fib_source |
The fixed source to priority mappings.
Declared here so those adding new sources can better determine their respective priority values.
Definition at line 255 of file fib_source.h.
typedef enum fib_source_behaviour_t_ fib_source_behaviour_t |
Each source has a defined behaviour that controls how entries behave that have that source.
Sources with non-default behaviour may have a private data area in the fib_entry_src_t union.
typedef enum fib_source_priority_cmp_t_ fib_source_priority_cmp_t |
source comparison
typedef u8 fib_source_priority_t |
Each source is assigned a priority.
lower priority is better. the source with the best source with have its contribution added to forwarding. the lesser sources will be 'remembered' by FIB and added to forwarding should the best source be removed.
Definition at line 182 of file fib_source.h.
typedef enum fib_source_t_ fib_source_t |
The different sources that can create a route.
A source is a combination of two concepts; priority and behaviour. Priority determines whether the source is contributing forwarding. Behaviour determines how FIB entries with this source interact with other elements of FIB.
typedef walk_rc_t(* fib_source_walk_t) (fib_source_t id, const char *name, fib_source_priority_t prio, fib_source_behaviour_t bh, void *ctx) |
Definition at line 303 of file fib_source.h.
Each source has a defined behaviour that controls how entries behave that have that source.
Sources with non-default behaviour may have a private data area in the fib_entry_src_t union.
Definition at line 200 of file fib_source.h.
source comparison
Enumerator | |
---|---|
FIB_SOURCE_CMP_BETTER | |
FIB_SOURCE_CMP_WORSE | |
FIB_SOURCE_CMP_EQUAL |
Definition at line 187 of file fib_source.h.
enum fib_source_t_ |
The different sources that can create a route.
A source is a combination of two concepts; priority and behaviour. Priority determines whether the source is contributing forwarding. Behaviour determines how FIB entries with this source interact with other elements of FIB.
Definition at line 29 of file fib_source.h.
fib_source_t fib_source_allocate | ( | const char * | name, |
fib_source_priority_t | prio, | ||
fib_source_behaviour_t | bh | ||
) |
Definition at line 118 of file fib_source.c.
fib_source_priority_cmp_t fib_source_cmp | ( | fib_source_t | s1, |
fib_source_t | s2 | ||
) |
Definition at line 76 of file fib_source.c.
fib_source_behaviour_t fib_source_get_behaviour | ( | fib_source_t | src | ) |
u16 fib_source_get_prio | ( | fib_source_t | src | ) |
void fib_source_module_init | ( | void | ) |
void fib_source_register | ( | fib_source_t | src, |
fib_source_priority_t | prio, | ||
fib_source_behaviour_t | bh | ||
) |
void fib_source_walk | ( | fib_source_walk_t | fn, |
void * | ctx | ||
) |
STATIC_ASSERT | ( | sizeof(fib_source_t) | = =1 , |
"FIB too many sources" | |||
) |