X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?a=blobdiff_plain;f=palacios%2Fsrc%2Fpalacios%2Fvmm_shadow_paging.c;h=3f12f05df01140d77797d80cf1d1a92b8118533a;hb=333f5653d38e4f7b77425b0c18b2496f2b2f8660;hp=b2d3b6cacd09cf5908cec479abee765e27e344fd;hpb=39849abeb743c4e6b669a790c307979fa8d51884;p=palacios.releases.git diff --git a/palacios/src/palacios/vmm_shadow_paging.c b/palacios/src/palacios/vmm_shadow_paging.c index b2d3b6c..3f12f05 100644 --- a/palacios/src/palacios/vmm_shadow_paging.c +++ b/palacios/src/palacios/vmm_shadow_paging.c @@ -51,7 +51,7 @@ struct shadow_page_data { static struct shadow_page_data * create_new_shadow_pt(struct guest_info * info); -static void inject_guest_pf(struct guest_info * info, addr_t fault_addr, pf_error_t error_code); +static int inject_guest_pf(struct guest_info * info, addr_t fault_addr, pf_error_t error_code); static int is_guest_pf(pt_access_status_t guest_access, pt_access_status_t shadow_access); @@ -66,6 +66,7 @@ int v3_init_shadow_page_state(struct guest_info * info) { state->guest_cr3 = 0; state->guest_cr0 = 0; + state->guest_efer.value = 0x0LL; INIT_LIST_HEAD(&(state->page_list)); @@ -235,13 +236,13 @@ static struct shadow_page_data * create_new_shadow_pt(struct guest_info * info) } -static void inject_guest_pf(struct guest_info * info, addr_t fault_addr, pf_error_t error_code) { +static int inject_guest_pf(struct guest_info * info, addr_t fault_addr, pf_error_t error_code) { if (info->enable_profiler) { info->profiler.guest_pf_cnt++; } info->ctrl_regs.cr2 = fault_addr; - v3_raise_exception_with_error(info, PF_EXCEPTION, *(uint_t *)&error_code); + return v3_raise_exception_with_error(info, PF_EXCEPTION, *(uint_t *)&error_code); }