Commit a595959d authored by Jim Harris's avatar Jim Harris Committed by Tomasz Zawadzki
Browse files

test/nvme/abort: ensure admin queue is sized appropriately



This abort test app will send a lot of abort commands on
the admin queue.  The default admin queue size is
relatively small (32) so increase it if necessary to
account for the expected number of outstanding abort
commands as well as any extra admin commands that may
be sent during test execution such as Keep Alive.

Fixes issue #2048.

Signed-off-by: default avatarJim Harris <james.r.harris@intel.com>
Change-Id: I5f64b7fc72a028299b860f09e30d430a64c95d2a
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8812


Community-CI: Mellanox Build Bot
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarPaul Luse <paul.e.luse@intel.com>
Reviewed-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
Reviewed-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: default avatarAleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: default avatarDong Yi <dongx.yi@intel.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
parent 690783a3
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -846,6 +846,14 @@ static bool
probe_cb(void *cb_ctx, const struct spdk_nvme_transport_id *trid,
	 struct spdk_nvme_ctrlr_opts *opts)
{
	uint16_t min_aq_size;

	/* We need to make sure the admin queue is big enough to handle all of the aborts that
	 * will be sent by this test app.  We add a few extra entries to account for any admin
	 * commands other than the aborts. */
	min_aq_size = spdk_divide_round_up(g_queue_depth, g_abort_interval) + 8;
	opts->admin_queue_size = spdk_max(opts->admin_queue_size, min_aq_size);

	return true;
}