Commit a6658c54 authored by Sarvesh Lanke's avatar Sarvesh Lanke Committed by Jim Harris
Browse files

env_dpdk: Add an option to run without huge pages.



This change adds a new SPDK commandline parameter "--no-huge", which
allows to run SPDK without huge pages. This is useful to run NVMf
with tcp/ip configuration.
Tested this by running a NVMf test over TCP between target and host.
Configured the NVMf target to run SPDK without hugepages by passing
the "no-huge" parameter. Then configured the NVMf host and connected
it to the target over TCP transport and verified that the subsystem
is getting exposed.
Modified existing NVMf tests to accept "--no-hugepages" parameter and
verified functionality by running those tests.

Fixes #2973

Change-Id: I68773bc6c818e5fc5173142213c3928fcbca96c8
Signed-off-by: default avatarSarvesh Lanke <sarvesh.lanke@nutanix.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/20171


Reviewed-by: default avatarJim Harris <jim.harris@samsung.com>
Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: default avatarMichal Berger <michal.berger@intel.com>
Community-CI: Mellanox Build Bot
Reviewed-by: default avatarAbhineet Pandey <abhineet.pandey@nutanix.com>
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
parent dbadf72e
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -20,6 +20,10 @@ Added support for `SBC WRITE SAME 10` and `SBC WRITE SAME 16`.

A new transport option `rdma_max_cq_size` was added to limit indefinite growth of CQ size.

### env

Added SPDK commandline parameter --no-huge, which enables SPDK to run without hugepages.

## v23.09

### accel
+1 −0
Original line number Diff line number Diff line
@@ -55,6 +55,7 @@ struct spdk_env_opts {
	bool			no_pci;
	bool			hugepage_single_segments;
	bool			unlink_hugepage;
	bool			no_huge;
	size_t			num_pci_addr;
	const char		*hugedir;
	struct spdk_pci_addr	*pci_blocked;
+3 −2
Original line number Diff line number Diff line
@@ -89,9 +89,10 @@ struct spdk_app_opts {
	bool			no_pci;
	bool			hugepage_single_segments;
	bool			unlink_hugepage;
	bool			no_huge;

	/* Hole at bytes 83-85. */
	uint8_t			reserved83[5];
	/* Hole at bytes 84-87. */
	uint8_t			reserved84[4];

	const char		*hugedir;
	enum spdk_log_level	print_level;
+1 −1
Original line number Diff line number Diff line
@@ -6,7 +6,7 @@
SPDK_ROOT_DIR := $(abspath $(CURDIR)/../..)
include $(SPDK_ROOT_DIR)/mk/spdk.common.mk

SO_VER := 12
SO_VER := 13
SO_MINOR := 0

CFLAGS += $(ENV_CFLAGS)
+5 −0
Original line number Diff line number Diff line
@@ -52,4 +52,9 @@ void vtophys_pci_device_added(struct rte_pci_device *pci_device);
 */
void vtophys_pci_device_removed(struct rte_pci_device *pci_device);

/**
 * Disable huge page usage based on SPDK command line option --no-huge.
 */
void mem_disable_huge_pages(void);

#endif
Loading