From: Daniel Wagner Date: Mon, 12 Feb 2024 10:40:44 +0000 (+0100) Subject: nvme/rc: do not issue warnings on cleanup when using fc transport X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=e8f53e8380b7a2a9b26f782a1e313b6d7dd1f7b6;p=users%2Fsagi%2Fblktests.git nvme/rc: do not issue warnings on cleanup when using fc transport When running the tests with FC as transport and the udev auto connect enabled, discovery controllers are created and destroyed while the tests are running. The cleanup code expects that all devices are under blktests control, but this isn't the case. So just disable the warning as it is reporting a lot of false positives. Signed-off-by: Daniel Wagner Signed-off-by: Shin'ichiro Kawasaki --- diff --git a/tests/nvme/rc b/tests/nvme/rc index 9cc83af..ca6a284 100644 --- a/tests/nvme/rc +++ b/tests/nvme/rc @@ -352,7 +352,10 @@ _cleanup_nvmet() { dev="$(basename "$dev")" transport="$(cat "/sys/class/nvme/${dev}/transport" 2>/dev/null)" if [[ "$transport" == "${nvme_trtype}" ]]; then - echo "WARNING: Test did not clean up ${nvme_trtype} device: ${dev}" + # if udev auto connect is enabled for FC we get false positives + if [[ "$transport" != "fc" ]]; then + echo "WARNING: Test did not clean up ${nvme_trtype} device: ${dev}" + fi _nvme_disconnect_ctrl "${dev}" fi done