X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?a=blobdiff_plain;f=palacios%2Finclude%2Fgeekos%2Fvm_guest.h;h=f711b3679514f48b72331b6c3ce882b344bdf94a;hb=9be2a31f574121ab4aa0289b7714eefe070b0db0;hp=15b6cca335fdbc18f62990b30fac3c776a6fd360;hpb=2e05f3b8f738466246add183c55bcb17abf33ec9;p=palacios-OLD.git diff --git a/palacios/include/geekos/vm_guest.h b/palacios/include/geekos/vm_guest.h index 15b6cca..f711b36 100644 --- a/palacios/include/geekos/vm_guest.h +++ b/palacios/include/geekos/vm_guest.h @@ -1,24 +1,66 @@ #ifndef __VM_GUEST_H #define __VM_GUEST_H -#include -#include +#include +#include +#include +#include +typedef ullong_t gpr_t; +/* + struct guest_gprs { + addr_t rax; + addr_t rbx; + addr_t rcx; + addr_t rdx; + addr_t rsi; + addr_t rdi; + addr_t rbp; + }; +*/ +struct guest_gprs { + gpr_t rdi; + gpr_t rsi; + gpr_t rbp; + gpr_t rsp; + gpr_t rbx; + gpr_t rdx; + gpr_t rcx; + gpr_t rax; +}; -typedef struct guest_state { - reg_ex_t rip; - reg_ex_t rsp; + +struct shadow_page_state; + + +typedef enum {SHADOW_PAGING, NESTED_PAGING} vm_page_mode_t; +typedef enum {REAL, PROTECTED, PROTECTED_PG, PROTECTED_PAE, PROTECTED_PAE_PG, LONG, LONG_PG} vm_cpu_mode_t; + +struct guest_info { + ullong_t rip; + + + shadow_map_t mem_map; - void * arch_data; -} guest_state_t; + vm_page_mode_t page_mode; + struct shadow_page_state shdw_pg_state; + // nested_paging_t nested_page_state; + + + vmm_io_map_t io_map; + // device_map + vm_cpu_mode_t cpu_mode; + struct guest_gprs vm_regs; + void * vmm_data; +};