mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-06-20 04:33:55 +00:00
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 Signed-off-by: Zide Chen <zide.chen@intel.com>
This commit is contained in:
parent
ff34975d1f
commit
ec2084a8a8
@ -587,7 +587,7 @@ uint64_t config_page_table_attr(struct map_params *map_params, uint32_t flags)
|
|||||||
if (flags & MMU_MEM_ATTR_READ) {
|
if (flags & MMU_MEM_ATTR_READ) {
|
||||||
/* Configure for read access */
|
/* Configure for read access */
|
||||||
attr |= ((table_type == PTT_EPT)
|
attr |= ((table_type == PTT_EPT)
|
||||||
? IA32E_EPT_R_BIT : MMU_MEM_ATTR_BIT_READ_WRITE);
|
? IA32E_EPT_R_BIT : 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Check for write access */
|
/* Check for write access */
|
||||||
|
Loading…
Reference in New Issue
Block a user