diff options
author | Akihiko Odaki <akihiko.odaki@daynix.com> | 2025-01-16 18:00:57 +0900 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2025-02-20 18:23:19 -0500 |
commit | e8b827ce7c4bf9a334c46282779f234d1a011cd1 (patch) | |
tree | 7e5591a7d3d9f382d347663b4b36d6422c8e150f /hw/pci | |
parent | 2c968f465392316d09e44f4a9f7e378999e5c011 (diff) | |
download | qemu-e8b827ce7c4bf9a334c46282779f234d1a011cd1.zip qemu-e8b827ce7c4bf9a334c46282779f234d1a011cd1.tar.gz qemu-e8b827ce7c4bf9a334c46282779f234d1a011cd1.tar.bz2 |
pcie_sriov: Do not manually unrealize
A device gets automatically unrealized when being unparented.
Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
Message-Id: <20250116-reuse-v20-6-7cb370606368@daynix.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Diffstat (limited to 'hw/pci')
-rw-r--r-- | hw/pci/pcie_sriov.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/hw/pci/pcie_sriov.c b/hw/pci/pcie_sriov.c index e9b2322..499becd 100644 --- a/hw/pci/pcie_sriov.c +++ b/hw/pci/pcie_sriov.c @@ -204,11 +204,7 @@ 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)); } |