public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [patch 1/3] x86, intr-remap: set redirection hint in the IRTE
@ 2010-08-27 18:09 Suresh Siddha
  2010-08-27 18:09 ` [patch 2/3] x86, intr-remap: remove IRTE setup duplicate code Suresh Siddha
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: Suresh Siddha @ 2010-08-27 18:09 UTC (permalink / raw)
  To: H. Peter Anvin, Ingo Molnar, Thomas Gleixner
  Cc: LKML, Suresh Siddha, Weidong Han, stable

[-- Attachment #1: set_redir_hint_for_irte.patch --]
[-- Type: text/plain, Size: 1843 bytes --]

Currently the redirection hint in the interrupt-remapping table entry
is set to 0, which means the remapped interrupt is directed to the
processors listed in the destination. So in logical flat mode
in the presence of intr-remapping, this results in a single
interrupt multi-casted to multiple cpu's as specified by the destination
bit mask. But what we really want is to send that interrupt to one of the cpus
based on the lowest priority delivery mode.

Set the redirection hint in the IRTE to '1' to indicate that we want
the remapped interrupt to be directed to only one of the processors
listed in the destination.

This fixes the issue of same interrupt getting delivered to multiple cpu's
in the logical flat mode in the presence of interrupt-remapping. While
there is no functional issue observed with this behavior, this will
impact performance of such configurations (<=8 cpu's using logical flat
mode in the presence of interrupt-remapping)

Signed-off-by: Suresh Siddha <suresh.b.siddha@intel.com>
Cc: Weidong Han <weidong.han@intel.com>
Cc: <stable@kernel.org> # [v2.6.32+]
---

diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_apic.c
index f1efeba..90f8a75 100644
--- a/arch/x86/kernel/apic/io_apic.c
+++ b/arch/x86/kernel/apic/io_apic.c
@@ -1392,6 +1392,7 @@ int setup_ioapic_entry(int apic_id, int irq,
 		irte.dlvry_mode = apic->irq_delivery_mode;
 		irte.vector = vector;
 		irte.dest_id = IRTE_DEST(destination);
+		irte.redir_hint = 1;
 
 		/* Set source-id of interrupt request */
 		set_ioapic_sid(&irte, apic_id);
@@ -3343,6 +3344,7 @@ static int msi_compose_msg(struct pci_dev *pdev, unsigned int irq,
 		irte.dlvry_mode = apic->irq_delivery_mode;
 		irte.vector = cfg->vector;
 		irte.dest_id = IRTE_DEST(dest);
+		irte.redir_hint = 1;
 
 		/* Set source-id of interrupt request */
 		if (pdev)



^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2010-09-16  0:53 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-27 18:09 [patch 1/3] x86, intr-remap: set redirection hint in the IRTE Suresh Siddha
2010-08-27 18:09 ` [patch 2/3] x86, intr-remap: remove IRTE setup duplicate code Suresh Siddha
2010-09-16  0:52   ` [tip:x86/x2apic] x86, intr-remap: Remove " tip-bot for Suresh Siddha
2010-08-27 18:09 ` [patch 3/3] x86, x2apic: simplify apic init in SMP and UP builds Suresh Siddha
2010-09-16  0:52   ` [tip:x86/x2apic] x86, x2apic: Simplify " tip-bot for Suresh Siddha
2010-08-30  1:35 ` [patch 1/3] x86, intr-remap: set redirection hint in the IRTE Weidong Han
2010-08-30  1:47 ` Weidong Han
2010-08-30 17:17   ` Suresh Siddha
2010-08-31  3:29     ` Weidong Han
2010-09-16  0:52 ` [tip:x86/x2apic] x86, intr-remap: Set " tip-bot for Suresh Siddha

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox