RE: [PATCH v7 10/17] KVM: x86: Update IRTE for posted-interrupts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> -----Original Message-----
> From: Alex Williamson [mailto:alex.williamson@xxxxxxxxxx]
> Sent: Wednesday, August 26, 2015 3:58 AM
> To: Wu, Feng
> Cc: pbonzini@xxxxxxxxxx; joro@xxxxxxxxxx; mtosatti@xxxxxxxxxx;
> eric.auger@xxxxxxxxxx; kvm@xxxxxxxxxxxxxxx;
> iommu@xxxxxxxxxxxxxxxxxxxxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx
> Subject: Re: [PATCH v7 10/17] KVM: x86: Update IRTE for posted-interrupts
> 
> On Tue, 2015-08-25 at 16:50 +0800, Feng Wu wrote:
> > This patch adds the routine to update IRTE for posted-interrupts
> > when guest changes the interrupt configuration.
> >
> > Signed-off-by: Feng Wu <feng.wu@xxxxxxxxx>
> > ---
> >  arch/x86/kvm/x86.c | 73
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++
> >  1 file changed, 73 insertions(+)
> > +		kvm_set_msi_irq(e, &irq);
> > +		if (!kvm_intr_is_single_vcpu(kvm, &irq, &vcpu))
> > +			continue;
> > +
> > +		vcpu_info.pi_desc_addr = kvm_x86_ops->get_pi_desc_addr(vcpu);
> > +		vcpu_info.vector = irq.vector;
> > +
> > +		if (set)
> > +			ret = irq_set_vcpu_affinity(host_irq, &vcpu_info);
> > +		else {
> > +			/* suppress notification event before unposting */
> > +			kvm_x86_ops->pi_set_sn(vcpu);
> > +			ret = irq_set_vcpu_affinity(host_irq, NULL);
> > +			kvm_x86_ops->pi_clear_sn(vcpu);
> > +		}
> 
> Can we add trace events so that we have a way to tell when PI is being
> enabled/disabled other than performance heuristics?  Thanks,

Sure, I will add it.

Thanks,
Feng

> 
> Alex
> > 
> 

��.n��������+%������w��{.n�����o�^n�r������&��z�ޗ�zf���h���~����������_��+v���)ߣ�

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux