how to set affinity of an interrupt through PCI bus in xen so that the guests always get interrupt on a particular processor? thanks. -a _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Pin the interrupt to a particular VCPU via /proc/irq/#/affinity in the guest (probably dom0), and pin the vcpu to a physical cpu via xm vcpu-pin. -- Keir On 19/10/07 21:03, "Ashish Bijlani" <ashish.bijlani@gmail.com> wrote:> how to set affinity of an interrupt through PCI bus in xen so that the guests > always get interrupt on a particular processor? > > thanks. > > -a > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
How does Xen deliver an interrupt to VCPU? If there are 2 VCPUs for a guest and there is no interrupt affinity set which VCPU will get the interrupt? is it round robin? _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
The guest can choose which VCPU gets any particular interrupt. This is tied into Linux''s normal irq affinity logic, for example. -- Keir On 19/10/07 21:39, "Agarwal, Lomesh" <lomesh.agarwal@intel.com> wrote:> How does Xen deliver an interrupt to VCPU? If there are 2 VCPUs for a > guest and there is no interrupt affinity set which VCPU will get the > interrupt? is it round robin? > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
What happens for windows HVM guest? Also for PV Linux guest do you know how does Linux setup irq affinity? -----Original Message----- From: Keir Fraser [mailto:Keir.Fraser@cl.cam.ac.uk] Sent: Friday, October 19, 2007 1:42 PM To: Agarwal, Lomesh; xen-devel@lists.xensource.com Subject: Re: [Xen-devel] interrupt delivery to VCPU The guest can choose which VCPU gets any particular interrupt. This is tied into Linux''s normal irq affinity logic, for example. -- Keir On 19/10/07 21:39, "Agarwal, Lomesh" <lomesh.agarwal@intel.com> wrote:> How does Xen deliver an interrupt to VCPU? If there are 2 VCPUs for a > guest and there is no interrupt affinity set which VCPU will get the > interrupt? is it round robin? > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
I don''t know about the VT-d support. I doubt that''s been optimised so much. I only know about physical IRQ delivery to PV guests. For Linux, a daemon (irqbalanced) usually periodically rebalances irqs by writing affinity info to /proc/irq/#/affinity. -- Keir On 19/10/07 21:45, "Agarwal, Lomesh" <lomesh.agarwal@intel.com> wrote:> What happens for windows HVM guest? > Also for PV Linux guest do you know how does Linux setup irq affinity? > > -----Original Message----- > From: Keir Fraser [mailto:Keir.Fraser@cl.cam.ac.uk] > Sent: Friday, October 19, 2007 1:42 PM > To: Agarwal, Lomesh; xen-devel@lists.xensource.com > Subject: Re: [Xen-devel] interrupt delivery to VCPU > > The guest can choose which VCPU gets any particular interrupt. This is > tied > into Linux''s normal irq affinity logic, for example. > > -- Keir > > On 19/10/07 21:39, "Agarwal, Lomesh" <lomesh.agarwal@intel.com> wrote: > >> How does Xen deliver an interrupt to VCPU? If there are 2 VCPUs for a >> guest and there is no interrupt affinity set which VCPU will get the >> interrupt? is it round robin? >> >> _______________________________________________ >> Xen-devel mailing list >> Xen-devel@lists.xensource.com >> http://lists.xensource.com/xen-devel_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Does anybody know how windows rebalances irqs among processors? -----Original Message----- From: xen-devel-bounces@lists.xensource.com [mailto:xen-devel-bounces@lists.xensource.com] On Behalf Of Keir Fraser Sent: Friday, October 19, 2007 1:49 PM To: Agarwal, Lomesh; xen-devel@lists.xensource.com Subject: Re: [Xen-devel] interrupt delivery to VCPU I don''t know about the VT-d support. I doubt that''s been optimised so much. I only know about physical IRQ delivery to PV guests. For Linux, a daemon (irqbalanced) usually periodically rebalances irqs by writing affinity info to /proc/irq/#/affinity. -- Keir On 19/10/07 21:45, "Agarwal, Lomesh" <lomesh.agarwal@intel.com> wrote:> What happens for windows HVM guest? > Also for PV Linux guest do you know how does Linux setup irq affinity? > > -----Original Message----- > From: Keir Fraser [mailto:Keir.Fraser@cl.cam.ac.uk] > Sent: Friday, October 19, 2007 1:42 PM > To: Agarwal, Lomesh; xen-devel@lists.xensource.com > Subject: Re: [Xen-devel] interrupt delivery to VCPU > > The guest can choose which VCPU gets any particular interrupt. This is > tied > into Linux''s normal irq affinity logic, for example. > > -- Keir > > On 19/10/07 21:39, "Agarwal, Lomesh" <lomesh.agarwal@intel.com> wrote: > >> How does Xen deliver an interrupt to VCPU? If there are 2 VCPUs for a >> guest and there is no interrupt affinity set which VCPU will get the >> interrupt? is it round robin? >> >> _______________________________________________ >> Xen-devel mailing list >> Xen-devel@lists.xensource.com >> http://lists.xensource.com/xen-devel_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Maybe windows uses IPI for forwarding interrupt to another processor?>From my observation, SMP Windows XP handles RTC timer interrupt this way.-----Original Message----- From: xen-devel-bounces@lists.xensource.com [mailto:xen-devel-bounces@lists.xensource.com] On Behalf Of Agarwal, Lomesh Sent: 2007年10月20日 5:51 To: Keir Fraser; xen-devel@lists.xensource.com Subject: RE: [Xen-devel] interrupt delivery to VCPU Does anybody know how windows rebalances irqs among processors? -----Original Message----- From: xen-devel-bounces@lists.xensource.com [mailto:xen-devel-bounces@lists.xensource.com] On Behalf Of Keir Fraser Sent: Friday, October 19, 2007 1:49 PM To: Agarwal, Lomesh; xen-devel@lists.xensource.com Subject: Re: [Xen-devel] interrupt delivery to VCPU I don''t know about the VT-d support. I doubt that''s been optimised so much. I only know about physical IRQ delivery to PV guests. For Linux, a daemon (irqbalanced) usually periodically rebalances irqs by writing affinity info to /proc/irq/#/affinity. -- Keir On 19/10/07 21:45, "Agarwal, Lomesh" <lomesh.agarwal@intel.com> wrote:> What happens for windows HVM guest? > Also for PV Linux guest do you know how does Linux setup irq affinity? > > -----Original Message----- > From: Keir Fraser [mailto:Keir.Fraser@cl.cam.ac.uk] > Sent: Friday, October 19, 2007 1:42 PM > To: Agarwal, Lomesh; xen-devel@lists.xensource.com > Subject: Re: [Xen-devel] interrupt delivery to VCPU > > The guest can choose which VCPU gets any particular interrupt. This is > tied > into Linux''s normal irq affinity logic, for example. > > -- Keir > > On 19/10/07 21:39, "Agarwal, Lomesh" <lomesh.agarwal@intel.com> wrote: > >> How does Xen deliver an interrupt to VCPU? If there are 2 VCPUs for a >> guest and there is no interrupt affinity set which VCPU will get the >> interrupt? is it round robin? >> >> _______________________________________________ >> Xen-devel mailing list >> Xen-devel@lists.xensource.com >> http://lists.xensource.com/xen-devel_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Does it make sense to change interrupt delivery to VCPU which is going to be runnable next so that interrupt latency can be minimized for HVM guest? -----Original Message----- From: Shan, Haitao Sent: Saturday, October 20, 2007 6:05 PM To: Agarwal, Lomesh; Keir Fraser; xen-devel@lists.xensource.com Subject: RE: [Xen-devel] interrupt delivery to VCPU Maybe windows uses IPI for forwarding interrupt to another processor?>From my observation, SMP Windows XP handles RTC timer interrupt this way.-----Original Message----- From: xen-devel-bounces@lists.xensource.com [mailto:xen-devel-bounces@lists.xensource.com] On Behalf Of Agarwal, Lomesh Sent: 2007年10月20日 5:51 To: Keir Fraser; xen-devel@lists.xensource.com Subject: RE: [Xen-devel] interrupt delivery to VCPU Does anybody know how windows rebalances irqs among processors? -----Original Message----- From: xen-devel-bounces@lists.xensource.com [mailto:xen-devel-bounces@lists.xensource.com] On Behalf Of Keir Fraser Sent: Friday, October 19, 2007 1:49 PM To: Agarwal, Lomesh; xen-devel@lists.xensource.com Subject: Re: [Xen-devel] interrupt delivery to VCPU I don''t know about the VT-d support. I doubt that''s been optimised so much. I only know about physical IRQ delivery to PV guests. For Linux, a daemon (irqbalanced) usually periodically rebalances irqs by writing affinity info to /proc/irq/#/affinity. -- Keir On 19/10/07 21:45, "Agarwal, Lomesh" <lomesh.agarwal@intel.com> wrote:> What happens for windows HVM guest? > Also for PV Linux guest do you know how does Linux setup irq affinity? > > -----Original Message----- > From: Keir Fraser [mailto:Keir.Fraser@cl.cam.ac.uk] > Sent: Friday, October 19, 2007 1:42 PM > To: Agarwal, Lomesh; xen-devel@lists.xensource.com > Subject: Re: [Xen-devel] interrupt delivery to VCPU > > The guest can choose which VCPU gets any particular interrupt. This is > tied > into Linux''s normal irq affinity logic, for example. > > -- Keir > > On 19/10/07 21:39, "Agarwal, Lomesh" <lomesh.agarwal@intel.com> wrote: > >> How does Xen deliver an interrupt to VCPU? If there are 2 VCPUs for a >> guest and there is no interrupt affinity set which VCPU will get the >> interrupt? is it round robin? >> >> _______________________________________________ >> Xen-devel mailing list >> Xen-devel@lists.xensource.com >> http://lists.xensource.com/xen-devel_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel