Thread (3 messages) flat view 3 messages, 2 authors, 2011-12-06

Re: "KVM: PPC: booke: Improve timer register emulation" breaks Book3s HV

From: Paul Mackerras <hidden>
Date: 2011-12-06 11:43:47
Subsystem: kernel virtual machine for powerpc (kvm/powerpc), linux for powerpc (32-bit and 64-bit), the rest · Maintainers: Madhavan Srinivasan, Linus Torvalds

On Tue, Dec 06, 2011 at 03:03:00PM +1100, Paul Mackerras wrote:
I'm not sure why yet, but commit 8a97c432 ("KVM: PPC: booke: Improve
timer register emulation") in Alex's kvm-ppc-next branch is breaking
Book3S HV KVM on POWER7.  Guest cpus fail to spin up, and even with
just one cpu, the guest stalls every so often.  If I stop the guest
and inspect the state with qemu, PC is at 0x900.  Reverting 8a97c432
makes it work properly again.
This fixes it:
diff --git a/arch/powerpc/kvm/powerpc.c b/arch/powerpc/kvm/powerpc.c
index 534cbe1..83bcb44 100644
--- a/arch/powerpc/kvm/powerpc.c
+++ b/arch/powerpc/kvm/powerpc.c
@@ -560,7 +560,7 @@ int kvm_arch_vcpu_ioctl_run(struct kvm_vcpu *vcpu, struct kvm_run *run)
 
 void kvm_vcpu_kick(struct kvm_vcpu *vcpu)
 {
-	if (waitqueue_active(&vcpu->wq)) {
+	if (waitqueue_active(vcpu->arch.wqp)) {
 		wake_up_interruptible(vcpu->arch.wqp);
 		vcpu->stat.halt_wakeup++;
 	} else if (vcpu->cpu != -1) {
Alex, do you want to roll that in with Scott's patch, or do you want me
to send a separate patch on top?

Paul.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help