Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-26 Thread Radim Krčmář
2016-02-25 20:11+0100, Paolo Bonzini: >> 2016-02-25 14:38+0100, Paolo Bonzini: >>> On 19/02/2016 15:44, Radim Krčmář wrote: >>> So we can change QEMU's kvm-i8254 to accept "slew" and warn if >>> "delay" is given. >> ** >> QEMU 4e4fa398db69 ("qdev: Introduce lost tick policy property") defi

Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-25 Thread Paolo Bonzini
> 2016-02-25 14:38+0100, Paolo Bonzini: >> On 19/02/2016 15:44, Radim Krčmář wrote: The resulting injections are: > - for catchup, which QEMU calls slew: 0, 42, 51, 60, 80. >> >> I think we agree that 0, 42, 43, 60, 80 is also a "catchup"/"slew" >> policy. > > We do. (Libvirt "catchup"

Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-25 Thread Radim Krčmář
I think I understand your definitions of tick policies and I remain convinced that libvirt defines them differently. Would you prefer that I got a confirmation on the libvirt list before continuing the discussion here? Two relevant parts of my reply that don't depend on libvirt's reply are marked

Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-25 Thread Paolo Bonzini
On 19/02/2016 15:44, Radim Krčmář wrote: >> The resulting injections are: >>> - for catchup, which QEMU calls slew: 0, 42, 51, 60, 80. I think we agree that 0, 42, 43, 60, 80 is also a "catchup"/"slew" policy. So we can change QEMU's kvm-i8254 to accept "slew" and warn if "delay" is given. In

Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-25 Thread Peter Krempa
On Fri, Feb 19, 2016 at 15:44:23 +0100, Radim Krčmář wrote: > [Cc'd Peter, the last guy that touched timers in libvirt, because he > might know what tick policies are supposed to be.] I found the following RFC that describes the design of timer access in libvirt: http://www.redhat.com/archives/l

Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-19 Thread Radim Krčmář
[Cc'd Peter, the last guy that touched timers in libvirt, because he might know what tick policies are supposed to be.] 2016-02-18 18:55+0100, Paolo Bonzini: > On 18/02/2016 18:33, Paolo Bonzini wrote: >> On 18/02/2016 17:56, Radim Krčmář wrote: >>> 2016-02-18 17:13+0100, Paolo Bonzini: On 1

Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-18 Thread Paolo Bonzini
On 17/02/2016 20:14, Radim Krčmář wrote: > > Even though there is a chance of regressions, I think we can fix the > LVT0 NMI bug without introducing a new tick policy. I agree, but please change the KVM_CAP_REINJECT_CONTROL check to return 2. This way we can make QEMU reject old kernels when t

Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-18 Thread Paolo Bonzini
On 18/02/2016 18:33, Paolo Bonzini wrote: > On 18/02/2016 17:56, Radim Krčmář wrote: >> 2016-02-18 17:13+0100, Paolo Bonzini: >>> On 17/02/2016 20:14, Radim Krčmář wrote: Discard policy uses ack_notifiers to prevent injection of PIT interrupts before EOI from the last one. Thi

Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-18 Thread Paolo Bonzini
On 18/02/2016 17:56, Radim Krčmář wrote: > 2016-02-18 17:13+0100, Paolo Bonzini: > > On 17/02/2016 20:14, Radim Krčmář wrote: > > > Discard policy uses ack_notifiers to prevent injection of PIT interrupts > > > before EOI from the last one. > > > > > > This patch changes the policy to always try t

Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-18 Thread Radim Krčmář
2016-02-18 17:13+0100, Paolo Bonzini: > On 17/02/2016 20:14, Radim Krčmář wrote: >> Discard policy uses ack_notifiers to prevent injection of PIT interrupts >> before EOI from the last one. >> >> This patch changes the policy to always try to deliver the interrupt, >> which makes a difference when

Re: [PATCH v2 01/14] KVM: x86: change PIT discard tick policy

2016-02-18 Thread Paolo Bonzini
On 17/02/2016 20:14, Radim Krčmář wrote: > Discard policy uses ack_notifiers to prevent injection of PIT interrupts > before EOI from the last one. > > This patch changes the policy to always try to deliver the interrupt, > which makes a difference when its vector is in ISR. > Old implementation