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

event: require opts->name is set



This has been implicitly required before, and all
in-tree apps (except accel_perf) set it, so let's
explicitly require it.  This name gets used for
things like the shm name for spdk trace event file.

While here, add the name for accel_perf.

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


Community-CI: Mellanox Build Bot
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarMichal Berger <michal.berger@intel.com>
Reviewed-by: default avatarDong Yi <dongx.yi@intel.com>
Reviewed-by: default avatarAleksey Marchuk <alexeymar@nvidia.com>
Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
parent fa09c9ac
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -780,6 +780,7 @@ main(int argc, char **argv)

	pthread_mutex_init(&g_workers_lock, NULL);
	spdk_app_opts_init(&opts, sizeof(opts));
	opts.name = "accel_perf";
	opts.reactor_mask = "0x1";
	if (spdk_app_parse_args(argc, argv, &opts, "a:C:o:q:t:yw:P:f:T:", NULL, parse_args,
				usage) != SPDK_APP_PARSE_ARGS_SUCCESS) {
+5 −0
Original line number Diff line number Diff line
@@ -523,6 +523,11 @@ spdk_app_start(struct spdk_app_opts *opts_user, spdk_msg_fn start_fn,
		return 1;
	}

	if (opts_user->name == NULL) {
		SPDK_ERRLOG("spdk_app_opts::name not specified\n");
		return 1;
	}

	app_copy_opts(opts, opts_user, opts_user->opts_size);

	if (!start_fn) {