[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] x86: Call msix_set_enable for MSI-x interrupt
# 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
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |