From e689f7c668cbd9d08f330e17c3dd3a059c9553d3 Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Wed, 30 Oct 2013 13:56:39 +0100 Subject: hw: Pass QEMUMachine to its init() method MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Put it in QEMUMachineInitArgs, so I don't have to touch every board. Reviewed-by: Andreas Färber Reviewed-by: Eduardo Habkost Reviewed-by: Michael S. Tsirkin Signed-off-by: Markus Armbruster Signed-off-by: Michael S. Tsirkin --- include/hw/boards.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/hw/boards.h b/include/hw/boards.h index 5a7ae9f..2151460 100644 --- a/include/hw/boards.h +++ b/include/hw/boards.h @@ -6,7 +6,10 @@ #include "sysemu/blockdev.h" #include "hw/qdev.h" +typedef struct QEMUMachine QEMUMachine; + typedef struct QEMUMachineInitArgs { + const QEMUMachine *machine; ram_addr_t ram_size; const char *boot_order; const char *kernel_filename; @@ -21,7 +24,7 @@ typedef void QEMUMachineResetFunc(void); typedef void QEMUMachineHotAddCPUFunc(const int64_t id, Error **errp); -typedef struct QEMUMachine { +struct QEMUMachine { const char *name; const char *alias; const char *desc; @@ -43,7 +46,7 @@ typedef struct QEMUMachine { GlobalProperty *compat_props; struct QEMUMachine *next; const char *hw_version; -} QEMUMachine; +}; int qemu_register_machine(QEMUMachine *m); QEMUMachine *find_default_machine(void); -- cgit v1.1