From e264d29de28c5b0be3d063307ce9fb613b427cc3 Mon Sep 17 00:00:00 2001 From: Eduardo Habkost Date: Fri, 4 Sep 2015 15:37:08 -0300 Subject: Use DEFINE_MACHINE() to register all machines MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Convert all machines to use DEFINE_MACHINE() instead of QEMUMachine automatically using a script. Signed-off-by: Eduardo Habkost [AF: Style cleanups, convert imx25_pdk machine] Signed-off-by: Andreas Färber --- hw/core/null-machine.c | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) (limited to 'hw/core/null-machine.c') diff --git a/hw/core/null-machine.c b/hw/core/null-machine.c index 1ec7c3bbe0..f36fbf2318 100644 --- a/hw/core/null-machine.c +++ b/hw/core/null-machine.c @@ -19,17 +19,11 @@ static void machine_none_init(MachineState *machine) { } -static QEMUMachine machine_none = { - .name = "none", - .desc = "empty machine", - .init = machine_none_init, - .max_cpus = 0, -}; - -static void register_machines(void) +static void machine_none_machine_init(MachineClass *mc) { - qemu_register_machine(&machine_none); + mc->desc = "empty machine"; + mc->init = machine_none_init; + mc->max_cpus = 0; } -machine_init(register_machines); - +DEFINE_MACHINE("none", machine_none_machine_init) -- cgit 1.4.1