|
FD.io VPP
v21.06-3-gbb25fbf28
Vector Packet Processing
|
Go to the documentation of this file.
149 s =
format(s,
"[%d] %U prio:%d.%d behaviour:%s",
210 .path =
"show fib source",
212 .short_help =
"show fib source [prio]",
219 #define _(s,p,b) fib_source_register(s,p,b);
fib_source_priority_t fsp_slot
static const char * fib_source_names[]
struct fib_source_prio_t_ fib_source_prio_t
static vlib_cli_command_t show_fib_sources
(constructor) VLIB_CLI_COMMAND (show_fib_sources)
fib_source_behaviour_t fib_source_get_behaviour(fib_source_t src)
void fib_source_register(fib_source_t src, fib_source_priority_t prio, fib_source_behaviour_t bh)
vlib_main_t * vm
X-connect all packets from the HOST to the PHY.
static fib_source_reg_t * fib_source_regs
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)
fib_source_priority_cmp_t fib_source_cmp(fib_source_t s1, fib_source_t s2)
#define vec_len(v)
Number of elements in vector (rvalue-only, NULL tolerant)
@ FIB_SOURCE_INVALID
An invalid source This is not a real source, so don't use it to source a prefix.
#define vec_dup(V)
Return copy of vector (no header, no alignment)
static const char * fib_source_behaviour_names[]
fib_source_behaviour_t fsr_behaviour
u16 fib_source_get_prio(fib_source_t src)
static clib_error_t * fib_source_show(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
static fib_source_t fib_source_id
#define vec_validate(V, I)
Make sure vector is long enough for given index (no header, unspecified alignment)
#define VLIB_CLI_COMMAND(x,...)
enum fib_source_behaviour_t_ fib_source_behaviour_t
Each source has a defined behaviour that controls how entries behave that have that source.
static u8 * format_fib_source_reg(u8 *s, va_list *a)
void vlib_cli_output(vlib_main_t *vm, char *fmt,...)
fib_source_t fib_source_allocate(const char *name, fib_source_priority_t prio, fib_source_behaviour_t bh)
void fib_source_walk(fib_source_walk_t fn, void *ctx)
u8 fib_source_priority_t
Each source is assigned a priority.
static void fib_source_reg_init(fib_source_t src, const char *name, fib_source_priority_t prio, fib_source_behaviour_t bh)
#define vec_free(V)
Free vector's memory (no header).
fib_source_priority_t fsp_class
static int fib_source_reg_cmp_for_sort(void *v1, void *v2)
fib_source_prio_t fsr_prio
description fragment has unexpected format
#define vec_foreach(var, vec)
Vector iterator.
#define FIB_SOURCE_BEHAVIOURS
STATIC_ASSERT_SIZEOF(fib_source_priority_t, 1)
for each client requested priority count the number pf uses of that prio so we can asign is usage a s...
#define vec_sort_with_function(vec, f)
Sort a vector using the supplied element comparison function.
u8 * format_fib_source(u8 *s, va_list *a)
enum fib_source_t_ fib_source_t
The different sources that can create a route.
#define foreach_fib_source
The fixed source to priority mappings.
struct fib_source_reg_t_ fib_source_reg_t
static fib_source_priority_t fib_source_prio_by_class[0x100]
void fib_source_module_init(void)
enum fib_source_priority_cmp_t_ fib_source_priority_cmp_t
source comparison