Also following upstream behaviour, we exit if not able to service this
request. As we target move forward on merging with qemu, this would have to
happen. So make it sooner, rather than later

Signed-off-by: Glauber Costa <[email protected]>
---
 qemu-kvm.c |    2 +-
 vl.c       |    6 ------
 2 files changed, 1 insertions(+), 7 deletions(-)

diff --git a/qemu-kvm.c b/qemu-kvm.c
index 3c892e6..db28126 100644
--- a/qemu-kvm.c
+++ b/qemu-kvm.c
@@ -37,7 +37,7 @@
 #error libkvm: userspace and kernel version mismatch
 #endif
 
-int kvm_allowed = 1;
+int kvm_allowed = 0;
 int kvm_irqchip = 1;
 int kvm_pit = 1;
 int kvm_pit_reinject = 1;
diff --git a/vl.c b/vl.c
index b3df596..7701488 100644
--- a/vl.c
+++ b/vl.c
@@ -5434,13 +5434,11 @@ int main(int argc, char **argv, char **envp)
                 break;
 #endif
 #ifdef CONFIG_KVM
-#ifdef KVM_UPSTREAM
             case QEMU_OPTION_enable_kvm:
                 kvm_allowed = 1;
 #ifdef CONFIG_KQEMU
                 kqemu_allowed = 0;
 #endif
-#endif
                 break;
            case QEMU_OPTION_no_kvm:
                kvm_allowed = 0;
@@ -5754,11 +5752,7 @@ int main(int argc, char **argv, char **envp)
     if (kvm_enabled()) {
        if (kvm_init(smp_cpus) < 0) {
            fprintf(stderr, "Could not initialize KVM, will disable KVM 
support\n");
-#ifdef NO_CPU_EMULATION
-           fprintf(stderr, "Compiled with --disable-cpu-emulation, 
exiting.\n");
            exit(1);
-#endif
-           kvm_allowed = 0;
        }
     }
 #endif
-- 
1.6.2.2

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to