Re: [Bug 37262] VNC access to KVM VM is unusable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 06/17/2011 04:39 AM, bugzilla-daemon@xxxxxxxxxxxxxxxxxxx wrote:
> https://bugzilla.kernel.org/show_bug.cgi?id=37262
> 
> 
> 
> 
> 
> --- Comment #43 from Steve <stefan.bosak@xxxxxxxxx>  2011-06-16 20:39:32 ---
> Solution of this bug is very simple:
> 
> arch/x86/kvm/mmu.c:
> 
> static bool mapping_level_dirty_bitmap(struct kvm_vcpu *vcpu, gfn_t large_gfn)
> {
> return (gfn_to_memslot_dirty_bitmap(vcpu, large_gfn, true) == NULL)
> ? true : false;
> }
> 
> Only opposite condition.
> Please commit when it's possible.
> 

Yes, it is the reason, thanks for your time and great job, i am so
sorry, this is caused by my mistake :-(

And this is the fix patch from you and i did little cleanup

From: Steve <stefan.bosak@xxxxxxxxx>
Subject: [PATCH] KVM: MMU: fix opposite condition in mapping_level_dirty_bitmap

The condition is opposite, it always maps huge page for the dirty tracked page

Reported-by: Steve <stefan.bosak@xxxxxxxxx>
Signed-off-by: Steve <stefan.bosak@xxxxxxxxx>
---
 arch/x86/kvm/mmu.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index 19ebb76..15afa1e 100644
--- a/arch/x86/kvm/mmu.c
+++ b/arch/x86/kvm/mmu.c
@@ -549,7 +549,7 @@ gfn_to_memslot_dirty_bitmap(struct kvm_vcpu *vcpu, gfn_t gfn,
 
 static bool mapping_level_dirty_bitmap(struct kvm_vcpu *vcpu, gfn_t large_gfn)
 {
-	return gfn_to_memslot_dirty_bitmap(vcpu, large_gfn, true);
+	return !gfn_to_memslot_dirty_bitmap(vcpu, large_gfn, true);
 }
 
 static int mapping_level(struct kvm_vcpu *vcpu, gfn_t large_gfn)
-- 
1.7.5.4

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux