X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=vnet%2Fvnet%2Ffib%2Ffib_node_list.c;h=ceb951b466b51dbd14652859ee1e8f72bc722f9b;hb=6c3ebcc2bfd36a5835a99225ad667e4403293ffb;hp=1d2e75ecec2c5422102e48c11217c3d18fcea111;hpb=5499b1968e1d12b736dd3e30b8fb2b69a300128f;p=vpp.git diff --git a/vnet/vnet/fib/fib_node_list.c b/vnet/vnet/fib/fib_node_list.c index 1d2e75ecec2..ceb951b466b 100644 --- a/vnet/vnet/fib/fib_node_list.c +++ b/vnet/vnet/fib/fib_node_list.c @@ -25,12 +25,6 @@ */ typedef struct fib_node_list_elt_t_ { - /** - * An opaque indentifier set by the FIB node owning this element - * that will allow the owner to identify which element it is. - */ - int fnle_owner_id; - /** * The index of the list this element is in */ @@ -108,7 +102,6 @@ fib_node_list_elt_create (fib_node_list_head_t *head, pool_get(fib_node_list_elt_pool, elt); elt->fnle_list = fib_node_list_head_get_index(head); - elt->fnle_owner_id = id; elt->fnle_owner.fnp_type = type; elt->fnle_owner.fnp_index = index; @@ -126,8 +119,7 @@ fib_node_list_head_init (fib_node_list_head_t *head) } /** - * @brief Create a new node list. The expectation is that these are few in number - * so straight from the memory subsystem + * @brief Create a new node list. */ fib_node_list_t fib_node_list_create (void) @@ -383,3 +375,16 @@ fib_node_list_walk (fib_node_list_t list, fn(&elt->fnle_owner, args); } } + +void +fib_node_list_memory_show (void) +{ + fib_show_memory_usage("Node-list elements", + pool_elts(fib_node_list_elt_pool), + pool_len(fib_node_list_elt_pool), + sizeof(fib_node_list_elt_t)); + fib_show_memory_usage("Node-list heads", + pool_elts(fib_node_list_head_pool), + pool_len(fib_node_list_head_pool), + sizeof(fib_node_list_head_t)); +}