public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] KVM: release bad page on MSR_KVM_SYSTEM_TIME
@ 2008-02-25 13:36 Marcelo Tosatti
  2008-02-25 17:27 ` Avi Kivity
  0 siblings, 1 reply; 2+ messages in thread
From: Marcelo Tosatti @ 2008-02-25 13:36 UTC (permalink / raw)
  To: Avi Kivity, Glauber de Oliveira Costa; +Cc: kvm-devel


Subject says it all.

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>


diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index e1aa6c9..ff7ef12 100644
--- a/arch/x86/kvm/x86.c
+++ b/arch/x86/kvm/x86.c
@@ -595,8 +595,10 @@ int kvm_set_msr_common(struct kvm_vcpu *vcpu, u32 msr, u64 data)
 				gfn_to_page(vcpu->kvm, data >> PAGE_SHIFT);
 		up_read(&current->mm->mmap_sem);
 
-		if (is_error_page(vcpu->arch.time_page))
+		if (is_error_page(vcpu->arch.time_page)) {
+			kvm_release_page_clean(vcpu->arch.time_page);
 			vcpu->arch.time_page = NULL;
+		}
 
 		kvm_write_guest_time(vcpu);
 		break;

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] KVM: release bad page on MSR_KVM_SYSTEM_TIME
  2008-02-25 13:36 [PATCH] KVM: release bad page on MSR_KVM_SYSTEM_TIME Marcelo Tosatti
@ 2008-02-25 17:27 ` Avi Kivity
  0 siblings, 0 replies; 2+ messages in thread
From: Avi Kivity @ 2008-02-25 17:27 UTC (permalink / raw)
  To: Marcelo Tosatti; +Cc: kvm-devel, Glauber de Oliveira Costa

Marcelo Tosatti wrote:
> Subject says it all.
>   

Applied, thanks.

-- 
error compiling committee.c: too many arguments to function


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-02-25 17:27 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-02-25 13:36 [PATCH] KVM: release bad page on MSR_KVM_SYSTEM_TIME Marcelo Tosatti
2008-02-25 17:27 ` Avi Kivity

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox