X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?a=blobdiff_plain;f=palacios%2Fsrc%2Fpalacios%2Fsvm_handler.c;h=63f09baba83713188aed9bc73e1c8ce363bdb66d;hb=f9bb3db89469169bb5775dc031d89e570c6fed70;hp=8a1a32fb69b5b08bb6979e38fdb470994b01e09e;hpb=191587141ec414547ca95a7eb134a8cbb1b2a292;p=palacios.releases.git diff --git a/palacios/src/palacios/svm_handler.c b/palacios/src/palacios/svm_handler.c index 8a1a32f..63f09ba 100644 --- a/palacios/src/palacios/svm_handler.c +++ b/palacios/src/palacios/svm_handler.c @@ -1,3 +1,6 @@ +/* Northwestern University */ +/* (c) 2008, Jack Lange */ + #include #include #include @@ -258,6 +261,21 @@ int handle_svm_exit(struct guest_info * info) { return -1; } } else { + /* + ulong_t tsc_spread = 0; + ullong_t exit_tsc = 0; + + ulong_t rax = (ulong_t)info->vm_regs.rbx; + ulong_t rdx = (ulong_t)info->vm_regs.rcx; + + *(ulong_t *)(&exit_tsc) = rax; + *(((ulong_t *)(&exit_tsc)) + 1) = rdx; + + tsc_spread = info->exit_tsc - exit_tsc; + + PrintError("VMMCALL tsc diff = %lu\n",tsc_spread); + info->rip += 3; + */ PrintError("VMMCALL with not emulator...\n"); return -1; } @@ -452,7 +470,6 @@ int handle_svm_exit(struct guest_info * info) { const uchar_t * vmexit_code_to_str(uint_t exit_code) { - switch(exit_code) { case VMEXIT_CR0_READ: return VMEXIT_CR0_READ_STR;