examples/nvme/cmb_copy: exit the test tool if no controller found
fix issue #2200. Change-Id: I9d0374e56f199d562c48581ec6630547175d8627 Signed-off-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/9927 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
This commit is contained in:
parent
6000920e8c
commit
9f7cb6aa2d
@ -397,6 +397,11 @@ int main(int argc, char **argv)
|
||||
g_config.cmb.ctrlr = g_config.write.ctrlr;
|
||||
}
|
||||
|
||||
if (!g_config.read.ctrlr || !g_config.write.ctrlr) {
|
||||
fprintf(stderr, "No NVMe controller that support CMB was found!\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
/*
|
||||
* Call the cmb_copy() function which performs the CMB
|
||||
* based copy or returns an error code if it fails.
|
||||
|
Loading…
Reference in New Issue
Block a user