Skip to contentSkip to conversation

e1000e: Fix irq_synchronize in MSI-X case

PATCH In review Jean Delvare 2 participants 2 messages Jul 20, 2010 – Jul 21, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 e1000e: Fix irq_synchronize in MSI-X case

Synchronize all IRQs when in MSI-X IRQ mode.

Cc Bruce Allan <[email protected]>
Cc Jesse Brandeburg <[email protected]>

---
I sent this patch to the e1000-devel list on June 8th, 2010, but didn't receive any answer:
http://sourceforge.net/mailarchive/forum.php?thread_name=201006081818.59098.jdelvare%40suse.de&forum_name=e1000-devel

I don't know how critical synchronize_irq() is, so I don't know if this patch should go to stable branches or not.

 drivers/net/e1000e/netdev.c |    8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
drivers/net/e1000e/netdev.c +7 -1
@@ -1939,7 +1939,13 @@ static void e1000_irq_disable(struct e10
 	if (adapter->msix_entries)
 		ew32(EIAC_82574, 0);
 	e1e_flush();
-	synchronize_irq(adapter->pdev->irq);
+
+	if (adapter->msix_entries) {
+		synchronize_irq(adapter->msix_entries[0].vector);
+		synchronize_irq(adapter->msix_entries[1].vector);
+		synchronize_irq(adapter->msix_entries[2].vector);
+	} else
+		synchronize_irq(adapter->pdev->irq);
 }
 
 /**
Signature · 2 lines
Jean Delvare
Suse L3
#1 lore raw
Quoted 35 lines · Jean Delvare

Synchronize all IRQs when in MSI-X IRQ mode.

Cc Bruce Allan <[email protected]>
Cc Jesse Brandeburg <[email protected]>

---
I sent this patch to the e1000-devel list on June 8th, 2010, but didn't receive any answer:
http://sourceforge.net/mailarchive/forum.php?thread_name=201006081818.59098.jdelvare%40suse.de&forum_name=e1000-devel

I don't know how critical synchronize_irq() is, so I don't know if this patch should go to stable branches or not.

 drivers/net/e1000e/netdev.c |    8 +++++++-

 1 file changed, 7 insertions(+), 1 deletion(-)
drivers/net/e1000e/netdev.c +7 -2
@@ -1939,7 +1939,13 @@ static void e1000_irq_disable(struct e10
        if (adapter->msix_entries)
                ew32(EIAC_82574, 0);
        e1e_flush();
-       synchronize_irq(adapter->pdev->irq);
+
+       if (adapter->msix_entries) {
+               synchronize_irq(adapter->msix_entries[0].vector);
+               synchronize_irq(adapter->msix_entries[1].vector);
+               synchronize_irq(adapter->msix_entries[2].vector);
+       } else
+               synchronize_irq(adapter->pdev->irq);
  }
 
  /**
 
--
Quoted 2 lines

Jean Delvare
Suse L3

Thanks, I have added the patch to my queue.

Signature · 2 lines
Cheers,
Jeff