test/bdevperf: apply g_abort to job->abort
Also give an error log when the g_timeout_in_sec parameter isn't set but g_abort is set. Fix issue #2643. Change-Id: Iafd9e94952319b89891e37bc6e9e0db6892ddd7d Signed-off-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/14435 Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Shuhei Matsumoto <smatsumoto@nvidia.com> Reviewed-by: Jim Harris <james.r.harris@intel.com>
This commit is contained in:
parent
c6824c7944
commit
6045458cb6
@ -1283,6 +1283,7 @@ bdevperf_construct_job(struct spdk_bdev *bdev, struct job_config *config,
|
||||
job->bdev = bdev;
|
||||
job->io_size_blocks = job->io_size / data_block_size;
|
||||
job->buf_size = job->io_size_blocks * block_size;
|
||||
job->abort = g_abort;
|
||||
job_init_rw(job, config->rw);
|
||||
|
||||
if ((job->io_size % data_block_size) != 0) {
|
||||
@ -2070,6 +2071,10 @@ verify_test_params(struct spdk_app_opts *opts)
|
||||
goto out;
|
||||
}
|
||||
|
||||
if (g_abort && !g_timeout_in_sec) {
|
||||
printf("Timeout must be set for abort option, Ignoring g_abort\n");
|
||||
}
|
||||
|
||||
if (g_show_performance_ema_period > 0 &&
|
||||
g_show_performance_real_time == 0) {
|
||||
fprintf(stderr, "-P option must be specified with -S option\n");
|
||||
|
Loading…
Reference in New Issue
Block a user