mirror of
https://github.com/xemu-project/xemu.git
synced 2025-04-02 11:11:48 -04:00
shpc: unparent device before free
Recent core change removed unparent so we need to do this in all callers now. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
8cc9b43f7c
commit
e9adf2605d
1 changed files with 1 additions and 0 deletions
|
@ -253,6 +253,7 @@ static void shpc_free_devices_in_slot(SHPCDevice *shpc, int slot)
|
|||
++devfn) {
|
||||
PCIDevice *affected_dev = shpc->sec_bus->devices[devfn];
|
||||
if (affected_dev) {
|
||||
object_unparent(OBJECT(affected_dev));
|
||||
qdev_free(&affected_dev->qdev);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue