4 * Copyright(c) 2010-2014 Intel Corporation. All rights reserved.
5 * Copyright(c) 2014 6WIND S.A.
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions
11 * * Redistributions of source code must retain the above copyright
12 * notice, this list of conditions and the following disclaimer.
13 * * Redistributions in binary form must reproduce the above copyright
14 * notice, this list of conditions and the following disclaimer in
15 * the documentation and/or other materials provided with the
17 * * Neither the name of Intel Corporation nor the names of its
18 * contributors may be used to endorse or promote products derived
19 * from this software without specific prior written permission.
21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
23 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
24 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
25 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
26 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
27 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
28 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
29 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
43 #include <sys/types.h>
49 #include <rte_lcore.h>
50 #include <rte_version.h>
51 #include <rte_devargs.h>
52 #include <rte_memcpy.h>
54 #include "eal_internal_cfg.h"
55 #include "eal_options.h"
56 #include "eal_filesystem.h"
58 #define BITS_PER_HEX 4
62 "b:" /* pci-blacklist */
67 "m:" /* memory size */
68 "n:" /* memory channels */
69 "r:" /* memory ranks */
71 "w:" /* pci-whitelist */
75 eal_long_options[] = {
76 {OPT_BASE_VIRTADDR, 1, NULL, OPT_BASE_VIRTADDR_NUM },
77 {OPT_CREATE_UIO_DEV, 0, NULL, OPT_CREATE_UIO_DEV_NUM },
78 {OPT_FILE_PREFIX, 1, NULL, OPT_FILE_PREFIX_NUM },
79 {OPT_HELP, 0, NULL, OPT_HELP_NUM },
80 {OPT_HUGE_DIR, 1, NULL, OPT_HUGE_DIR_NUM },
81 {OPT_HUGE_UNLINK, 0, NULL, OPT_HUGE_UNLINK_NUM },
82 {OPT_LCORES, 1, NULL, OPT_LCORES_NUM },
83 {OPT_LOG_LEVEL, 1, NULL, OPT_LOG_LEVEL_NUM },
84 {OPT_MASTER_LCORE, 1, NULL, OPT_MASTER_LCORE_NUM },
85 {OPT_NO_HPET, 0, NULL, OPT_NO_HPET_NUM },
86 {OPT_NO_HUGE, 0, NULL, OPT_NO_HUGE_NUM },
87 {OPT_NO_PCI, 0, NULL, OPT_NO_PCI_NUM },
88 {OPT_NO_SHCONF, 0, NULL, OPT_NO_SHCONF_NUM },
89 {OPT_PCI_BLACKLIST, 1, NULL, OPT_PCI_BLACKLIST_NUM },
90 {OPT_PCI_WHITELIST, 1, NULL, OPT_PCI_WHITELIST_NUM },
91 {OPT_PROC_TYPE, 1, NULL, OPT_PROC_TYPE_NUM },
92 {OPT_SOCKET_MEM, 1, NULL, OPT_SOCKET_MEM_NUM },
93 {OPT_SYSLOG, 1, NULL, OPT_SYSLOG_NUM },
94 {OPT_VDEV, 1, NULL, OPT_VDEV_NUM },
95 {OPT_VFIO_INTR, 1, NULL, OPT_VFIO_INTR_NUM },
96 {OPT_VMWARE_TSC_MAP, 0, NULL, OPT_VMWARE_TSC_MAP_NUM },
97 {OPT_XEN_DOM0, 0, NULL, OPT_XEN_DOM0_NUM },
101 TAILQ_HEAD(shared_driver_list, shared_driver);
103 /* Definition for shared object drivers. */
104 struct shared_driver {
105 TAILQ_ENTRY(shared_driver) next;
111 /* List of external loadable drivers */
112 static struct shared_driver_list solib_list =
113 TAILQ_HEAD_INITIALIZER(solib_list);
115 /* Default path of external loadable drivers */
116 static const char *default_solib_dir = RTE_EAL_PMD_PATH;
118 static int master_lcore_parsed;
119 static int mem_parsed;
122 eal_reset_internal_config(struct internal_config *internal_cfg)
126 internal_cfg->memory = 0;
127 internal_cfg->force_nrank = 0;
128 internal_cfg->force_nchannel = 0;
129 internal_cfg->hugefile_prefix = HUGEFILE_PREFIX_DEFAULT;
130 internal_cfg->hugepage_dir = NULL;
131 internal_cfg->force_sockets = 0;
132 /* zero out the NUMA config */
133 for (i = 0; i < RTE_MAX_NUMA_NODES; i++)
134 internal_cfg->socket_mem[i] = 0;
135 /* zero out hugedir descriptors */
136 for (i = 0; i < MAX_HUGEPAGE_SIZES; i++)
137 internal_cfg->hugepage_info[i].lock_descriptor = -1;
138 internal_cfg->base_virtaddr = 0;
140 internal_cfg->syslog_facility = LOG_DAEMON;
141 /* default value from build option */
142 internal_cfg->log_level = RTE_LOG_LEVEL;
144 internal_cfg->xen_dom0_support = 0;
146 /* if set to NONE, interrupt mode is determined automatically */
147 internal_cfg->vfio_intr_mode = RTE_INTR_MODE_NONE;
149 #ifdef RTE_LIBEAL_USE_HPET
150 internal_cfg->no_hpet = 0;
152 internal_cfg->no_hpet = 1;
154 internal_cfg->vmware_tsc_map = 0;
155 internal_cfg->create_uio_dev = 0;
159 eal_plugin_add(const char *path)
161 struct shared_driver *solib;
163 solib = malloc(sizeof(*solib));
165 RTE_LOG(ERR, EAL, "malloc(solib) failed\n");
168 memset(solib, 0, sizeof(*solib));
169 strncpy(solib->name, path, PATH_MAX-1);
170 solib->name[PATH_MAX-1] = 0;
171 TAILQ_INSERT_TAIL(&solib_list, solib, next);
177 eal_plugindir_init(const char *path)
180 struct dirent *dent = NULL;
181 char sopath[PATH_MAX];
183 if (path == NULL || *path == '\0')
188 RTE_LOG(ERR, EAL, "failed to open directory %s: %s\n",
189 path, strerror(errno));
193 while ((dent = readdir(d)) != NULL) {
196 snprintf(sopath, PATH_MAX-1, "%s/%s", path, dent->d_name);
197 sopath[PATH_MAX-1] = 0;
199 if (!(stat(sopath, &sb) == 0 && S_ISREG(sb.st_mode)))
202 if (eal_plugin_add(sopath) == -1)
207 /* XXX this ignores failures from readdir() itself */
208 return (dent == NULL) ? 0 : -1;
212 eal_plugins_init(void)
214 struct shared_driver *solib = NULL;
216 if (*default_solib_dir != '\0')
217 eal_plugin_add(default_solib_dir);
219 TAILQ_FOREACH(solib, &solib_list, next) {
222 if (stat(solib->name, &sb) == 0 && S_ISDIR(sb.st_mode)) {
223 if (eal_plugindir_init(solib->name) == -1) {
225 "Cannot init plugin directory %s\n",
230 RTE_LOG(DEBUG, EAL, "open shared lib %s\n",
232 solib->lib_handle = dlopen(solib->name, RTLD_NOW);
233 if (solib->lib_handle == NULL) {
234 RTE_LOG(ERR, EAL, "%s\n", dlerror());
244 * Parse the coremask given as argument (hexadecimal string) and fill
245 * the global configuration (core role and core count) with the parsed
248 static int xdigit2val(unsigned char c)
262 eal_parse_coremask(const char *coremask)
264 struct rte_config *cfg = rte_eal_get_configuration();
270 if (coremask == NULL)
272 /* Remove all blank characters ahead and after .
273 * Remove 0x/0X if exists.
275 while (isblank(*coremask))
277 if (coremask[0] == '0' && ((coremask[1] == 'x')
278 || (coremask[1] == 'X')))
280 i = strlen(coremask);
281 while ((i > 0) && isblank(coremask[i - 1]))
286 for (i = i - 1; i >= 0 && idx < RTE_MAX_LCORE; i--) {
288 if (isxdigit(c) == 0) {
289 /* invalid characters */
293 for (j = 0; j < BITS_PER_HEX && idx < RTE_MAX_LCORE; j++, idx++)
295 if ((1 << j) & val) {
296 if (!lcore_config[idx].detected) {
297 RTE_LOG(ERR, EAL, "lcore %u "
298 "unavailable\n", idx);
301 cfg->lcore_role[idx] = ROLE_RTE;
302 lcore_config[idx].core_index = count;
305 cfg->lcore_role[idx] = ROLE_OFF;
306 lcore_config[idx].core_index = -1;
311 if (coremask[i] != '0')
313 for (; idx < RTE_MAX_LCORE; idx++) {
314 cfg->lcore_role[idx] = ROLE_OFF;
315 lcore_config[idx].core_index = -1;
319 /* Update the count of enabled logical cores of the EAL configuration */
320 cfg->lcore_count = count;
325 eal_parse_corelist(const char *corelist)
327 struct rte_config *cfg = rte_eal_get_configuration();
333 if (corelist == NULL)
336 /* Remove all blank characters ahead and after */
337 while (isblank(*corelist))
339 i = strlen(corelist);
340 while ((i > 0) && isblank(corelist[i - 1]))
344 for (idx = 0; idx < RTE_MAX_LCORE; idx++) {
345 cfg->lcore_role[idx] = ROLE_OFF;
346 lcore_config[idx].core_index = -1;
349 /* Get list of cores */
352 while (isblank(*corelist))
354 if (*corelist == '\0')
357 idx = strtoul(corelist, &end, 10);
358 if (errno || end == NULL)
360 while (isblank(*end))
364 } else if ((*end == ',') || (*end == '\0')) {
366 if (min == RTE_MAX_LCORE)
368 for (idx = min; idx <= max; idx++) {
369 if (cfg->lcore_role[idx] != ROLE_RTE) {
370 cfg->lcore_role[idx] = ROLE_RTE;
371 lcore_config[idx].core_index = count;
379 } while (*end != '\0');
384 /* Update the count of enabled logical cores of the EAL configuration */
385 cfg->lcore_count = count;
390 /* Changes the lcore id of the master thread */
392 eal_parse_master_lcore(const char *arg)
395 struct rte_config *cfg = rte_eal_get_configuration();
398 cfg->master_lcore = (uint32_t) strtol(arg, &parsing_end, 0);
399 if (errno || parsing_end[0] != 0)
401 if (cfg->master_lcore >= RTE_MAX_LCORE)
403 master_lcore_parsed = 1;
408 * Parse elem, the elem could be single number/range or '(' ')' group
409 * 1) A single number elem, it's just a simple digit. e.g. 9
410 * 2) A single range elem, two digits with a '-' between. e.g. 2-6
411 * 3) A group elem, combines multiple 1) or 2) with '( )'. e.g (0,2-4,6)
412 * Within group elem, '-' used for a range separator;
413 * ',' used for a single number.
416 eal_parse_set(const char *input, uint16_t set[], unsigned num)
419 const char *str = input;
423 memset(set, 0, num * sizeof(uint16_t));
425 while (isblank(*str))
428 /* only digit or left bracket is qualify for start point */
429 if ((!isdigit(*str) && *str != '(') || *str == '\0')
432 /* process single number or single range of number */
435 idx = strtoul(str, &end, 10);
436 if (errno || end == NULL || idx >= num)
439 while (isblank(*end))
445 /* process single <number>-<number> */
447 while (isblank(*end))
453 idx = strtoul(end, &end, 10);
454 if (errno || end == NULL || idx >= num)
457 while (isblank(*end))
459 if (*end != ',' && *end != '\0')
463 if (*end != ',' && *end != '\0' &&
467 for (idx = RTE_MIN(min, max);
468 idx <= RTE_MAX(min, max); idx++)
475 /* process set within bracket */
477 while (isblank(*str))
485 /* go ahead to the first digit */
486 while (isblank(*str))
491 /* get the digit value */
493 idx = strtoul(str, &end, 10);
494 if (errno || end == NULL || idx >= num)
497 /* go ahead to separator '-',',' and ')' */
498 while (isblank(*end))
501 if (min == RTE_MAX_LCORE)
503 else /* avoid continuous '-' */
505 } else if ((*end == ',') || (*end == ')')) {
507 if (min == RTE_MAX_LCORE)
509 for (idx = RTE_MIN(min, max);
510 idx <= RTE_MAX(min, max); idx++)
518 } while (*end != '\0' && *end != ')');
523 /* convert from set array to cpuset bitmap */
525 convert_to_cpuset(rte_cpuset_t *cpusetp,
526 uint16_t *set, unsigned num)
532 for (idx = 0; idx < num; idx++) {
536 if (!lcore_config[idx].detected) {
537 RTE_LOG(ERR, EAL, "core %u "
538 "unavailable\n", idx);
542 CPU_SET(idx, cpusetp);
549 * The format pattern: --lcores='<lcores[@cpus]>[<,lcores[@cpus]>...]'
550 * lcores, cpus could be a single digit/range or a group.
551 * '(' and ')' are necessary if it's a group.
552 * If not supply '@cpus', the value of cpus uses the same as lcores.
553 * e.g. '1,2@(5-7),(3-5)@(0,2),(0,6),7-8' means start 9 EAL thread as below
554 * lcore 0 runs on cpuset 0x41 (cpu 0,6)
555 * lcore 1 runs on cpuset 0x2 (cpu 1)
556 * lcore 2 runs on cpuset 0xe0 (cpu 5,6,7)
557 * lcore 3,4,5 runs on cpuset 0x5 (cpu 0,2)
558 * lcore 6 runs on cpuset 0x41 (cpu 0,6)
559 * lcore 7 runs on cpuset 0x80 (cpu 7)
560 * lcore 8 runs on cpuset 0x100 (cpu 8)
563 eal_parse_lcores(const char *lcores)
565 struct rte_config *cfg = rte_eal_get_configuration();
566 static uint16_t set[RTE_MAX_LCORE];
570 const char *lcore_start = NULL;
571 const char *end = NULL;
580 /* Remove all blank characters ahead and after */
581 while (isblank(*lcores))
584 while ((i > 0) && isblank(lcores[i - 1]))
589 /* Reset lcore config */
590 for (idx = 0; idx < RTE_MAX_LCORE; idx++) {
591 cfg->lcore_role[idx] = ROLE_OFF;
592 lcore_config[idx].core_index = -1;
593 CPU_ZERO(&lcore_config[idx].cpuset);
596 /* Get list of cores */
598 while (isblank(*lcores))
603 /* record lcore_set start point */
604 lcore_start = lcores;
606 /* go across a complete bracket */
607 if (*lcore_start == '(') {
608 lcores += strcspn(lcores, ")");
609 if (*lcores++ == '\0')
613 /* scan the separator '@', ','(next) or '\0'(finish) */
614 lcores += strcspn(lcores, "@,");
616 if (*lcores == '@') {
617 /* explicit assign cpu_set */
618 offset = eal_parse_set(lcores + 1, set, RTE_DIM(set));
622 /* prepare cpu_set and update the end cursor */
623 if (0 > convert_to_cpuset(&cpuset,
626 end = lcores + 1 + offset;
627 } else { /* ',' or '\0' */
628 /* haven't given cpu_set, current loop done */
631 /* go back to check <number>-<number> */
632 offset = strcspn(lcore_start, "(-");
633 if (offset < (end - lcore_start) &&
634 *(lcore_start + offset) != '(')
638 if (*end != ',' && *end != '\0')
641 /* parse lcore_set from start point */
642 if (0 > eal_parse_set(lcore_start, set, RTE_DIM(set)))
645 /* without '@', by default using lcore_set as cpu_set */
646 if (*lcores != '@' &&
647 0 > convert_to_cpuset(&cpuset, set, RTE_DIM(set)))
650 /* start to update lcore_set */
651 for (idx = 0; idx < RTE_MAX_LCORE; idx++) {
655 if (cfg->lcore_role[idx] != ROLE_RTE) {
656 lcore_config[idx].core_index = count;
657 cfg->lcore_role[idx] = ROLE_RTE;
663 CPU_SET(idx, &cpuset);
665 rte_memcpy(&lcore_config[idx].cpuset, &cpuset,
666 sizeof(rte_cpuset_t));
670 } while (*end != '\0');
675 cfg->lcore_count = count;
684 eal_parse_syslog(const char *facility, struct internal_config *conf)
691 { "auth", LOG_AUTH },
692 { "cron", LOG_CRON },
693 { "daemon", LOG_DAEMON },
695 { "kern", LOG_KERN },
697 { "mail", LOG_MAIL },
698 { "news", LOG_NEWS },
699 { "syslog", LOG_SYSLOG },
700 { "user", LOG_USER },
701 { "uucp", LOG_UUCP },
702 { "local0", LOG_LOCAL0 },
703 { "local1", LOG_LOCAL1 },
704 { "local2", LOG_LOCAL2 },
705 { "local3", LOG_LOCAL3 },
706 { "local4", LOG_LOCAL4 },
707 { "local5", LOG_LOCAL5 },
708 { "local6", LOG_LOCAL6 },
709 { "local7", LOG_LOCAL7 },
713 for (i = 0; map[i].name; i++) {
714 if (!strcmp(facility, map[i].name)) {
715 conf->syslog_facility = map[i].value;
723 eal_parse_log_level(const char *level, uint32_t *log_level)
729 tmp = strtoul(level, &end, 0);
731 /* check for errors */
732 if ((errno != 0) || (level[0] == '\0') ||
733 end == NULL || (*end != '\0'))
736 /* log_level is a uint32_t */
737 if (tmp >= UINT32_MAX)
744 static enum rte_proc_type_t
745 eal_parse_proc_type(const char *arg)
747 if (strncasecmp(arg, "primary", sizeof("primary")) == 0)
748 return RTE_PROC_PRIMARY;
749 if (strncasecmp(arg, "secondary", sizeof("secondary")) == 0)
750 return RTE_PROC_SECONDARY;
751 if (strncasecmp(arg, "auto", sizeof("auto")) == 0)
752 return RTE_PROC_AUTO;
754 return RTE_PROC_INVALID;
758 eal_parse_common_option(int opt, const char *optarg,
759 struct internal_config *conf)
764 if (rte_eal_devargs_add(RTE_DEVTYPE_BLACKLISTED_PCI,
771 if (rte_eal_devargs_add(RTE_DEVTYPE_WHITELISTED_PCI,
778 if (eal_parse_coremask(optarg) < 0) {
779 RTE_LOG(ERR, EAL, "invalid coremask\n");
785 if (eal_parse_corelist(optarg) < 0) {
786 RTE_LOG(ERR, EAL, "invalid core list\n");
792 conf->memory = atoi(optarg);
793 conf->memory *= 1024ULL;
794 conf->memory *= 1024ULL;
797 /* force number of channels */
799 conf->force_nchannel = atoi(optarg);
800 if (conf->force_nchannel == 0 ||
801 conf->force_nchannel > 4) {
802 RTE_LOG(ERR, EAL, "invalid channel number\n");
806 /* force number of ranks */
808 conf->force_nrank = atoi(optarg);
809 if (conf->force_nrank == 0 ||
810 conf->force_nrank > 16) {
811 RTE_LOG(ERR, EAL, "invalid rank number\n");
815 /* force loading of external driver */
817 if (eal_plugin_add(optarg) == -1)
821 /* since message is explicitly requested by user, we
822 * write message at highest log level so it can always
824 * even if info or warning messages are disabled */
825 RTE_LOG(CRIT, EAL, "RTE Version: '%s'\n", rte_version());
829 case OPT_HUGE_UNLINK_NUM:
830 conf->hugepage_unlink = 1;
833 case OPT_NO_HUGE_NUM:
834 conf->no_hugetlbfs = 1;
841 case OPT_NO_HPET_NUM:
845 case OPT_VMWARE_TSC_MAP_NUM:
846 conf->vmware_tsc_map = 1;
849 case OPT_NO_SHCONF_NUM:
853 case OPT_PROC_TYPE_NUM:
854 conf->process_type = eal_parse_proc_type(optarg);
857 case OPT_MASTER_LCORE_NUM:
858 if (eal_parse_master_lcore(optarg) < 0) {
859 RTE_LOG(ERR, EAL, "invalid parameter for --"
860 OPT_MASTER_LCORE "\n");
866 if (rte_eal_devargs_add(RTE_DEVTYPE_VIRTUAL,
873 if (eal_parse_syslog(optarg, conf) < 0) {
874 RTE_LOG(ERR, EAL, "invalid parameters for --"
880 case OPT_LOG_LEVEL_NUM: {
883 if (eal_parse_log_level(optarg, &log) < 0) {
885 "invalid parameters for --"
889 conf->log_level = log;
893 if (eal_parse_lcores(optarg) < 0) {
894 RTE_LOG(ERR, EAL, "invalid parameter for --"
900 /* don't know what to do, leave this to caller */
910 eal_adjust_config(struct internal_config *internal_cfg)
913 struct rte_config *cfg = rte_eal_get_configuration();
915 if (internal_config.process_type == RTE_PROC_AUTO)
916 internal_config.process_type = eal_proc_type_detect();
918 /* default master lcore is the first one */
919 if (!master_lcore_parsed)
920 cfg->master_lcore = rte_get_next_lcore(-1, 0, 0);
922 /* if no memory amounts were requested, this will result in 0 and
923 * will be overridden later, right after eal_hugepage_info_init() */
924 for (i = 0; i < RTE_MAX_NUMA_NODES; i++)
925 internal_cfg->memory += internal_cfg->socket_mem[i];
931 eal_check_common_options(struct internal_config *internal_cfg)
933 struct rte_config *cfg = rte_eal_get_configuration();
935 if (cfg->lcore_role[cfg->master_lcore] != ROLE_RTE) {
936 RTE_LOG(ERR, EAL, "Master lcore is not enabled for DPDK\n");
940 if (internal_cfg->process_type == RTE_PROC_INVALID) {
941 RTE_LOG(ERR, EAL, "Invalid process type specified\n");
944 if (index(internal_cfg->hugefile_prefix, '%') != NULL) {
945 RTE_LOG(ERR, EAL, "Invalid char, '%%', in --"OPT_FILE_PREFIX" "
949 if (mem_parsed && internal_cfg->force_sockets == 1) {
950 RTE_LOG(ERR, EAL, "Options -m and --"OPT_SOCKET_MEM" cannot "
951 "be specified at the same time\n");
954 if (internal_cfg->no_hugetlbfs && internal_cfg->force_sockets == 1) {
955 RTE_LOG(ERR, EAL, "Option --"OPT_SOCKET_MEM" cannot "
956 "be specified together with --"OPT_NO_HUGE"\n");
960 if (internal_cfg->no_hugetlbfs && internal_cfg->hugepage_unlink) {
961 RTE_LOG(ERR, EAL, "Option --"OPT_HUGE_UNLINK" cannot "
962 "be specified together with --"OPT_NO_HUGE"\n");
966 if (rte_eal_devargs_type_count(RTE_DEVTYPE_WHITELISTED_PCI) != 0 &&
967 rte_eal_devargs_type_count(RTE_DEVTYPE_BLACKLISTED_PCI) != 0) {
968 RTE_LOG(ERR, EAL, "Options blacklist (-b) and whitelist (-w) "
969 "cannot be used at the same time\n");
977 eal_common_usage(void)
979 printf("[options]\n\n"
980 "EAL common options:\n"
981 " -c COREMASK Hexadecimal bitmask of cores to run on\n"
982 " -l CORELIST List of cores to run on\n"
983 " The argument format is <c1>[-c2][,c3[-c4],...]\n"
984 " where c1, c2, etc are core indexes between 0 and %d\n"
985 " --"OPT_LCORES" COREMAP Map lcore set to physical cpu set\n"
986 " The argument format is\n"
987 " '<lcores[@cpus]>[<,lcores[@cpus]>...]'\n"
988 " lcores and cpus list are grouped by '(' and ')'\n"
989 " Within the group, '-' is used for range separator,\n"
990 " ',' is used for single number separator.\n"
991 " '( )' can be omitted for single element group,\n"
992 " '@' can be omitted if cpus and lcores have the same value\n"
993 " --"OPT_MASTER_LCORE" ID Core ID that is used as master\n"
994 " -n CHANNELS Number of memory channels\n"
995 " -m MB Memory to allocate (see also --"OPT_SOCKET_MEM")\n"
996 " -r RANKS Force number of memory ranks (don't detect)\n"
997 " -b, --"OPT_PCI_BLACKLIST" Add a PCI device in black list.\n"
998 " Prevent EAL from using this PCI device. The argument\n"
999 " format is <domain:bus:devid.func>.\n"
1000 " -w, --"OPT_PCI_WHITELIST" Add a PCI device in white list.\n"
1001 " Only use the specified PCI devices. The argument format\n"
1002 " is <[domain:]bus:devid.func>. This option can be present\n"
1003 " several times (once per device).\n"
1004 " [NOTE: PCI whitelist cannot be used with -b option]\n"
1005 " --"OPT_VDEV" Add a virtual device.\n"
1006 " The argument format is <driver><id>[,key=val,...]\n"
1007 " (ex: --vdev=eth_pcap0,iface=eth2).\n"
1008 " -d LIB.so|DIR Add a driver or driver directory\n"
1009 " (can be used multiple times)\n"
1010 " --"OPT_VMWARE_TSC_MAP" Use VMware TSC map instead of native RDTSC\n"
1011 " --"OPT_PROC_TYPE" Type of this process (primary|secondary|auto)\n"
1012 " --"OPT_SYSLOG" Set syslog facility\n"
1013 " --"OPT_LOG_LEVEL" Set default log level\n"
1014 " -v Display version information on startup\n"
1015 " -h, --help This help\n"
1016 "\nEAL options for DEBUG use only:\n"
1017 " --"OPT_HUGE_UNLINK" Unlink hugepage files after init\n"
1018 " --"OPT_NO_HUGE" Use malloc instead of hugetlbfs\n"
1019 " --"OPT_NO_PCI" Disable PCI\n"
1020 " --"OPT_NO_HPET" Disable HPET\n"
1021 " --"OPT_NO_SHCONF" No shared config (mmap'd files)\n"
1022 "\n", RTE_MAX_LCORE);