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] x86: Call msix_set_enable for MSI-x inter

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] x86: Call msix_set_enable for MSI-x interrupt
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 16 Jan 2009 02:50:53 -0800
Delivery-date: Fri, 16 Jan 2009 02:53:51 -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 1231862027 0
# Node ID 4f6a2bbdff3fea7db13979ffccb1ae5403ca79c8
# Parent  b169db55faf38fda27985626284c9262aac09784
x86: Call msix_set_enable for MSI-x interrupt

For MSI-x, we should call msix_set_enable() instead of
msi_set_enable().

Signed-off-by: Jiang Yunhong <yunhong.jiang@xxxxxxxxx>
---
 xen/arch/x86/msi.c |   15 ++++++++++++---
 1 files changed, 12 insertions(+), 3 deletions(-)

diff -r b169db55faf3 -r 4f6a2bbdff3f xen/arch/x86/msi.c
--- a/xen/arch/x86/msi.c        Tue Jan 13 15:42:47 2009 +0000
+++ b/xen/arch/x86/msi.c        Tue Jan 13 15:53:47 2009 +0000
@@ -671,7 +671,7 @@ static void __pci_disable_msix(struct ms
 
     pos = pci_find_cap_offset(bus, slot, func, PCI_CAP_ID_MSIX);
     control = pci_conf_read16(bus, slot, func, msix_control_reg(pos));
-    msi_set_enable(dev, 0);
+    msix_set_enable(dev, 0);
 
     BUG_ON(list_empty(&dev->msi_list));
 
@@ -770,11 +770,20 @@ int pci_restore_msi_state(struct pci_dev
             return -EINVAL;
         }
 
-        msi_set_enable(pdev, 0);
+        if ( entry->msi_attrib.type == PCI_CAP_ID_MSI )
+            msi_set_enable(pdev, 0);
+        else if ( entry->msi_attrib.type == PCI_CAP_ID_MSIX )
+            msix_set_enable(pdev, 0);
+
         write_msi_msg(entry, &entry->msg);
 
-        msi_set_enable(pdev, 1);
         msi_set_mask_bit(vector, entry->msi_attrib.masked);
+
+        if ( entry->msi_attrib.type == PCI_CAP_ID_MSI )
+            msi_set_enable(pdev, 1);
+        else if ( entry->msi_attrib.type == PCI_CAP_ID_MSIX )
+            msix_set_enable(pdev, 1);
+
         spin_unlock_irqrestore(&desc->lock, flags);
     }
 

_______________________________________________
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] x86: Call msix_set_enable for MSI-x interrupt, Xen patchbot-unstable <=