[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[RFC PATCH 03/10] hw/i386/pc_piix: Allow for setting properties on "piix
From: |
Bernhard Beschow |
Subject: |
[RFC PATCH 03/10] hw/i386/pc_piix: Allow for setting properties on "piix3-ide" before realizing it |
Date: |
Mon, 27 Jun 2022 09:16:04 +0200 |
The next patch will introduce a quirk for user-created PIIX IDE devices for
backwards compatibility. In order to opt-in to new behavior for builtin
devices a property will need to be set until a deprecation period is over.
Signed-off-by: Bernhard Beschow <shentey@gmail.com>
---
hw/i386/pc_piix.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c
index 0fc2361ffe..2d146b19c0 100644
--- a/hw/i386/pc_piix.c
+++ b/hw/i386/pc_piix.c
@@ -252,7 +252,8 @@ static void pc_init1(MachineState *machine,
if (pcmc->pci_enabled) {
PCIDevice *dev;
- dev = pci_create_simple(pci_bus, piix3_devfn + 1, "piix3-ide");
+ dev = pci_new_multifunction(piix3_devfn + 1, false, "piix3-ide");
+ pci_realize_and_unref(dev, pci_bus, &error_fatal);
pci_ide_create_devs(dev);
idebus[0] = qdev_get_child_bus(&dev->qdev, "ide.0");
idebus[1] = qdev_get_child_bus(&dev->qdev, "ide.1");
--
2.36.1
- [RFC PATCH 00/10] Resolve isabus global, Bernhard Beschow, 2022/06/27
- [RFC PATCH 01/10] hw/ide/piix: Check for presence of ISABus before using it, Bernhard Beschow, 2022/06/27
- [RFC PATCH 02/10] Revert "hw/ide: Fix crash when plugging a piix3-ide device into the x-remote machine", Bernhard Beschow, 2022/06/27
- [RFC PATCH 06/10] hw/ide/ioport: Rename ide_init_ioport() to isa_ide_init_ioport(), Bernhard Beschow, 2022/06/27
- [RFC PATCH 05/10] hw/isa/isa-bus: assert() if isa_get_irq() gets passed a NULL ISADevice, Bernhard Beschow, 2022/06/27
- [RFC PATCH 04/10] hw/ide/piix: Avoid the isabus global when wiring ISA interrupts for internal devices, Bernhard Beschow, 2022/06/27
- [RFC PATCH 08/10] hw/ide/piix: Use pci_ide_init_ioport() rather than isa_ide_init_ioport(), Bernhard Beschow, 2022/06/27
- [RFC PATCH 09/10] hw/isa: Resolve unneeded usage of isabus global, Bernhard Beschow, 2022/06/27
- [RFC PATCH 10/10] hw/isa/isa-bus: Resolve isabus global, Bernhard Beschow, 2022/06/27
- [RFC PATCH 07/10] hw/pci/pci: Introduce pci_register_portio_list(), Bernhard Beschow, 2022/06/27
- [RFC PATCH 03/10] hw/i386/pc_piix: Allow for setting properties on "piix3-ide" before realizing it,
Bernhard Beschow <=