Commit a7d59c9d authored by Shuhei Matsumoto's avatar Shuhei Matsumoto Committed by Tomasz Zawadzki
Browse files

lib/nvmf: Add three variables to spdk_nvmf_request to avoid temp context for abort operation



Add three variables, poller, timeout_tsc, and req_to_abort to
struct spdk_nvmf_request to wait until the request to abort is
abortable without using any dynamically allocated context.

struct spdk_nvmf_request is already very large (968 bytes), and
the pahole tool checked these variables did not create any extra hole.

Poller pointer and timeout value are usable for other potential
cases, and so use generic names.

Signed-off-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: I7202ade181365ab586d8c30383b3ea0fef82dcff
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/3260


Community-CI: Mellanox Build Bot
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Reviewed-by: default avatarAleksey Marchuk <alexeymar@mellanox.com>
parent 604b4503
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -94,6 +94,9 @@ struct spdk_nvmf_request {
	struct spdk_nvmf_dif_info	dif;
	spdk_nvmf_nvme_passthru_cmd_cb	cmd_cb_fn;
	struct spdk_nvmf_request	*first_fused_req;
	struct spdk_nvmf_request	*req_to_abort;
	struct spdk_poller		*poller;
	uint64_t			timeout_tsc;

	STAILQ_ENTRY(spdk_nvmf_request)	buf_link;
	TAILQ_ENTRY(spdk_nvmf_request)	link;