projects
/
users
/
dwmw2
/
qemu.git
/ commitdiff
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
19c45c0
)
Revert "pcie_sriov: Do not manually unrealize"
author
Michael S. Tsirkin <mst@redhat.com>
Thu, 1 Aug 2024 07:44:45 +0000
(
03:44
-0400)
committer
Michael S. Tsirkin <mst@redhat.com>
Thu, 1 Aug 2024 08:32:00 +0000
(
04:32
-0400)
This reverts commit
c613ad25125bf3016aa8f81ce170f5ac91d2379f
.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/pci/pcie_sriov.c
patch
|
blob
|
history
diff --git
a/hw/pci/pcie_sriov.c
b/hw/pci/pcie_sriov.c
index 499becd5273f8423e05813379b04645d459cfa91..e9b23221d713c0802c2fd91f83eb925a68031c2c 100644
(file)
--- a/
hw/pci/pcie_sriov.c
+++ b/
hw/pci/pcie_sriov.c
@@
-204,7
+204,11
@@
static void unregister_vfs(PCIDevice *dev)
trace_sriov_unregister_vfs(dev->name, PCI_SLOT(dev->devfn),
PCI_FUNC(dev->devfn), num_vfs);
for (i = 0; i < num_vfs; i++) {
+ Error *err = NULL;
PCIDevice *vf = dev->exp.sriov_pf.vf[i];
+ if (!object_property_set_bool(OBJECT(vf), "realized", false, &err)) {
+ error_reportf_err(err, "Failed to unplug: ");
+ }
object_unparent(OBJECT(vf));
object_unref(OBJECT(vf));
}