aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/ip/ip4_forward.c
diff options
context:
space:
mode:
authorDave Barach <dave@barachs.net>2020-06-11 08:57:52 -0400
committerDamjan Marion <dmarion@me.com>2020-06-12 12:06:29 +0000
commit01a2a10715551ccbad760cec641786aa079c373a (patch)
treebd9180e1456d2f0110ab6751a458ec4c4f7cd8b2 /src/vnet/ip/ip4_forward.c
parent4cb21c8e5d70d20df94f5d892471a11488547881 (diff)
ip: allocate ip4 mtrie pages in htlb memory
No change in default behavior. To use htlb pages for the ip4 mtrie, use the "ip" command-line option "mtrie-hugetlb". Type: improvement Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I5497e426a47200edff2c7e15563ed6a42af12e7f
Diffstat (limited to 'src/vnet/ip/ip4_forward.c')
-rw-r--r--src/vnet/ip/ip4_forward.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/vnet/ip/ip4_forward.c b/src/vnet/ip/ip4_forward.c
index 0fa9da22c93..595a0a1913c 100644
--- a/src/vnet/ip/ip4_forward.c
+++ b/src/vnet/ip/ip4_forward.c
@@ -3097,10 +3097,13 @@ ip4_config (vlib_main_t * vm, unformat_input_t * input)
{
if (unformat (input, "heap-size %U", unformat_memory_size, &heapsize))
;
+ else if (unformat (input, "mtrie-hugetlb %=", &im->mtrie_hugetlb, 1))
+ ;
else
return clib_error_return (0,
"invalid heap-size parameter `%U'",
format_unformat_error, input);
+
}
im->mtrie_heap_size = heapsize;