2018-01-29 13:11:25 +00:00
|
|
|
/* SPDX-License-Identifier: BSD-3-Clause
|
|
|
|
* Copyright(c) 2014 6WIND S.A.
|
2014-09-22 08:37:59 +00:00
|
|
|
*/
|
|
|
|
|
2014-11-21 14:26:17 +00:00
|
|
|
#ifndef EAL_OPTIONS_H
|
|
|
|
#define EAL_OPTIONS_H
|
2014-09-22 08:38:00 +00:00
|
|
|
|
|
|
|
enum {
|
|
|
|
/* long options mapped to a short option */
|
2015-01-29 16:51:17 +00:00
|
|
|
#define OPT_HELP "help"
|
|
|
|
OPT_HELP_NUM = 'h',
|
2015-01-29 16:42:31 +00:00
|
|
|
#define OPT_PCI_BLACKLIST "pci-blacklist"
|
|
|
|
OPT_PCI_BLACKLIST_NUM = 'b',
|
|
|
|
#define OPT_PCI_WHITELIST "pci-whitelist"
|
|
|
|
OPT_PCI_WHITELIST_NUM = 'w',
|
2014-09-22 08:37:59 +00:00
|
|
|
|
2014-09-22 08:38:00 +00:00
|
|
|
/* first long only option value must be >= 256, so that we won't
|
|
|
|
* conflict with short options */
|
|
|
|
OPT_LONG_MIN_NUM = 256,
|
2015-01-29 16:42:31 +00:00
|
|
|
#define OPT_BASE_VIRTADDR "base-virtaddr"
|
|
|
|
OPT_BASE_VIRTADDR_NUM,
|
|
|
|
#define OPT_CREATE_UIO_DEV "create-uio-dev"
|
|
|
|
OPT_CREATE_UIO_DEV_NUM,
|
|
|
|
#define OPT_FILE_PREFIX "file-prefix"
|
|
|
|
OPT_FILE_PREFIX_NUM,
|
|
|
|
#define OPT_HUGE_DIR "huge-dir"
|
|
|
|
OPT_HUGE_DIR_NUM,
|
2015-10-28 22:04:25 +00:00
|
|
|
#define OPT_HUGE_UNLINK "huge-unlink"
|
|
|
|
OPT_HUGE_UNLINK_NUM,
|
eal: new option --lcores for cpu assignment
It supports one new eal long option '--lcores' for EAL thread cpuset assignment.
The format pattern:
--lcores='<lcores[@cpus]>[<,lcores[@cpus]>...]'
lcores, cpus could be a single digit/range or a group.
'(' and ')' are necessary if it's a group.
If not supply '@cpus', the value of cpus uses the same as lcores.
e.g. '1,2@(5-7),(3-5)@(0,2),(0,6),7-8' means starting 9 EAL thread as below
lcore 0 runs on cpuset 0x41 (cpu 0,6)
lcore 1 runs on cpuset 0x2 (cpu 1)
lcore 2 runs on cpuset 0xe0 (cpu 5,6,7)
lcore 3,4,5 runs on cpuset 0x5 (cpu 0,2)
lcore 6 runs on cpuset 0x41 (cpu 0,6)
lcore 7 runs on cpuset 0x80 (cpu 7)
lcore 8 runs on cpuset 0x100 (cpu 8)
Test report: http://dpdk.org/ml/archives/dev/2015-February/013383.html
Signed-off-by: Cunming Liang <cunming.liang@intel.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
Tested-by: Qun Wan <qun.wan@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
2015-02-17 02:08:00 +00:00
|
|
|
#define OPT_LCORES "lcores"
|
|
|
|
OPT_LCORES_NUM,
|
2015-01-29 16:42:31 +00:00
|
|
|
#define OPT_LOG_LEVEL "log-level"
|
|
|
|
OPT_LOG_LEVEL_NUM,
|
|
|
|
#define OPT_MASTER_LCORE "master-lcore"
|
2014-07-08 08:28:30 +00:00
|
|
|
OPT_MASTER_LCORE_NUM,
|
2017-10-06 07:45:29 +00:00
|
|
|
#define OPT_MBUF_POOL_OPS_NAME "mbuf-pool-ops-name"
|
|
|
|
OPT_MBUF_POOL_OPS_NAME_NUM,
|
2015-01-29 16:42:31 +00:00
|
|
|
#define OPT_PROC_TYPE "proc-type"
|
2014-09-22 08:38:00 +00:00
|
|
|
OPT_PROC_TYPE_NUM,
|
2015-01-29 16:42:31 +00:00
|
|
|
#define OPT_NO_HPET "no-hpet"
|
2014-09-22 08:38:00 +00:00
|
|
|
OPT_NO_HPET_NUM,
|
2015-01-29 16:42:31 +00:00
|
|
|
#define OPT_NO_HUGE "no-huge"
|
2014-09-22 08:38:00 +00:00
|
|
|
OPT_NO_HUGE_NUM,
|
2015-01-29 16:42:31 +00:00
|
|
|
#define OPT_NO_PCI "no-pci"
|
|
|
|
OPT_NO_PCI_NUM,
|
|
|
|
#define OPT_NO_SHCONF "no-shconf"
|
|
|
|
OPT_NO_SHCONF_NUM,
|
|
|
|
#define OPT_SOCKET_MEM "socket-mem"
|
2014-09-22 08:38:00 +00:00
|
|
|
OPT_SOCKET_MEM_NUM,
|
2015-01-29 16:42:31 +00:00
|
|
|
#define OPT_SYSLOG "syslog"
|
2014-09-22 08:38:00 +00:00
|
|
|
OPT_SYSLOG_NUM,
|
2015-01-29 16:42:31 +00:00
|
|
|
#define OPT_VDEV "vdev"
|
|
|
|
OPT_VDEV_NUM,
|
|
|
|
#define OPT_VFIO_INTR "vfio-intr"
|
2014-09-22 08:38:00 +00:00
|
|
|
OPT_VFIO_INTR_NUM,
|
2015-01-29 16:42:31 +00:00
|
|
|
#define OPT_VMWARE_TSC_MAP "vmware-tsc-map"
|
|
|
|
OPT_VMWARE_TSC_MAP_NUM,
|
2014-09-22 08:38:00 +00:00
|
|
|
OPT_LONG_MAX_NUM
|
|
|
|
};
|
2014-09-22 08:37:59 +00:00
|
|
|
|
|
|
|
extern const char eal_short_options[];
|
|
|
|
extern const struct option eal_long_options[];
|
|
|
|
|
2014-09-22 08:38:00 +00:00
|
|
|
int eal_parse_common_option(int opt, const char *argv,
|
2014-09-22 08:37:59 +00:00
|
|
|
struct internal_config *conf);
|
2017-08-02 17:10:22 +00:00
|
|
|
int eal_option_device_parse(void);
|
2014-11-20 21:57:22 +00:00
|
|
|
int eal_adjust_config(struct internal_config *internal_cfg);
|
2014-11-17 09:14:10 +00:00
|
|
|
int eal_check_common_options(struct internal_config *internal_cfg);
|
2014-09-22 08:37:59 +00:00
|
|
|
void eal_common_usage(void);
|
2014-11-20 21:57:22 +00:00
|
|
|
enum rte_proc_type_t eal_proc_type_detect(void);
|
2015-11-10 14:28:14 +00:00
|
|
|
int eal_plugins_init(void);
|
2014-11-21 14:26:17 +00:00
|
|
|
|
|
|
|
#endif /* EAL_OPTIONS_H */
|