aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--hw/arm/cubieboard.c2
-rw-r--r--hw/arm/integratorcp.c2
-rw-r--r--hw/arm/msf2-som.c2
-rw-r--r--hw/arm/orangepi.c2
-rw-r--r--hw/arm/raspi.c2
-rw-r--r--hw/arm/realview.c2
-rw-r--r--hw/arm/sabrelite.c2
-rw-r--r--hw/misc/sifive_u_otp.c4
-rw-r--r--hw/riscv/microchip_pfsoc.c2
-rw-r--r--hw/riscv/sifive_u.c2
-rw-r--r--hw/sparc64/niagara.c2
11 files changed, 12 insertions, 12 deletions
diff --git a/hw/arm/cubieboard.c b/hw/arm/cubieboard.c
index 294ba5d..5e3372a 100644
--- a/hw/arm/cubieboard.c
+++ b/hw/arm/cubieboard.c
@@ -81,7 +81,7 @@ static void cubieboard_init(MachineState *machine)
}
/* Retrieve SD bus */
- di = drive_get_next(IF_SD);
+ di = drive_get(IF_SD, 0, 0);
blk = di ? blk_by_legacy_dinfo(di) : NULL;
bus = qdev_get_child_bus(DEVICE(a10), "sd-bus");
diff --git a/hw/arm/integratorcp.c b/hw/arm/integratorcp.c
index 16e8985..b109ece 100644
--- a/hw/arm/integratorcp.c
+++ b/hw/arm/integratorcp.c
@@ -649,7 +649,7 @@ static void integratorcp_init(MachineState *machine)
qdev_get_gpio_in_named(icp, ICP_GPIO_MMC_WPROT, 0));
qdev_connect_gpio_out_named(dev, "card-inserted", 0,
qdev_get_gpio_in_named(icp, ICP_GPIO_MMC_CARDIN, 0));
- dinfo = drive_get_next(IF_SD);
+ dinfo = drive_get(IF_SD, 0, 0);
if (dinfo) {
DeviceState *card;
diff --git a/hw/arm/msf2-som.c b/hw/arm/msf2-som.c
index 396e8b9..d9f8816 100644
--- a/hw/arm/msf2-som.c
+++ b/hw/arm/msf2-som.c
@@ -45,7 +45,7 @@ static void emcraft_sf2_s2s010_init(MachineState *machine)
DeviceState *spi_flash;
MSF2State *soc;
MachineClass *mc = MACHINE_GET_CLASS(machine);
- DriveInfo *dinfo = drive_get_next(IF_MTD);
+ DriveInfo *dinfo = drive_get(IF_MTD, 0, 0);
qemu_irq cs_line;
BusState *spi_bus;
MemoryRegion *sysmem = get_system_memory();
diff --git a/hw/arm/orangepi.c b/hw/arm/orangepi.c
index 0cf9895..e796382 100644
--- a/hw/arm/orangepi.c
+++ b/hw/arm/orangepi.c
@@ -85,7 +85,7 @@ static void orangepi_init(MachineState *machine)
qdev_realize(DEVICE(h3), NULL, &error_abort);
/* Retrieve SD bus */
- di = drive_get_next(IF_SD);
+ di = drive_get(IF_SD, 0, 0);
blk = di ? blk_by_legacy_dinfo(di) : NULL;
bus = qdev_get_child_bus(DEVICE(h3), "sd-bus");
diff --git a/hw/arm/raspi.c b/hw/arm/raspi.c
index 146d353..b4dd6c1 100644
--- a/hw/arm/raspi.c
+++ b/hw/arm/raspi.c
@@ -284,7 +284,7 @@ static void raspi_machine_init(MachineState *machine)
qdev_realize(DEVICE(&s->soc), NULL, &error_fatal);
/* Create and plug in the SD cards */
- di = drive_get_next(IF_SD);
+ di = drive_get(IF_SD, 0, 0);
blk = di ? blk_by_legacy_dinfo(di) : NULL;
bus = qdev_get_child_bus(DEVICE(&s->soc), "sd-bus");
if (bus == NULL) {
diff --git a/hw/arm/realview.c b/hw/arm/realview.c
index 1c54316..ddc70b5 100644
--- a/hw/arm/realview.c
+++ b/hw/arm/realview.c
@@ -237,7 +237,7 @@ static void realview_init(MachineState *machine,
qemu_irq_invert(qdev_get_gpio_in(gpio2, 0)));
qdev_connect_gpio_out_named(dev, "card-read-only", 0, mmc_irq[0]);
qdev_connect_gpio_out_named(dev, "card-inserted", 0, mmc_irq[1]);
- dinfo = drive_get_next(IF_SD);
+ dinfo = drive_get(IF_SD, 0, 0);
if (dinfo) {
DeviceState *card;
diff --git a/hw/arm/sabrelite.c b/hw/arm/sabrelite.c
index 553608e..cce49aa 100644
--- a/hw/arm/sabrelite.c
+++ b/hw/arm/sabrelite.c
@@ -76,7 +76,7 @@ static void sabrelite_init(MachineState *machine)
if (spi_bus) {
DeviceState *flash_dev;
qemu_irq cs_line;
- DriveInfo *dinfo = drive_get_next(IF_MTD);
+ DriveInfo *dinfo = drive_get(IF_MTD, 0, 0);
flash_dev = qdev_new("sst25vf016b");
if (dinfo) {
diff --git a/hw/misc/sifive_u_otp.c b/hw/misc/sifive_u_otp.c
index 52fdb75..6d5f84e 100644
--- a/hw/misc/sifive_u_otp.c
+++ b/hw/misc/sifive_u_otp.c
@@ -209,9 +209,9 @@ static void sifive_u_otp_realize(DeviceState *dev, Error **errp)
TYPE_SIFIVE_U_OTP, SIFIVE_U_OTP_REG_SIZE);
sysbus_init_mmio(SYS_BUS_DEVICE(dev), &s->mmio);
- dinfo = drive_get_next(IF_PFLASH);
+ dinfo = drive_get(IF_PFLASH, 0, 0);
if (!dinfo) {
- dinfo = drive_get_next(IF_NONE);
+ dinfo = drive_get(IF_NONE, 0, 0);
if (dinfo) {
warn_report("using \"-drive if=none\" for the OTP is deprecated, "
"use \"-drive if=pflash\" instead.");
diff --git a/hw/riscv/microchip_pfsoc.c b/hw/riscv/microchip_pfsoc.c
index 57d779f..d1d065e 100644
--- a/hw/riscv/microchip_pfsoc.c
+++ b/hw/riscv/microchip_pfsoc.c
@@ -458,7 +458,7 @@ static void microchip_icicle_kit_machine_init(MachineState *machine)
target_ulong firmware_end_addr, kernel_start_addr;
uint64_t kernel_entry;
uint32_t fdt_load_addr;
- DriveInfo *dinfo = drive_get_next(IF_SD);
+ DriveInfo *dinfo = drive_get(IF_SD, 0, 0);
/* Sanity check on RAM size */
if (machine->ram_size < mc->default_ram_size) {
diff --git a/hw/riscv/sifive_u.c b/hw/riscv/sifive_u.c
index a4ecada..aa74e67 100644
--- a/hw/riscv/sifive_u.c
+++ b/hw/riscv/sifive_u.c
@@ -672,7 +672,7 @@ static void sifive_u_machine_init(MachineState *machine)
/* Connect an SPI flash to SPI0 */
flash_dev = qdev_new("is25wp256");
- dinfo = drive_get_next(IF_MTD);
+ dinfo = drive_get(IF_MTD, 0, 0);
if (dinfo) {
qdev_prop_set_drive_err(flash_dev, "drive",
blk_by_legacy_dinfo(dinfo),
diff --git a/hw/sparc64/niagara.c b/hw/sparc64/niagara.c
index f3e42d0..ccad2c4 100644
--- a/hw/sparc64/niagara.c
+++ b/hw/sparc64/niagara.c
@@ -98,7 +98,7 @@ static void add_rom_or_fail(const char *file, const hwaddr addr)
static void niagara_init(MachineState *machine)
{
NiagaraBoardState *s = g_new(NiagaraBoardState, 1);
- DriveInfo *dinfo = drive_get_next(IF_PFLASH);
+ DriveInfo *dinfo = drive_get(IF_PFLASH, 0, 0);
MemoryRegion *sysmem = get_system_memory();
/* init CPUs */