[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v6 07/15] pcie_sriov: Do not manually unrealize
From: |
Akihiko Odaki |
Subject: |
[PATCH v6 07/15] pcie_sriov: Do not manually unrealize |
Date: |
Tue, 20 Feb 2024 21:24:42 +0900 |
A device gets automatically unrealized when being unparented.
Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
---
hw/pci/pcie_sriov.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/hw/pci/pcie_sriov.c b/hw/pci/pcie_sriov.c
index e9b23221d713..8b1fd2a89ad7 100644
--- a/hw/pci/pcie_sriov.c
+++ b/hw/pci/pcie_sriov.c
@@ -17,7 +17,6 @@
#include "hw/qdev-properties.h"
#include "qemu/error-report.h"
#include "qemu/range.h"
-#include "qapi/error.h"
#include "trace.h"
static PCIDevice *register_vf(PCIDevice *pf, int devfn,
@@ -204,11 +203,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));
}
--
2.43.1
- Re: [PATCH v6 01/15] hw/nvme: Use pcie_sriov_num_vfs(), (continued)
[PATCH v6 02/15] pcie_sriov: Validate NumVFs, Akihiko Odaki, 2024/02/20
[PATCH v6 04/15] pcie_sriov: Do not reset NumVFs after disabling VFs, Akihiko Odaki, 2024/02/20
[PATCH v6 05/15] hw/pci: Always call pcie_sriov_pf_reset(), Akihiko Odaki, 2024/02/20
[PATCH v6 08/15] pcie_sriov: Reuse SR-IOV VF device instances, Akihiko Odaki, 2024/02/20
[PATCH v6 03/15] pcie_sriov: Reset SR-IOV extended capability, Akihiko Odaki, 2024/02/20
[PATCH v6 06/15] hw/pci: Rename has_power to enabled, Akihiko Odaki, 2024/02/20
[PATCH v6 09/15] pcie_sriov: Release VFs failed to realize, Akihiko Odaki, 2024/02/20
[PATCH v6 07/15] pcie_sriov: Do not manually unrealize,
Akihiko Odaki <=
[PATCH v6 11/15] pcie_sriov: Register VFs after migration, Akihiko Odaki, 2024/02/20
[PATCH v6 10/15] pcie_sriov: Remove num_vfs from PCIESriovPF, Akihiko Odaki, 2024/02/20
[PATCH v6 12/15] hw/pci: Use -1 as a default value for rombar, Akihiko Odaki, 2024/02/20
[PATCH v6 13/15] hw/pci: Determine if rombar is explicitly enabled, Akihiko Odaki, 2024/02/20
[PATCH v6 14/15] vfio: Avoid inspecting option QDict for rombar, Akihiko Odaki, 2024/02/20