HV: correct the handling of MU_MEM_ATTR_READ MMU flag
Currently config_page_table_attr() treats MMU_MEM_ATTR_READ exactly as
MMU_MEM_ATTR_BIT_READ_WRITE for PTT_HOST, so even when MMU_MEM_ATTR_WRITE
is not used, the R/W bit in PTE is still being set
@@ -587,7 +587,7 @@ uint64_t config_page_table_attr(struct map_params *map_params, uint32_t flags)
if (flags & MMU_MEM_ATTR_READ) {
/* Configure for read access */
attr |= ((table_type == PTT_EPT)
- ? IA32E_EPT_R_BIT : MMU_MEM_ATTR_BIT_READ_WRITE);
+ ? IA32E_EPT_R_BIT : 0);
}
/* Check for write access */
