Skip to contentSkip to conversation

eal/freebsd: ignore in-memory option

PATCH In review Bruce Richardson 2 participants 2 messages Sep 13, 2021 – Oct 13, 2021

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 eal/freebsd: ignore in-memory option

The in-memory option is not supported on FreeBSD so print a warning and ignore the flag when it is specified for BSD apps. The lack of support is due to the different way in which memory is managed on FreeBSD using the contigmem driver rather than via a hugetlbfs filesystem.

Fixes 14de8734c401 ("eal: add --in-memory option")
---
 lib/eal/freebsd/eal.c | 4 ++++
 1 file changed, 4 insertions(+)
lib/eal/freebsd/eal.c +4 -0
index 6cee5ae369..fb734012a4 100644
@@ -718,6 +718,10 @@ rte_eal_init(int argc, char **argv)
 
 	/* FreeBSD always uses legacy memory model */
 	internal_conf->legacy_mem = true;
+	if (internal_conf->in_memory) {
+		RTE_LOG(WARNING, EAL, "Warning: ignoring unsupported flag, '%s'\n", OPT_IN_MEMORY);
+		internal_conf->in_memory = false;
+	}
 
 	if (eal_plugins_init() < 0) {
 		rte_eal_init_alert("Cannot init plugins");
Signature · 1 line
2.30.2
#1 lore raw

13/09/2021 16:34, Bruce Richardson:

Quoted 9 lines

The in-memory option is not supported on FreeBSD so print a warning and ignore the flag when it is specified for BSD apps. The lack of support is due to the different way in which memory is managed on FreeBSD using the contigmem driver rather than via a hugetlbfs filesystem.

Fixes 14de8734c401 ("eal: add --in-memory option")

Applied with Cc:stable, thanks.