WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] Intel VT-D: Don't turn x2APIC if there is

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] Intel VT-D: Don't turn x2APIC if there is a missing DRHD entry for the IOAPIC.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 09 Mar 2010 10:25:10 -0800
Delivery-date: Tue, 09 Mar 2010 10:25:17 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1268157491 0
# Node ID 3198a2e81d383783e675cb49854255c87ab3e7c5
# Parent  bfaafdddf31a1c3988a7bb39a045f950e38a8cbf
Intel VT-D: Don't turn x2APIC if there is a missing DRHD entry for the IOAPIC.

Follow the Linux kernel lead in which the x2APIC is only turned on
only if there is an DRHD entry for all IOAPICs in the system. If we
don't do this we might enable x2APIC and see various devices not
covered by the IOAPIC mentioned in DRHD, not receive any interrupts.

From: Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>
Signed-off-by: Keir Fraser <keir.fraser@xxxxxxxxxx>
---
 xen/drivers/passthrough/vtd/intremap.c |    6 ++++++
 1 files changed, 6 insertions(+)

diff -r bfaafdddf31a -r 3198a2e81d38 xen/drivers/passthrough/vtd/intremap.c
--- a/xen/drivers/passthrough/vtd/intremap.c    Tue Mar 09 17:53:01 2010 +0000
+++ b/xen/drivers/passthrough/vtd/intremap.c    Tue Mar 09 17:58:11 2010 +0000
@@ -127,9 +127,15 @@ int iommu_supports_eim(void)
 int iommu_supports_eim(void)
 {
     struct acpi_drhd_unit *drhd;
+    int apic;
 
     if ( !iommu_enabled || !iommu_qinval || !iommu_intremap )
         return 0;
+
+    /* We MUST have a DRHD unit for each IOAPIC. */
+    for ( apic = 0; apic < nr_ioapics; apic++ )
+        if ( !ioapic_to_iommu(IO_APIC_ID(apic)) )
+            return 0;
 
     if ( list_empty(&acpi_drhd_units) )
         return 0;

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] Intel VT-D: Don't turn x2APIC if there is a missing DRHD entry for the IOAPIC., Xen patchbot-unstable <=