summary refs log tree commit diff stats
path: root/hw/ide/piix.c
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2017-02-03 12:31:40 +0000
committerPeter Maydell <peter.maydell@linaro.org>2017-02-03 12:31:40 +0000
commit4100a344eb3d50d88f9da85cae334afc47aee134 (patch)
tree42156e1fd553310e3735f16f92e3d3930bce677b /hw/ide/piix.c
parent77e217d1bf63c4d042c17f7d55b0816a7d386bf3 (diff)
parente9dcbc86d614018923e26e31319b0a54c9e5abac (diff)
downloadfocaccia-qemu-4100a344eb3d50d88f9da85cae334afc47aee134.tar.gz
focaccia-qemu-4100a344eb3d50d88f9da85cae334afc47aee134.zip
Merge remote-tracking branch 'remotes/sstabellini/tags/xen-20170202' into staging
Xen 2017/02/02

# gpg: Signature made Thu 02 Feb 2017 18:26:58 GMT
# gpg:                using RSA key 0x894F8F4870E1AE90
# gpg: Good signature from "Stefano Stabellini <sstabellini@kernel.org>"
# gpg:                 aka "Stefano Stabellini <stefano.stabellini@eu.citrix.com>"
# Primary key fingerprint: D04E 33AB A51F 67BA 07D3  0AEA 894F 8F48 70E1 AE90

* remotes/sstabellini/tags/xen-20170202:
  xen: use qdev_unplug() instead of g_free() in xen_pv_find_xendev()
  MAINTAINERS: Update xen-devel mailing list address
  xen-platform: add missing disk unplug option
  xen-platform: add support for unplugging NVMe disks...
  xen-platform: re-structure unplug_disks

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/ide/piix.c')
-rw-r--r--hw/ide/piix.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/ide/piix.c b/hw/ide/piix.c
index d5777fd0b3..7e2d76705d 100644
--- a/hw/ide/piix.c
+++ b/hw/ide/piix.c
@@ -165,7 +165,7 @@ static void pci_piix_ide_realize(PCIDevice *dev, Error **errp)
     pci_piix_init_ports(d);
 }
 
-int pci_piix3_xen_ide_unplug(DeviceState *dev)
+int pci_piix3_xen_ide_unplug(DeviceState *dev, bool aux)
 {
     PCIIDEState *pci_ide;
     DriveInfo *di;
@@ -174,7 +174,7 @@ int pci_piix3_xen_ide_unplug(DeviceState *dev)
 
     pci_ide = PCI_IDE(dev);
 
-    for (i = 0; i < 4; i++) {
+    for (i = aux ? 1 : 0; i < 4; i++) {
         di = drive_get_by_index(IF_IDE, i);
         if (di != NULL && !di->media_cd) {
             BlockBackend *blk = blk_by_legacy_dinfo(di);