summaryrefslogtreecommitdiffstats
path: root/drivers/pci/msi.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2009-05-17 11:55:57 -0700
committerDavid S. Miller <davem@davemloft.net>2009-05-17 11:55:57 -0700
commit74392592bbf7e93ef383588e21aea0c1450d6f12 (patch)
tree086981f9ef51d57a34fbc5fde8095652877cf739 /drivers/pci/msi.c
parent17e4d43eb6743a92d7667c822a3c3ecd63a9c58e (diff)
parent0f6f49a8cd0163fdb1723ed29f01fc65177108dc (diff)
downloadop-kernel-dev-74392592bbf7e93ef383588e21aea0c1450d6f12.zip
op-kernel-dev-74392592bbf7e93ef383588e21aea0c1450d6f12.tar.gz
Merge branch 'master' of /home/davem/src/GIT/linux-2.6/
Diffstat (limited to 'drivers/pci/msi.c')
-rw-r--r--drivers/pci/msi.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c
index 6f2e629..3627732 100644
--- a/drivers/pci/msi.c
+++ b/drivers/pci/msi.c
@@ -455,8 +455,6 @@ static int msix_capability_init(struct pci_dev *dev,
entry->msi_attrib.default_irq = dev->irq;
entry->msi_attrib.pos = pos;
entry->mask_base = base;
- entry->masked = readl(base + j * PCI_MSIX_ENTRY_SIZE +
- PCI_MSIX_ENTRY_VECTOR_CTRL_OFFSET);
msix_mask_irq(entry, 1);
list_add_tail(&entry->list, &dev->msi_list);
@@ -493,6 +491,12 @@ static int msix_capability_init(struct pci_dev *dev,
msix_set_enable(dev, 1);
dev->msix_enabled = 1;
+ list_for_each_entry(entry, &dev->msi_list, list) {
+ int vector = entry->msi_attrib.entry_nr;
+ entry->masked = readl(base + vector * PCI_MSIX_ENTRY_SIZE +
+ PCI_MSIX_ENTRY_VECTOR_CTRL_OFFSET);
+ }
+
return 0;
}
OpenPOWER on IntegriCloud