diff options
author | Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> | 2020-03-07 09:13:12 +0000 |
---|---|---|
committer | John Snow <jsnow@redhat.com> | 2020-03-10 14:50:12 -0400 |
commit | 2529791082199b4134b37b5dbf78e33bc0c86e89 (patch) | |
tree | 039bb03d2d584c6f2a026ca2c34809c97fb57c29 | |
parent | 62b411bdaa9be7eee64e8ae12903bd3270c764cf (diff) |
dp264: use pci_create_simple() to initialise the cmd646 device
Remove the call to pci_cmd646_ide_init() since global device init functions
are deprecated in preference of using qdev directly.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-id: 20200307091313.24190-2-mark.cave-ayland@ilande.co.uk
Signed-off-by: John Snow <jsnow@redhat.com>
-rw-r--r-- | hw/alpha/dp264.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/hw/alpha/dp264.c b/hw/alpha/dp264.c index e5350a287f..27595767e5 100644 --- a/hw/alpha/dp264.c +++ b/hw/alpha/dp264.c @@ -16,6 +16,7 @@ #include "sysemu/sysemu.h" #include "hw/rtc/mc146818rtc.h" #include "hw/ide.h" +#include "hw/ide/pci.h" #include "hw/timer/i8254.h" #include "hw/isa/superio.h" #include "hw/dma/i8257.h" @@ -101,9 +102,12 @@ static void clipper_init(MachineState *machine) /* IDE disk setup. */ { DriveInfo *hd[MAX_IDE_BUS * MAX_IDE_DEVS]; + PCIDevice *pci_dev; + ide_drive_get(hd, ARRAY_SIZE(hd)); - pci_cmd646_ide_init(pci_bus, hd, 0); + pci_dev = pci_create_simple(pci_bus, -1, "cmd646-ide"); + pci_ide_create_devs(pci_dev, hd); } /* Load PALcode. Given that this is not "real" cpu palcode, |