test/nvme: Move ASAN check out of for loop
Check whether ASAN is enabled up front, before entering the loop over all PCI devices. Change-Id: Iede6a0466014745b77190b79fb8255e7b61bb260 Signed-off-by: yidong0635 <dongx.yi@intel.com> Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/453512 Reviewed-by: Seth Howell <seth.howell5141@gmail.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
e560d53c12
commit
62966da34c
@ -169,19 +169,15 @@ if [ `uname` = Linux ]; then
|
|||||||
trap - SIGINT SIGTERM EXIT
|
trap - SIGINT SIGTERM EXIT
|
||||||
kill_stub
|
kill_stub
|
||||||
fi
|
fi
|
||||||
PLUGIN_DIR=$rootdir/examples/nvme/fio_plugin
|
|
||||||
|
|
||||||
if [ -d /usr/src/fio ]; then
|
if [ -d /usr/src/fio ] && [ $SPDK_RUN_ASAN -eq 0 ]; then
|
||||||
|
# Only test when ASAN is not enabled. If ASAN is enabled, we cannot test.
|
||||||
timing_enter fio_plugin
|
timing_enter fio_plugin
|
||||||
|
PLUGIN_DIR=$rootdir/examples/nvme/fio_plugin
|
||||||
for bdf in $(iter_pci_class_code 01 08 02); do
|
for bdf in $(iter_pci_class_code 01 08 02); do
|
||||||
# Only test when ASAN is not enabled. If ASAN is enabled, we cannot test.
|
LD_PRELOAD=$PLUGIN_DIR/fio_plugin /usr/src/fio/fio $PLUGIN_DIR/example_config.fio --filename="trtype=PCIe traddr=${bdf//:/.} ns=1"
|
||||||
if [ $SPDK_RUN_ASAN -eq 0 ]; then
|
report_test_completion "bdev_fio"
|
||||||
LD_PRELOAD=$PLUGIN_DIR/fio_plugin /usr/src/fio/fio $PLUGIN_DIR/example_config.fio --filename="trtype=PCIe traddr=${bdf//:/.} ns=1"
|
|
||||||
report_test_completion "bdev_fio"
|
|
||||||
fi
|
|
||||||
break
|
|
||||||
done
|
done
|
||||||
|
|
||||||
timing_exit fio_plugin
|
timing_exit fio_plugin
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user