[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH] vl.c: fix regression when reading machine type from
From: |
Marcel Apfelbaum |
Subject: |
[Qemu-devel] [PATCH] vl.c: fix regression when reading machine type from config file |
Date: |
Tue, 6 Jan 2015 19:41:18 +0200 |
After 'Machine as QOM' series the machine type input triggers
the creation of the machine class.
If the machine type is set in the configuration file, the machine
class is not updated accordingly and remains the default.
Fixed that by querying the machine options after the configuration
file is loaded.
Cc: address@hidden
Reported-by: William Dauchy <address@hidden>
Signed-off-by: Marcel Apfelbaum <address@hidden>
---
vl.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/vl.c b/vl.c
index 7786b2f..ecd8c93 100644
--- a/vl.c
+++ b/vl.c
@@ -3659,6 +3659,11 @@ int main(int argc, char **argv, char **envp)
strerror(-ret));
exit(1);
}
+ opts = qemu_get_machine_opts();
+ optarg = qemu_opt_get(opts, "type");
+ if (optarg) {
+ machine_class = machine_parse(optarg);
+ }
break;
}
case QEMU_OPTION_spice:
--
2.1.0
- [Qemu-devel] [PATCH] vl.c: fix regression when reading machine type from config file,
Marcel Apfelbaum <=