From: Rusty Russell Date: Tue, 1 Nov 2011 00:15:20 +0000 (+1100) Subject: lguest: Allow running under paravirt-enabled KVM. X-Git-Tag: next-20111101~36^2~19 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=bd5291f5f8b8a9267fc8e93a85251628879da5eb;p=karo-tx-linux.git lguest: Allow running under paravirt-enabled KVM. We actually can run under KVM, as it doesn't paravirtualize anything we need to use; reduce the check to checking we are the normal ringlevel. Reported-by: Stefanos Geraggelos Signed-off-by: Rusty Russell # HG changeset patch --- diff --git a/drivers/lguest/core.c b/drivers/lguest/core.c index 2535933c49f8..5c13e93898f9 100644 --- a/drivers/lguest/core.c +++ b/drivers/lguest/core.c @@ -313,7 +313,7 @@ static int __init init(void) int err; /* Lguest can't run under Xen, VMI or itself. It does Tricky Stuff. */ - if (paravirt_enabled()) { + if (get_kernel_rpl() != 0) { printk("lguest is afraid of being a guest\n"); return -EPERM; }