Commit 1e2b25ec authored by Ziye Yang's avatar Ziye Yang Committed by Changpeng Liu
Browse files

bdevperf: fix the reset testing failure issue.



Root cause: we did not check the status of the bdev_io
in bdevperf_verify_write_complete function.

So the fix is that: if the status is failed, we should
not do the read check again, but just complete this I/O.

Change-Id: I3dc796abe47c3f2e7eeb2b6eb0ebc0338122479d
Signed-off-by: default avatarZiye Yang <ziye.yang@intel.com>
Reviewed-on: https://review.gerrithub.io/419338


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarChunyang Hui <chunyang.hui@intel.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
Reviewed-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
parent 9ddf6438
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -362,8 +362,12 @@ static void
bdevperf_verify_write_complete(struct spdk_bdev_io *bdev_io, bool success,
			       void *cb_arg)
{
	if (success) {
		spdk_bdev_free_io(bdev_io);
		bdevperf_verify_submit_read(cb_arg);
	} else {
		bdevperf_complete(bdev_io, success, cb_arg);
	}
}

static __thread unsigned int seed = 0;