Skip to contentSkip to conversation

x86: kill msix_flush_writes()

PATCH New Jan Beulich 1 participant 1 message Jan 21, 2010

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x86: kill msix_flush_writes()

The (only) two callers of it don't need it, as the MSI-X case of msi_set_mask_bit() already does the necessary readl().

xen/arch/x86/msi.c +0 -23
@@ -327,27 +327,6 @@ static void msix_set_enable(struct pci_d
     }
 }
 
-static void msix_flush_writes(unsigned int irq)
-{
-    struct msi_desc *entry = irq_desc[irq].msi_desc;
-
-    BUG_ON(!entry || !entry->dev);
-    switch (entry->msi_attrib.type) {
-    case PCI_CAP_ID_MSI:
-        /* nothing to do */
-        break;
-    case PCI_CAP_ID_MSIX:
-    {
-        int offset = PCI_MSIX_ENTRY_VECTOR_CTRL_OFFSET;
-        readl(entry->mask_base + offset);
-        break;
-    }
-    default:
-        BUG();
-        break;
-    }
-}
-
 int msi_maskable_irq(const struct msi_desc *entry)
 {
     BUG_ON(!entry);
@@ -394,13 +373,11 @@ static void msi_set_mask_bit(unsigned in
 void mask_msi_irq(unsigned int irq)
 {
     msi_set_mask_bit(irq, 1);
-    msix_flush_writes(irq);
 }
 
 void unmask_msi_irq(unsigned int irq)
 {
     msi_set_mask_bit(irq, 0);
-    msix_flush_writes(irq);
 }
 
 static struct msi_desc* alloc_msi_entry(void)

The (only) two callers of it don't need it, as the MSI-X case of msi_set_mask_bit() already does the necessary readl().

xen/arch/x86/msi.c +0 -23
@@ -327,27 +327,6 @@ static void msix_set_enable(struct pci_d
     }
 }
 
-static void msix_flush_writes(unsigned int irq)
-{
-    struct msi_desc *entry = irq_desc[irq].msi_desc;
-
-    BUG_ON(!entry || !entry->dev);
-    switch (entry->msi_attrib.type) {
-    case PCI_CAP_ID_MSI:
-        /* nothing to do */
-        break;
-    case PCI_CAP_ID_MSIX:
-    {
-        int offset = PCI_MSIX_ENTRY_VECTOR_CTRL_OFFSET;
-        readl(entry->mask_base + offset);
-        break;
-    }
-    default:
-        BUG();
-        break;
-    }
-}
-
 int msi_maskable_irq(const struct msi_desc *entry)
 {
     BUG_ON(!entry);
@@ -394,13 +373,11 @@ static void msi_set_mask_bit(unsigned in
 void mask_msi_irq(unsigned int irq)
 {
     msi_set_mask_bit(irq, 1);
-    msix_flush_writes(irq);
 }
 
 void unmask_msi_irq(unsigned int irq)
 {
     msi_set_mask_bit(irq, 0);
-    msix_flush_writes(irq);
 }
 
 static struct msi_desc* alloc_msi_entry(void)

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel