Subject: Re: [PATCH] forcedeth: fix dma api mismatches

From: David Miller <[email-masked]>
Date: Thu, 18 Jun 2009 00:46:42 -0700 (PDT)

From: Eric Dumazet <[email-masked]>
Date: Thu, 18 Jun 2009 09:17:59 +0200

> Please find following patch, candidate for stable, but alas not tested
> since I dont have the hardware. I hit this on a 2.6.30 kernel on a machine
> I dont have access anymore.
> 
> Thank you
> 
> [PATCH] forcedeth: fix dma api mismatches
> 
> forcedeth doesnt use properly dma api in its tx completion path
> and in nv_loopback_test()
> 
> pci_map_single() should be paired with pci_unmap_single()
> pci_map_page() should be paired with pci_unmap_page()
> 
> forcedeth xmit path uses pci_map_single() & pci_map_page(),
> but tx completion path only uses pci_unmap_single()
> 
> nv_loopback_test() uses pci_map_single() & pci_unmap_page()
> 
> Add a dma_single field in struct nv_skb_map, and
> define a helper function nv_unmap_txskb
> 
> Signed-off-by: Eric Dumazet <[email-masked]>
> CC: Ayaz Abdulla <[email-masked]>

I'm going to apply this to net-next-2.6 now since it looks
painfully correct to me.