Cleanup the user-space paging exit handler now that the unified instruction

emulation is in place.

Obtained from:	NetApp
This commit is contained in:
Neel Natu 2012-11-28 13:34:44 +00:00
parent b42206f300
commit 48a29f4e07
5 changed files with 3 additions and 10 deletions

View File

@ -267,9 +267,7 @@ struct vm_exit {
uint32_t eax; /* valid for out */
} inout;
struct {
uint64_t cr3;
uint64_t gpa;
int rwx;
struct vie vie;
} paging;
/*

View File

@ -1303,9 +1303,7 @@ vmx_exit_process(struct vmx *vmx, int vcpu, struct vm_exit *vmexit)
cr3, qual, &vmexit->u.paging.vie);
if (!handled) {
vmexit->exitcode = VM_EXITCODE_PAGING;
vmexit->u.paging.cr3 = cr3;
vmexit->u.paging.gpa = gpa;
vmexit->u.paging.rwx = qual & 0x7;
}
break;
default:

View File

@ -453,8 +453,7 @@ vmexit_paging(struct vmctx *ctx, struct vm_exit *vmexit, int *pvcpu)
int err;
stats.vmexit_paging++;
err = emulate_mem(ctx, *pvcpu, vmexit->u.paging.gpa, vmexit->rip,
vmexit->u.paging.cr3, vmexit->u.paging.rwx,
err = emulate_mem(ctx, *pvcpu, vmexit->u.paging.gpa,
&vmexit->u.paging.vie);
if (err) {

View File

@ -156,8 +156,7 @@ mem_write(void *ctx, int vcpu, uint64_t gpa, uint64_t wval, int size, void *arg)
}
int
emulate_mem(struct vmctx *ctx, int vcpu, uint64_t paddr, uint64_t rip,
uint64_t cr3, int mode, struct vie *vie)
emulate_mem(struct vmctx *ctx, int vcpu, uint64_t paddr, struct vie *vie)
{
struct mmio_rb_range *entry;
int err;

View File

@ -50,8 +50,7 @@ struct mem_range {
#define MEM_F_RW 0x3
void init_mem(void);
int emulate_mem(struct vmctx *, int vcpu, uint64_t paddr, uint64_t rip,
uint64_t cr3, int mode, struct vie *vie);
int emulate_mem(struct vmctx *, int vcpu, uint64_t paddr, struct vie *vie);
int register_mem(struct mem_range *memp);