FD.io VPP  v17.07.01-10-g3be13f0
Vector Packet Processing
fib_node_list.h File Reference
+ Include dependency graph for fib_node_list.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef int(* fib_node_list_walk_cb_t) (fib_node_ptr_t *owner, void *args)
 Callback function invoked during a list walk. More...
 

Functions

fib_node_list_t fib_node_list_create (void)
 a hetrogeneous w.r.t. More...
 
void fib_node_list_destroy (fib_node_list_t *list)
 
u32 fib_node_list_push_front (fib_node_list_t head, int owner_id, fib_node_type_t type, fib_node_index_t index)
 Insert an element at the from of the list. More...
 
u32 fib_node_list_push_back (fib_node_list_t head, int owner_id, fib_node_type_t type, fib_node_index_t index)
 
void fib_node_list_remove (fib_node_list_t head, u32 sibling)
 
void fib_node_list_elt_remove (u32 sibling)
 
int fib_node_list_advance (u32 sibling)
 Advance the sibling one step (toward the tail) in the list. More...
 
int fib_node_list_get_front (fib_node_list_t head, fib_node_ptr_t *ptr)
 
int fib_node_list_elt_get_next (u32 elt, fib_node_ptr_t *ptr)
 
u32 fib_node_list_get_size (fib_node_list_t head)
 
void fib_node_list_walk (fib_node_list_t head, fib_node_list_walk_cb_t fn, void *args)
 Walk the list of node. More...
 
void fib_node_list_memory_show (void)
 

Typedef Documentation

typedef int(* fib_node_list_walk_cb_t) (fib_node_ptr_t *owner, void *args)

Callback function invoked during a list walk.

Definition at line 55 of file fib_node_list.h.

Function Documentation

int fib_node_list_advance ( u32  sibling)

Advance the sibling one step (toward the tail) in the list.

return 0 if at the end of the list, 1 otherwise.

Definition at line 264 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

fib_node_list_t fib_node_list_create ( void  )

a hetrogeneous w.r.t.

FIB node type, list of FIB nodes. Since we cannot use C pointers, due to memeory reallocs, the next/prev are described as an index to an element. Each element contains a pointer (key:{type, index}) to a FIB node.

a hetrogeneous w.r.t.

Definition at line 125 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void fib_node_list_destroy ( fib_node_list_t list)

Definition at line 137 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int fib_node_list_elt_get_next ( u32  elt,
fib_node_ptr_t ptr 
)

Definition at line 291 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void fib_node_list_elt_remove ( u32  sibling)

Definition at line 250 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int fib_node_list_get_front ( fib_node_list_t  head,
fib_node_ptr_t ptr 
)

Definition at line 328 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 fib_node_list_get_size ( fib_node_list_t  head)

Definition at line 313 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void fib_node_list_memory_show ( void  )

Definition at line 380 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 fib_node_list_push_back ( fib_node_list_t  head,
int  owner_id,
fib_node_type_t  type,
fib_node_index_t  index 
)

Definition at line 183 of file fib_node_list.c.

u32 fib_node_list_push_front ( fib_node_list_t  head,
int  owner_id,
fib_node_type_t  type,
fib_node_index_t  index 
)

Insert an element at the from of the list.

Definition at line 156 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void fib_node_list_remove ( fib_node_list_t  head,
u32  sibling 
)

Definition at line 234 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void fib_node_list_walk ( fib_node_list_t  list,
fib_node_list_walk_cb_t  fn,
void *  args 
)

Walk the list of node.

This must be safe w.r.t. the removal of nodes during the walk.

Definition at line 354 of file fib_node_list.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function: