mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
qemu: Report error on failure to set isolation group
This is more user-friendly because the error will be displayed directly instead of being buried in the log. Signed-off-by: Andrea Bolognani <abologna@redhat.com> Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
This commit is contained in:
parent
941ec9b6a7
commit
ed9db36b42
@ -1012,10 +1012,11 @@ qemuDomainFillDeviceIsolationGroup(virDomainDefPtr def,
|
|||||||
tmp = virPCIDeviceAddressGetIOMMUGroupNum(hostAddr);
|
tmp = virPCIDeviceAddressGetIOMMUGroupNum(hostAddr);
|
||||||
|
|
||||||
if (tmp < 0) {
|
if (tmp < 0) {
|
||||||
VIR_WARN("Can't look up isolation group for host device "
|
virReportError(VIR_ERR_INTERNAL_ERROR,
|
||||||
"%04x:%02x:%02x.%x",
|
_("Can't look up isolation group for host device "
|
||||||
hostAddr->domain, hostAddr->bus,
|
"%04x:%02x:%02x.%x"),
|
||||||
hostAddr->slot, hostAddr->function);
|
hostAddr->domain, hostAddr->bus,
|
||||||
|
hostAddr->slot, hostAddr->function);
|
||||||
goto cleanup;
|
goto cleanup;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1056,9 +1057,11 @@ qemuDomainFillDeviceIsolationGroup(virDomainDefPtr def,
|
|||||||
tmp = qemuDomainFindUnusedIsolationGroup(def);
|
tmp = qemuDomainFindUnusedIsolationGroup(def);
|
||||||
|
|
||||||
if (tmp == 0) {
|
if (tmp == 0) {
|
||||||
VIR_WARN("Can't obtain usable isolation group for interface "
|
virReportError(VIR_ERR_INTERNAL_ERROR,
|
||||||
"configured to use hostdev-backed network '%s'",
|
_("Can't obtain usable isolation group for "
|
||||||
iface->data.network.name);
|
"interface configured to use hostdev-backed "
|
||||||
|
"network '%s'"),
|
||||||
|
iface->data.network.name);
|
||||||
goto cleanup;
|
goto cleanup;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user