On 2013-09-26 22:44, Paolo Bonzini wrote: > Il 26/09/2013 19:47, Paolo Bonzini ha scritto: >> >> If I only apply this hunk, which disables the preemption timer while >> in L1: >> >> @@ -8396,6 +8375,8 @@ static void nested_vmx_vmexit(struct kvm_vcpu *vcpu) >> >> load_vmcs12_host_state(vcpu, vmcs12); >> >> + vmcs_write32(PIN_BASED_VM_EXEC_CONTROL, vmx_pin_based_exec_ctrl(vmx)); >> + >> /* Update TSC_OFFSET if TSC was changed while L2 ran */ >> vmcs_write64(TSC_OFFSET, vmx->nested.vmcs01_tsc_offset); >> >> then the testcase works for somewhat larger values of the preemption timer >> (up to ~1500000 TSC cycles), but then fails. Err, does this mean we run L1 with PIN_BASED_VM_EXEC_CONTROL of L2? Ouch. Should be fixed independently. > > I mean if I apply it on top of current kvm/next, without Arthur's patch. > > If I apply the hunk on top of Arthur's patch nothing changes and the > timer testcase starts breaking around ~65000 TSC cycles. So there are several overlapping issues. > > It is a bit problematic that adding printks changes something, so that > the test starts passing. I haven't tried tracepoints yet. Yeah, just convert to trace_printk. > > Jan, which L1 is using the preemption timer? Any reason why you added > it? The one I'm going to present in Edinburgh. Will publish code soon, but it's unspectacular regard preemption timer usage: I'm only using it to enforce immediate exits on next vmentry, i.e. set the timer value to 0. > I wonder if it isn't better to revert it, since it is quite broken. It's in upstream since 3.10, so reverting doesn't buy us anything, we need to fix it anyway for long-term stable. Jan
Attachment:
signature.asc
Description: OpenPGP digital signature