kvm tools, bios: Set CF for non-supported services

Don't mislead callers into thinking that a non-implemented int15 service
succeeded.

Cc: Cyrill Gorcunov <gorcunov@gmail.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Sasha Levin <levinsasha928@gmail.com>
Signed-off-by: Pekka Enberg <penberg@kernel.org>
This commit is contained in:
Pekka Enberg
2015-06-01 16:39:47 +01:00
committed by Will Deacon
parent 677a2bf1ac
commit 0e753db4a3
+6
View File
@@ -2,11 +2,17 @@
#include "kvm/e820.h"
#include <asm/processor-flags.h>
bioscall void int15_handler(struct biosregs *regs)
{
switch (regs->eax) {
case 0xe820:
e820_query_map(regs);
break;
default:
/* Set CF to indicate failure. */
regs->eflags |= X86_EFLAGS_CF;
break;
}
}