From: Thomas Monjalon <thomas@monjalon.net>
To: anatoly.burakov@intel.com
Cc: dev@dpdk.org
Subject: [dpdk-dev] [PATCH v3] eal: warn on legacy memory allocation requirement
Date: Tue, 30 Jul 2019 19:21:53 +0200 [thread overview]
Message-ID: <20190730172153.29008-1-thomas@monjalon.net> (raw)
In-Reply-To: <20190718093432.14092-1-thomas@monjalon.net>
When using --no-huge mode, dynamic allocation is not supported.
Because of this limitation, the option --legacy-mem is implied
and -m may be needed to specify the amount of memory to allocate.
Otherwise the default amount MEMSIZE_IF_NO_HUGE_PAGE will be allocated.
The option --socket-mem can also be used with --legacy-mem
when hugepages are supported.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
---
v3:
- replace "allocation" with "amount of reserved memory"
- add --socket-mem
- more rewording
v2:
- user-oriented message
- trigger warning on any legacy mem option
---
lib/librte_eal/common/eal_common_options.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/lib/librte_eal/common/eal_common_options.c b/lib/librte_eal/common/eal_common_options.c
index 512d5088e..ab0b6082b 100644
--- a/lib/librte_eal/common/eal_common_options.c
+++ b/lib/librte_eal/common/eal_common_options.c
@@ -1589,6 +1589,11 @@ eal_check_common_options(struct internal_config *internal_cfg)
"with --"OPT_MATCH_ALLOCATIONS"\n");
return -1;
}
+ if (internal_cfg->legacy_mem && internal_cfg->memory == 0) {
+ RTE_LOG(NOTICE, EAL, "Static memory layout is selected, "
+ "amount of reserved memory can be adjusted with "
+ "-m or --"OPT_SOCKET_MEM"\n");
+ }
return 0;
}
--
2.21.0
next prev parent reply other threads:[~2019-07-30 17:21 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-18 9:34 [dpdk-dev] [PATCH] eal: warn on --no-huge " Thomas Monjalon
2019-07-18 10:18 ` Burakov, Anatoly
2019-07-18 10:29 ` Thomas Monjalon
2019-07-18 10:37 ` Burakov, Anatoly
2019-07-22 16:55 ` [dpdk-dev] [PATCH v2] eal: warn on legacy memory " Thomas Monjalon
2019-07-22 17:03 ` Thomas Monjalon
2019-07-23 9:10 ` Burakov, Anatoly
2019-07-30 17:21 ` Thomas Monjalon [this message]
2019-07-31 9:15 ` [dpdk-dev] [PATCH v3] " Burakov, Anatoly
2019-08-05 9:46 ` Thomas Monjalon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190730172153.29008-1-thomas@monjalon.net \
--to=thomas@monjalon.net \
--cc=anatoly.burakov@intel.com \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).