KVM: Wire up hypercall handlers to a central arch-independent location

Signed-off-by: Avi Kivity <avi@qumranet.com>
This commit is contained in:
Avi Kivity
2007-02-19 14:37:47 +02:00
parent 02e235bc8e
commit 270fd9b96f
4 changed files with 40 additions and 18 deletions

View File

@ -1078,16 +1078,8 @@ static int halt_interception(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run)
static int vmmcall_interception(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run)
{
printk(KERN_DEBUG "got vmmcall at RIP %08llx\n",
vcpu->svm->vmcb->save.rip);
printk(KERN_DEBUG "vmmcall params: %08llx, %08lx, %08lx, %08lx\n",
vcpu->svm->vmcb->save.rax,
vcpu->regs[VCPU_REGS_RCX],
vcpu->regs[VCPU_REGS_RDX],
vcpu->regs[VCPU_REGS_RBP]);
vcpu->svm->vmcb->save.rax = 0;
vcpu->svm->vmcb->save.rip += 3;
return 1;
return kvm_hypercall(vcpu, kvm_run);
}
static int invalid_op_interception(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run)