diff options
author | Eduardo Habkost <ehabkost@redhat.com> | 2015-09-04 15:37:08 -0300 |
---|---|---|
committer | Andreas Färber <afaerber@suse.de> | 2015-09-19 16:40:15 +0200 |
commit | e264d29de28c5b0be3d063307ce9fb613b427cc3 (patch) | |
tree | 5e8d9622965ee60421eddbb26dcb42ab8bea7712 /hw/arm/versatilepb.c | |
parent | f309ae852c67833c3cac11747474fbb013529382 (diff) |
Use DEFINE_MACHINE() to register all machines
Convert all machines to use DEFINE_MACHINE() instead of QEMUMachine
automatically using a script.
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
[AF: Style cleanups, convert imx25_pdk machine]
Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'hw/arm/versatilepb.c')
-rw-r--r-- | hw/arm/versatilepb.c | 28 |
1 files changed, 12 insertions, 16 deletions
diff --git a/hw/arm/versatilepb.c b/hw/arm/versatilepb.c index 6c69f4eaa8..54281f4e3c 100644 --- a/hw/arm/versatilepb.c +++ b/hw/arm/versatilepb.c @@ -391,27 +391,23 @@ static void vab_init(MachineState *machine) versatile_init(machine, 0x25e); } -static QEMUMachine versatilepb_machine = { - .name = "versatilepb", - .desc = "ARM Versatile/PB (ARM926EJ-S)", - .init = vpb_init, - .block_default_type = IF_SCSI, -}; +static void versatilepb_machine_init(MachineClass *mc) +{ + mc->desc = "ARM Versatile/PB (ARM926EJ-S)"; + mc->init = vpb_init; + mc->block_default_type = IF_SCSI; +} -static QEMUMachine versatileab_machine = { - .name = "versatileab", - .desc = "ARM Versatile/AB (ARM926EJ-S)", - .init = vab_init, - .block_default_type = IF_SCSI, -}; +DEFINE_MACHINE("versatilepb", versatilepb_machine_init) -static void versatile_machine_init(void) +static void versatileab_machine_init(MachineClass *mc) { - qemu_register_machine(&versatilepb_machine); - qemu_register_machine(&versatileab_machine); + mc->desc = "ARM Versatile/AB (ARM926EJ-S)"; + mc->init = vab_init; + mc->block_default_type = IF_SCSI; } -machine_init(versatile_machine_init); +DEFINE_MACHINE("versatileab", versatileab_machine_init) static void vpb_sic_class_init(ObjectClass *klass, void *data) { |