]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
another .27 patch
authorGreg Kroah-Hartman <gregkh@suse.de>
Mon, 25 Jan 2010 20:42:48 +0000 (12:42 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 25 Jan 2010 20:42:48 +0000 (12:42 -0800)
queue-2.6.27/series
queue-2.6.27/sfc-fix-dma-mapping-cleanup-in-case-of-an-error-in-tso.patch [new file with mode: 0644]

index f3258bd56e8d5cf552680d4f6e444839f1487211..b78891860cdc3565eef6ffdbf7760c72bf04b509 100644 (file)
@@ -7,3 +7,4 @@ tty-fix-race-in-tty_fasync.patch
 usb-add-missing-delay-during-remote-wakeup.patch
 usb-ehci-fix-handling-of-unusual-interrupt-intervals.patch
 usb-ehci-uhci-fix-race-between-root-hub-suspend-and-port-resume.patch
+sfc-fix-dma-mapping-cleanup-in-case-of-an-error-in-tso.patch
diff --git a/queue-2.6.27/sfc-fix-dma-mapping-cleanup-in-case-of-an-error-in-tso.patch b/queue-2.6.27/sfc-fix-dma-mapping-cleanup-in-case-of-an-error-in-tso.patch
new file mode 100644 (file)
index 0000000..5a73f04
--- /dev/null
@@ -0,0 +1,40 @@
+From a7ebd27a13757248863cd61e541af7fa9e7727ee Mon Sep 17 00:00:00 2001
+From: Neil Turton <nturton@solarflare.com>
+Date: Wed, 23 Dec 2009 13:47:13 +0000
+Subject: sfc: Fix DMA mapping cleanup in case of an error in TSO
+
+From: Neil Turton <nturton@solarflare.com>
+
+commit a7ebd27a13757248863cd61e541af7fa9e7727ee upstream.
+
+We need buffer->len to remain valid to work out the correct address to
+be unmapped.  We therefore need to clear buffer->len after the unmap
+operation.
+
+Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/net/sfc/tx.c |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/drivers/net/sfc/tx.c
++++ b/drivers/net/sfc/tx.c
+@@ -813,14 +813,14 @@ static void efx_enqueue_unwind(struct ef
+                                          tx_queue->efx->type->txd_ring_mask];
+               efx_tsoh_free(tx_queue, buffer);
+               EFX_BUG_ON_PARANOID(buffer->skb);
+-              buffer->len = 0;
+-              buffer->continuation = 1;
+               if (buffer->unmap_len) {
+                       pci_unmap_page(tx_queue->efx->pci_dev,
+                                      buffer->unmap_addr,
+                                      buffer->unmap_len, PCI_DMA_TODEVICE);
+                       buffer->unmap_len = 0;
+               }
++              buffer->len = 0;
++              buffer->continuation = 1;
+       }
+ }