qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH] S390: Bail out whithout KVM


From: Alexander Graf
Subject: [Qemu-devel] [PATCH] S390: Bail out whithout KVM
Date: Fri, 18 Dec 2009 16:29:04 +0100

Currently only the S390 KVM target works. To keep users from accidently not
using KVM, let's not even initialize the machine when KVM is not used.

Signed-off-by: Alexander Graf <address@hidden>
---
 hw/s390-virtio.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/hw/s390-virtio.c b/hw/s390-virtio.c
index b57fa9c..a33076a 100644
--- a/hw/s390-virtio.c
+++ b/hw/s390-virtio.c
@@ -142,6 +142,13 @@ static void s390_init(ram_addr_t ram_size,
     ram_addr_t initrd_size = 0;
     int i;
 
+    /* XXX we only work on KVM for now */
+
+    if (!kvm_enabled()) {
+        fprintf(stderr, "The S390 target only works with KVM enabled\n");
+        exit(1);
+    }
+
     /* get a BUS */
     s390_bus = s390_virtio_bus_init(&ram_size);
 
-- 
1.6.0.2





reply via email to

[Prev in Thread] Current Thread [Next in Thread]