From 784553b681e4ef3387d352f84936bd70ddf8c892 Mon Sep 17 00:00:00 2001 From: Karol Latecki Date: Mon, 29 Jun 2020 12:32:38 +0200 Subject: [PATCH] test/iscsi: remove nvme bdev controller test case Removing verify_add_nvme_bdev_rpc_methods test from rpc_config.py. bdev_nvme_attach_controller RPC call is frequently used in a lot of other low-level test cases. Also this test case fails when run on a VM with multiple NVMe disks containing 0-namespace and OCSSD emualted NVMes, which is most probably a result of a very generic regex used to obtain NVMe BDFs. Signed-off-by: Karol Latecki Change-Id: I091cc7fa4b426784136cda7423f829dc4a82eae0 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/3111 Community-CI: Broadcom CI Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins Reviewed-by: Maciej Wawryk Reviewed-by: Jim Harris Reviewed-by: Tomasz Zawadzki --- test/iscsi_tgt/rpc_config/rpc_config.py | 23 ----------------------- 1 file changed, 23 deletions(-) diff --git a/test/iscsi_tgt/rpc_config/rpc_config.py b/test/iscsi_tgt/rpc_config/rpc_config.py index 324dacbbe..1d9c4275e 100755 --- a/test/iscsi_tgt/rpc_config/rpc_config.py +++ b/test/iscsi_tgt/rpc_config/rpc_config.py @@ -457,28 +457,6 @@ def verify_net_interface_add_delete_ip_address(rpc_py): print("verify_net_interface_add_delete_ip_address passed.") -def verify_add_nvme_bdev_rpc_methods(rpc_py): - rpc = spdk_rpc(rpc_py) - test_pass = 0 - output = check_output(["lspci", "-mm", "-nn"]) - addrs = re.findall(r'^([0-9]{2}:[0-9]{2}.[0-9]) "Non-Volatile memory controller \[0108\]".*-p02', output.decode(), re.MULTILINE) - for addr in addrs: - ctrlr_address = "-b Nvme{} -t pcie -a 0000:{}".format(addrs.index(addr), addr) - rpc.bdev_nvme_attach_controller(ctrlr_address) - print("add nvme device passed first time") - test_pass = 0 - try: - rpc.bdev_nvme_attach_controller(ctrlr_address) - except Exception as e: - print("add nvme device passed second time") - test_pass = 1 - pass - else: - pass - verify(test_pass == 1, 1, "add nvme device passed second time") - print("verify_add_nvme_bdev_rpc_methods passed.") - - if __name__ == "__main__": rpc_py = sys.argv[1] @@ -496,7 +474,6 @@ if __name__ == "__main__": verify_target_nodes_rpc_methods(rpc_py, rpc_param) verify_scsi_devices_rpc_methods(rpc_py) verify_iscsi_connection_rpc_methods(rpc_py) - verify_add_nvme_bdev_rpc_methods(rpc_py) except RpcException as e: print("{}. Exiting with status {}".format(e.message, e.retval)) raise e