aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Färber <afaerber@suse.de>2012-03-04 21:32:35 +0100
committerAnthony Liguori <aliguori@us.ibm.com>2012-03-13 13:23:17 -0500
commit1b71f7c14fab6f00c2680d4489fbee7baf796e4f (patch)
treec325839cecfd3f9df2521a630965b24e74239645
parent03f48b0797c9904301ee91e0081e89b3a3250f91 (diff)
qom: Register QOM infrastructure early
The constructors for QOM TYPE_INTERFACE were executed rather late in vl.c's main(). Call them very early so that QOM can safely be used for machines and CPUs. Signed-off-by: Andreas Färber <afaerber@suse.de> Cc: Anthony Liguori <anthony@codemonkey.ws> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
-rw-r--r--vl.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/vl.c b/vl.c
index 65f11f200d..bd95539ff7 100644
--- a/vl.c
+++ b/vl.c
@@ -2299,6 +2299,8 @@ int main(int argc, char **argv, char **envp)
#endif
}
+ module_call_init(MODULE_INIT_QOM);
+
runstate_init();
init_clocks();
@@ -3466,8 +3468,6 @@ int main(int argc, char **argv, char **envp)
if (foreach_device_config(DEV_DEBUGCON, debugcon_parse) < 0)
exit(1);
- module_call_init(MODULE_INIT_QOM);
-
/* must be after qdev registration but before machine init */
if (vga_model) {
select_vgahw(vga_model);