[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-commits] [COMMIT 214910a] fix -daemonize with kvm
From: |
Anthony Liguori |
Subject: |
[Qemu-commits] [COMMIT 214910a] fix -daemonize with kvm |
Date: |
Sat, 26 Sep 2009 21:42:10 -0000 |
From: Marcelo Tosatti <address@hidden>
Otherwise fork might not inherit state initialized by kvm_init().
Signed-off-by: Marcelo Tosatti <address@hidden>
Signed-off-by: Aurelien Jarno <address@hidden>
diff --git a/vl.c b/vl.c
index e7d9232..e12f1d3 100644
--- a/vl.c
+++ b/vl.c
@@ -5424,16 +5424,6 @@ int main(int argc, char **argv, char **envp)
}
}
- if (kvm_enabled()) {
- int ret;
-
- ret = kvm_init(smp_cpus);
- if (ret < 0) {
- fprintf(stderr, "failed to initialize KVM\n");
- exit(1);
- }
- }
-
/* If no data_dir is specified then try to find it relative to the
executable path. */
if (!data_dir) {
@@ -5523,6 +5513,16 @@ int main(int argc, char **argv, char **envp)
}
#endif
+ if (kvm_enabled()) {
+ int ret;
+
+ ret = kvm_init(smp_cpus);
+ if (ret < 0) {
+ fprintf(stderr, "failed to initialize KVM\n");
+ exit(1);
+ }
+ }
+
if (qemu_init_main_loop()) {
fprintf(stderr, "qemu_init_main_loop failed\n");
exit(1);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Qemu-commits] [COMMIT 214910a] fix -daemonize with kvm,
Anthony Liguori <=