Palacios Public Git Repository

To checkout Palacios execute

  git clone http://v3vee.org/palacios/palacios.web/palacios.git
This will give you the master branch. You probably want the devel branch or one of the release branches. To switch to the devel branch, simply execute
  cd palacios
  git checkout --track -b devel origin/devel
The other branches are similar.


add more permission checks to shadow paging
[palacios.git] / palacios / src / palacios / mmu / vmm_shdw_pg_tlb_32.h
index 91ae34e..30acc7a 100644 (file)
@@ -274,8 +274,6 @@ static int handle_pte_shadow_pagefault_32(struct guest_info * info, addr_t fault
            }
 
 
-
-           // Write hooks trump all, and are set Read Only
            if (shdw_reg->flags.write == 0) {
                shadow_pte->writable = 0;
            }
@@ -296,7 +294,7 @@ static int handle_pte_shadow_pagefault_32(struct guest_info * info, addr_t fault
                PrintError("Special Page fault handler returned error for address: %p\n",  (void *)fault_addr);
                return -1;
            }
-       } else {
+       } else if (shdw_reg->flags.write == 1) {
            PrintDebug("Shadow PTE Write Error\n");
            shadow_pte->writable = guest_pte->writable;
        }