From 877eb21d5607e5097b8331e7a5b3d9714c0c5b91 Mon Sep 17 00:00:00 2001 From: Mark Cave-Ayland Date: Wed, 19 Sep 2018 18:20:58 +0100 Subject: scsi: move lsi53c8xx_create() callers to lsi53c8xx_handle_legacy_cmdline() MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit As part of commits a64aa5785d "hw: Deprecate -drive if=scsi with non-onboard HBAs" and b891538e81 "hw/ppc/prep: Fix implicit creation of "-drive if=scsi" devices" the lsi53c895a_create() and lsi53c810_create() functions were added to wrap pci_create_simple() and scsi_bus_legacy_handle_cmdline(). Unfortunately this prevents us from changing qdev properties on the device and/or changing the PCI configuration. By switching over to using the new lsi53c8xx_handle_legacy_cmdline() function then the caller can now configure and realize the LSI SCSI device exactly as required. Signed-off-by: Mark Cave-Ayland Reviewed-by: Thomas Huth Reviewed-by: Philippe Mathieu-Daudé Acked-by: Peter Maydell [arm parts] Signed-off-by: David Gibson --- hw/hppa/machine.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'hw/hppa/machine.c') diff --git a/hw/hppa/machine.c b/hw/hppa/machine.c index cf7c61c..0fb8fb8 100644 --- a/hw/hppa/machine.c +++ b/hw/hppa/machine.c @@ -59,6 +59,7 @@ static void machine_hppa_init(MachineState *machine) const char *kernel_filename = machine->kernel_filename; const char *kernel_cmdline = machine->kernel_cmdline; const char *initrd_filename = machine->initrd_filename; + DeviceState *dev; PCIBus *pci_bus; ISABus *isa_bus; qemu_irq rtc_irq, serial_irq; @@ -115,7 +116,8 @@ static void machine_hppa_init(MachineState *machine) } /* SCSI disk setup. */ - lsi53c895a_create(pci_bus); + dev = DEVICE(pci_create_simple(pci_bus, -1, "lsi53c895a")); + lsi53c8xx_handle_legacy_cmdline(dev); /* Network setup. e1000 is good enough, failing Tulip support. */ for (i = 0; i < nb_nics; i++) { -- cgit v1.1