提交 439e218a 编写于 作者: A Avi Kivity

KVM: MMU: Fix is_dirty_pte()

is_dirty_pte() is used on guest ptes, not shadow ptes, so it needs to avoid
shadow_dirty_mask and use PT_DIRTY_MASK instead.

Misdetecting dirty pages could lead to unnecessarily setting the dirty bit
under EPT.
Signed-off-by: NAvi Kivity <avi@redhat.com>
上级 7ffd92c5
......@@ -242,7 +242,7 @@ static int is_writeble_pte(unsigned long pte)
static int is_dirty_pte(unsigned long pte)
{
return pte & shadow_dirty_mask;
return pte & PT_DIRTY_MASK;
}
static int is_rmap_pte(u64 pte)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册