Re: Nested VMX - L1 hangs on running L2

2011-07-31 Thread Nadav Har'El
On Sun, Jul 31, 2011, Zachary Amsden wrote about "Re: Nested VMX - L1 hangs on running L2": > This patch looks good, with one comment noted inline below. Are there > no other call sites for kvm_get_msr() or which alias some other > function to kvm_get_msr(MSR_IA32_TSC) ?

Re: Nested VMX - L1 hangs on running L2

2011-07-31 Thread Zachary Amsden
Zachary Amsden wrote about "Re: Nested VMX - L1 hangs > on running L2": >>... >> In that case, you need to distinguish between reads of the TSC MSR by >> the guest and reads by the host (as done internally to track drift and >>... >> Unfortunately, th

Re: Nested VMX - L1 hangs on running L2

2011-07-31 Thread Nadav Har'El
On Fri, Jul 29, 2011, Zachary Amsden wrote about "Re: Nested VMX - L1 hangs on running L2": >... > In that case, you need to distinguish between reads of the TSC MSR by > the guest and reads by the host (as done internally to track drift and >... > Unfortunately, the l

Re: Nested VMX - L1 hangs on running L2

2011-07-29 Thread Roedel, Joerg
On Fri, Jul 29, 2011 at 05:01:16AM -0400, Zachary Amsden wrote: > So you are right, this is still wrong for the case in which L1 does > not trap TSC MSR reads. Note however, the RDTSC instruction is still > virtualized properly, it is only the relatively rare actual TSC MSR > read via RDMSR which

Re: Nested VMX - L1 hangs on running L2

2011-07-29 Thread Zachary Amsden
2011/7/27 Nadav Har'El : > On Wed, Jul 20, 2011, Zachary Amsden wrote about "Re: Nested VMX - L1 hangs > on running L2": >> > > No, both patches are wrong. >> > >> >> kvm_get_msr(vcpu, MSR_IA32_TSC, &tsc) should always return the L1 TSC,

Re: Nested VMX - L1 hangs on running L2

2011-07-28 Thread Matt McGill
hang. As for the correct way to fix it, I don't yet understand the VMX spec or the possible cases well enough to know what the correct behavior should be. -Matt McGill On Jul 28, 2011, at 7:11 AM, Nadav Har'El wrote: > On Wed, Jul 20, 2011, Zachary Amsden wrote about "Re: Nested V

Re: Nested VMX - L1 hangs on running L2

2011-07-28 Thread Nadav Har'El
On Wed, Jul 20, 2011, Zachary Amsden wrote about "Re: Nested VMX - L1 hangs on running L2": > > > No, both patches are wrong. > > > > > The correct fix is to make kvm_get_msr() return the L1 guest TSC at all > > times. > > >  We are serving the L

Re: Nested VMX - L1 hangs on running L2

2011-07-27 Thread Nadav Har'El
On Wed, Jul 20, 2011, Zachary Amsden wrote about "Re: Nested VMX - L1 hangs on running L2": > > > No, both patches are wrong. > > > > kvm_get_msr(vcpu, MSR_IA32_TSC, &tsc) should always return the L1 TSC, > regardless of the setting of any MSR bitmap. The r

Re: Nested VMX - L1 hangs on running L2

2011-07-20 Thread Zachary Amsden
On Wed, Jul 20, 2011 at 12:52 PM, Nadav Har'El wrote: > > > No, both patches are wrong. > > Guys, thanks for looking into this bug. I'm afraid I'm still at a loss at > why a TSC bug would even cause a guest lockup :( > > When Avi Kivity saw my nested TSC handling code he remarked "this is > probab

Re: Nested VMX - L1 hangs on running L2

2011-07-20 Thread Bandan Das
On 0, Nadav Har'El wrote: > > No, both patches are wrong. > > Guys, thanks for looking into this bug. I'm afraid I'm still at a loss at > why a TSC bug would even cause a guest lockup :( > > When Avi Kivity saw my nested TSC handling code he remarked "this is > probably wrong". When I asked him

Re: Nested VMX - L1 hangs on running L2

2011-07-20 Thread Nadav Har'El
> No, both patches are wrong. Guys, thanks for looking into this bug. I'm afraid I'm still at a loss at why a TSC bug would even cause a guest lockup :( When Avi Kivity saw my nested TSC handling code he remarked "this is probably wrong". When I asked him where it was wrong, he basically said tha

Re: Nested VMX - L1 hangs on running L2

2011-07-20 Thread Marcelo Tosatti
On Wed, Jul 20, 2011 at 06:19:19PM +0200, Jan Kiszka wrote: > On 2011-07-20 18:12, Marcelo Tosatti wrote: > > On Wed, Jul 20, 2011 at 09:58:47AM +0200, Jan Kiszka wrote: > >> On 2011-07-18 20:26, Marcelo Tosatti wrote: > >>> > >>> On Fri, Jul 08, 2011 at 02:40:53PM -0400, Bandan Das wrote: > I

Re: Nested VMX - L1 hangs on running L2

2011-07-20 Thread Jan Kiszka
On 2011-07-20 18:12, Marcelo Tosatti wrote: > On Wed, Jul 20, 2011 at 09:58:47AM +0200, Jan Kiszka wrote: >> On 2011-07-18 20:26, Marcelo Tosatti wrote: >>> >>> On Fri, Jul 08, 2011 at 02:40:53PM -0400, Bandan Das wrote: I have already discussed this a bit with Nadav but hoping someone e

Re: Nested VMX - L1 hangs on running L2

2011-07-20 Thread Marcelo Tosatti
On Wed, Jul 20, 2011 at 09:58:47AM +0200, Jan Kiszka wrote: > On 2011-07-18 20:26, Marcelo Tosatti wrote: > > > > On Fri, Jul 08, 2011 at 02:40:53PM -0400, Bandan Das wrote: > >> I have already discussed this a bit with Nadav but hoping someone > >> else has any other ideas/clues/suggestions/comm

Re: Nested VMX - L1 hangs on running L2

2011-07-20 Thread Jan Kiszka
On 2011-07-18 20:26, Marcelo Tosatti wrote: > > On Fri, Jul 08, 2011 at 02:40:53PM -0400, Bandan Das wrote: >> I have already discussed this a bit with Nadav but hoping someone >> else has any other ideas/clues/suggestions/comments. With recent versions of >> the >> kernel (The last I tried is

Re: Nested VMX - L1 hangs on running L2

2011-07-18 Thread Bandan Das
On 0, Marcelo Tosatti wrote: > > On Fri, Jul 08, 2011 at 02:40:53PM -0400, Bandan Das wrote: > > I have already discussed this a bit with Nadav but hoping someone > > else has any other ideas/clues/suggestions/comments. With recent versions > > of the > > kernel (The last I tried is 3.0-rc5 w

Re: Nested VMX - L1 hangs on running L2

2011-07-18 Thread Marcelo Tosatti
On Fri, Jul 08, 2011 at 02:40:53PM -0400, Bandan Das wrote: > I have already discussed this a bit with Nadav but hoping someone > else has any other ideas/clues/suggestions/comments. With recent versions of > the > kernel (The last I tried is 3.0-rc5 with nVMX patches already merged), my L1 >

Nested VMX - L1 hangs on running L2

2011-07-08 Thread Bandan Das
I have already discussed this a bit with Nadav but hoping someone else has any other ideas/clues/suggestions/comments. With recent versions of the kernel (The last I tried is 3.0-rc5 with nVMX patches already merged), my L1 guest always hangs when I start L2. My setup : The host, L1 and L2 a