From: Jessica Tallon Date: Mon, 21 May 2018 12:27:05 +0000 (+0000) Subject: VPP-1042: Fix the DPDK no-hugetbl flags X-Git-Tag: v18.07-rc1~133 X-Git-Url: https://gerrit.fd.io/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F78%2F12678%2F4;p=vpp.git VPP-1042: Fix the DPDK no-hugetbl flags Change-Id: I7c611d3fa7fabe82294fc22a61d5a3927a2da39d Signed-off-by: Jessica Tallon --- 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);