On 25/10/2023 15:50, David Woodhouse wrote:
From: David Woodhouse <d...@amazon.co.uk>
To support Xen guests using the Q35 chipset, the unplug protocol needs
to also remove AHCI disks.
Make pci_xen_ide_unplug() more generic, iterating over the children
of the PCI device and destroying the "ide-hd" devices. That works the
same for both AHCI and IDE, as does the detection of the primary disk
as unit 0 on the bus named "ide.0".
Then pci_xen_ide_unplug() can be used for both AHCI and IDE devices.
Signed-off-by: David Woodhouse <d...@amazon.co.uk>
---
hw/i386/xen/xen_platform.c | 68 +++++++++++++++++++++++++-------------
1 file changed, 45 insertions(+), 23 deletions(-)
Reviewed-by: Paul Durrant <p...@xen.org>