Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e752991a authored by David S. Miller's avatar David S. Miller
Browse files

Merge branch '3c59x-dma-fixes'



Neil Horman says:

====================
3c59x: Fix dma map/unmap imbalances

	recent enhancements to libdma revealed a few minor bugs in 3c59x, in
which dma ranges were mapped as singles and unmaped as pages, or vice versa.
These patches fix those up.  Tested by myself with success
====================

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents 3b780bed 6e144419
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -2459,8 +2459,13 @@ boomerang_interrupt(int irq, void *dev_id)
					struct sk_buff *skb = vp->tx_skbuff[entry];
#if DO_ZEROCOPY
					int i;
					for (i=0; i<=skb_shinfo(skb)->nr_frags; i++)
					pci_unmap_single(VORTEX_PCI(vp),
							le32_to_cpu(vp->tx_ring[entry].frag[0].addr),
							le32_to_cpu(vp->tx_ring[entry].frag[0].length),
							PCI_DMA_TODEVICE);

					for (i=1; i<=skb_shinfo(skb)->nr_frags; i++)
							pci_unmap_page(VORTEX_PCI(vp),
											 le32_to_cpu(vp->tx_ring[entry].frag[i].addr),
											 le32_to_cpu(vp->tx_ring[entry].frag[i].length)&0xFFF,
											 PCI_DMA_TODEVICE);