From: Glauber Costa <[email protected]>

Otherwise, compilation breaks with kvm disabled.

Signed-off-by: Glauber Costa <[email protected]>
Signed-off-by: Avi Kivity <[email protected]>

diff --git a/hw/pc.c b/hw/pc.c
index cf84416..afab0ad 100644
--- a/hw/pc.c
+++ b/hw/pc.c
@@ -1131,7 +1131,9 @@ static void pc_init1(ram_addr_t ram_size,
 #endif
     }
 
-    kvm_set_boot_cpu_id(0);
+    if (kvm_enabled()) {
+        kvm_set_boot_cpu_id(0);
+    }
     for (i = 0; i < smp_cpus; i++) {
         env = pc_new_cpu(cpu_model);
     }
--
To unsubscribe from this list: send the line "unsubscribe kvm-commits" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to