提交 8b97ba29 编写于 作者: J John Ferlan

conf: Remove extraneous check in virDomainHostdevAssignAddress

Since the only way virDomainHostdevAssignAddress can be called is from
within virDomainHostdevDefParseXML when hostdev->source.subsys.type is
VIR_DOMAIN_HOSTDEV_SUBSYS_TYPE_SCSI, thus there's no need for redundancy.
Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
上级 88c4c32a
...@@ -5342,9 +5342,6 @@ virDomainHostdevAssignAddress(virDomainXMLOptionPtr xmlopt, ...@@ -5342,9 +5342,6 @@ virDomainHostdevAssignAddress(virDomainXMLOptionPtr xmlopt,
size_t i; size_t i;
int ret; int ret;
if (hostdev->source.subsys.type != VIR_DOMAIN_HOSTDEV_SUBSYS_TYPE_SCSI)
return -1;
for (i = 0; i < def->ncontrollers; i++) { for (i = 0; i < def->ncontrollers; i++) {
if (def->controllers[i]->type != VIR_DOMAIN_CONTROLLER_TYPE_SCSI) if (def->controllers[i]->type != VIR_DOMAIN_CONTROLLER_TYPE_SCSI)
continue; continue;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册