diff options
author | Marcel Apfelbaum <marcel.a@redhat.com> | 2014-05-07 17:42:57 +0300 |
---|---|---|
committer | Andreas Färber <afaerber@suse.de> | 2014-05-28 17:35:01 +0200 |
commit | 3ef9622182e598392855931e7a0437d3855cef5e (patch) | |
tree | 87765046f480836eb65ecbcd293cade13518c62f /hw/arm/nseries.c | |
parent | 0380aef323154205a7d838fb9953423621290d41 (diff) | |
download | qemu-3ef9622182e598392855931e7a0437d3855cef5e.zip qemu-3ef9622182e598392855931e7a0437d3855cef5e.tar.gz qemu-3ef9622182e598392855931e7a0437d3855cef5e.tar.bz2 |
machine: Conversion of QEMUMachineInitArgs to MachineState
Total removal of QEMUMachineInitArgs struct. QEMUMachineInitArgs's fields
are copied into MachineState. Removed duplicated fields from MachineState.
All the other changes are only mechanical refactoring, no semantic changes.
Signed-off-by: Marcel Apfelbaum <marcel.a@redhat.com>
Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com> (s390)
Reviewed-by: Michael S. Tsirkin <mst@redhat.com> (PC)
[AF: Renamed ms -> machine, use MACHINE_GET_CLASS()]
Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'hw/arm/nseries.c')
-rw-r--r-- | hw/arm/nseries.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/hw/arm/nseries.c b/hw/arm/nseries.c index c28f895..82772c6 100644 --- a/hw/arm/nseries.c +++ b/hw/arm/nseries.c @@ -1278,14 +1278,14 @@ static int n810_atag_setup(const struct arm_boot_info *info, void *p) return n8x0_atag_setup(p, 810); } -static void n8x0_init(QEMUMachineInitArgs *args, +static void n8x0_init(MachineState *machine, struct arm_boot_info *binfo, int model) { MemoryRegion *sysmem = get_system_memory(); struct n800_s *s = (struct n800_s *) g_malloc0(sizeof(*s)); int sdram_size = binfo->ram_size; - s->mpu = omap2420_mpu_init(sysmem, sdram_size, args->cpu_model); + s->mpu = omap2420_mpu_init(sysmem, sdram_size, machine->cpu_model); /* Setup peripherals * @@ -1329,18 +1329,18 @@ static void n8x0_init(QEMUMachineInitArgs *args, n8x0_usb_setup(s); } - if (args->kernel_filename) { + if (machine->kernel_filename) { /* Or at the linux loader. */ - binfo->kernel_filename = args->kernel_filename; - binfo->kernel_cmdline = args->kernel_cmdline; - binfo->initrd_filename = args->initrd_filename; + binfo->kernel_filename = machine->kernel_filename; + binfo->kernel_cmdline = machine->kernel_cmdline; + binfo->initrd_filename = machine->initrd_filename; arm_load_kernel(s->mpu->cpu, binfo); qemu_register_reset(n8x0_boot_init, s); } if (option_rom[0].name && - (args->boot_order[0] == 'n' || !args->kernel_filename)) { + (machine->boot_order[0] == 'n' || !machine->kernel_filename)) { uint8_t nolo_tags[0x10000]; /* No, wait, better start at the ROM. */ s->mpu->cpu->env.regs[15] = OMAP2_Q2_BASE + 0x400000; @@ -1382,14 +1382,14 @@ static struct arm_boot_info n810_binfo = { .atag_board = n810_atag_setup, }; -static void n800_init(QEMUMachineInitArgs *args) +static void n800_init(MachineState *machine) { - return n8x0_init(args, &n800_binfo, 800); + return n8x0_init(machine, &n800_binfo, 800); } -static void n810_init(QEMUMachineInitArgs *args) +static void n810_init(MachineState *machine) { - return n8x0_init(args, &n810_binfo, 810); + return n8x0_init(machine, &n810_binfo, 810); } static QEMUMachine n800_machine = { |