From e513f98f5baa120c37d0ccb796ab06b424f3e473 Mon Sep 17 00:00:00 2001 From: Jessica Tallon Date: Mon, 21 May 2018 12:27:05 +0000 Subject: VPP-1042: Fix the DPDK no-hugetbl flags Change-Id: I7c611d3fa7fabe82294fc22a61d5a3927a2da39d Signed-off-by: Jessica Tallon --- src/plugins/dpdk/device/init.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'src/plugins') diff --git a/src/plugins/dpdk/device/init.c b/src/plugins/dpdk/device/init.c index 0ab339b8455..df91ca99f4b 100644 --- a/src/plugins/dpdk/device/init.c +++ b/src/plugins/dpdk/device/init.c @@ -1034,7 +1034,7 @@ dpdk_config (vlib_main_t * vm, unformat_input_t * input) /* Prime the pump */ if (unformat (input, "no-hugetlb")) { - vec_add1 (conf->eal_init_args, (u8 *) "no-huge"); + vec_add1 (conf->eal_init_args, (u8 *) "--no-huge"); no_huge = 1; } @@ -1336,10 +1336,13 @@ dpdk_config (vlib_main_t * vm, unformat_input_t * input) vec_add1 (conf->eal_init_args, tmp); /* set socket-mem */ - tmp = format (0, "--socket-mem%c", 0); - vec_add1 (conf->eal_init_args, tmp); - tmp = format (0, "%s%c", socket_mem, 0); - vec_add1 (conf->eal_init_args, tmp); + if (!no_huge) + { + tmp = format (0, "--socket-mem%c", 0); + vec_add1 (conf->eal_init_args, tmp); + tmp = format (0, "%s%c", socket_mem, 0); + vec_add1 (conf->eal_init_args, tmp); + } /* NULL terminate the "argv" vector, in case of stupidity */ vec_add1 (conf->eal_init_args, 0); -- cgit 1.2.3-korg