{"action":"created","issue":{"url":"https://api.github.com/repos/avocado-framework/avocado-vt/issues/196","labels_url":"https://api.github.com/repos/avocado-framework/avocado-vt/issues/196/labels{/name}","comments_url":"https://api.github.com/repos/avocado-framework/avocado-vt/issues/196/comments","events_url":"https://api.github.com/repos/avocado-framework/avocado-vt/issues/196/events","html_url":"https://github.com/avocado-framework/avocado-vt/issues/196","id":111638363,"number":196,"title":"Dual port SRIOV VF issue with NIC count","user":{"login":"bssrikanth","id":11852063,"avatar_url":"https://avatars.githubusercontent.com/u/11852063?v=3","gravatar_id":"","url":"https://api.github.com/users/bssrikanth","html_url":"https://github.com/bssrikanth","followers_url":"https://api.github.com/users/bssrikanth/followers","following_url":"https://api.github.com/users/bssrikanth/following{/other_user}","gists_url":"https://api.github.com/users/bssrikanth/gists{/gist_id}","starred_url":"https://api.github.com/users/bssrikanth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bssrikanth/subscriptions","organizations_url":"https://api.github.com/users/bssrikanth/orgs","repos_url":"https://api.github.com/users/bssrikanth/repos","events_url":"https://api.github.com/users/bssrikanth/events{/privacy}","received_events_url":"https://api.github.com/users/bssrikanth/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2015-10-15T15:09:20Z","updated_at":"2016-01-06T04:12:21Z","closed_at":null,"body":"Hi,\r\nI having been working on enabling SRIOV tests which are currently part of qemu tests on IBM PowerKVM. On IBM PowerKVM 3.1 [next GA] we support SRIOV on Mellanox Connectx cards. I have completed most of the patch work now, but not sure on one of the issue which I am facing requesting your suggestion.\r\n\r\nCurrently in qemu/libvirt tests in virttest/avocado-vt we assume that 'nics' param has 1-1 mapping with ports. That is if I have nic = \"nic1\" in my cfg file, it is assumed to have single port [which gets probed into guest as 1 iface interface].\r\n\r\nBut in case of Mellanox Connectx cards we have 2 Port Virtual Functions[VFs], I am having below in my configuration file:\r\n..\r\n    nics = \"nic1\"\r\n    pci_assignable_nic1 = vf\r\n    device_driver = vfio-pci\r\n..\r\nso 1 VFIO is passthroughed to guest in my case, which has 2 ports [2 ifaces] and this cause issue in current code where virttest assumes 1 nic = 1 port.\r\n\r\n    File \"/var/lib/libvirt/images/srikanth/fvt-pkvm-test/powerkvm-virt-test/virttest/utils_net.py\", line 2941, in update_mac_ip_address\r\n      vm.virtnet.set_mac_address(vlan, mac)\r\n    File \"/var/lib/libvirt/images/srikanth/fvt-pkvm-test/powerkvm-virt-test/virttest/utils_net.py\", line 2626, in set_mac_address\r\n      nic = self[nic_index_or_name]\r\n    File \"/var/lib/libvirt/images/srikanth/fvt-pkvm-test/powerkvm-virt-test/virttest/utils_net.py\", line 2093, in __getitem__\r\n      return super(VMNet, self).__getitem__(index_or_name)\r\n  IndexError: list index out of range\r\n\r\nI am thinking for a solution. Welcome if any of you have suggestions."},"comment":{"url":"https://api.github.com/repos/avocado-framework/avocado-vt/issues/comments/169215690","html_url":"https://github.com/avocado-framework/avocado-vt/issues/196#issuecomment-169215690","issue_url":"https://api.github.com/repos/avocado-framework/avocado-vt/issues/196","id":169215690,"user":{"login":"bssrikanth","id":11852063,"avatar_url":"https://avatars.githubusercontent.com/u/11852063?v=3","gravatar_id":"","url":"https://api.github.com/users/bssrikanth","html_url":"https://github.com/bssrikanth","followers_url":"https://api.github.com/users/bssrikanth/followers","following_url":"https://api.github.com/users/bssrikanth/following{/other_user}","gists_url":"https://api.github.com/users/bssrikanth/gists{/gist_id}","starred_url":"https://api.github.com/users/bssrikanth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bssrikanth/subscriptions","organizations_url":"https://api.github.com/users/bssrikanth/orgs","repos_url":"https://api.github.com/users/bssrikanth/repos","events_url":"https://api.github.com/users/bssrikanth/events{/privacy}","received_events_url":"https://api.github.com/users/bssrikanth/received_events","type":"User","site_admin":false},"created_at":"2016-01-06T04:12:21Z","updated_at":"2016-01-06T04:12:21Z","body":"Any thoughts on this one? the testing is done with above mentioned workaround."}}