mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
[PATCH] KVM: MMU: If an empty shadow page is not empty, report more info
Signed-off-by: Avi Kivity <[email protected]> Acked-by: Ingo Molnar <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
5f1e0b6abc
commit
139bdb2d9e
1 changed files with 8 additions and 4 deletions
|
|
@ -305,12 +305,16 @@ static void rmap_write_protect(struct kvm *kvm, u64 gfn)
|
|||
|
||||
static int is_empty_shadow_page(hpa_t page_hpa)
|
||||
{
|
||||
u32 *pos;
|
||||
u32 *end;
|
||||
for (pos = __va(page_hpa), end = pos + PAGE_SIZE / sizeof(u32);
|
||||
u64 *pos;
|
||||
u64 *end;
|
||||
|
||||
for (pos = __va(page_hpa), end = pos + PAGE_SIZE / sizeof(u64);
|
||||
pos != end; pos++)
|
||||
if (*pos != 0)
|
||||
if (*pos != 0) {
|
||||
printk(KERN_ERR "%s: %p %llx\n", __FUNCTION__,
|
||||
pos, *pos);
|
||||
return 0;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue