tg3: convert to SKB paged frag API.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: Matt Carlson <mcarlson@broadcom.com>
Cc: Michael Chan <mchan@broadcom.com>
Cc: netdev@vger.kernel.org
Cc: devicetree-discuss@lists.ozlabs.org
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Ian Campbell 2011-08-24 22:28:11 +00:00 committed by David S. Miller
parent 5581be3b48
commit dc234d0b24
1 changed files with 2 additions and 4 deletions

View File

@ -6311,10 +6311,8 @@ static netdev_tx_t tg3_start_xmit(struct sk_buff *skb, struct net_device *dev)
skb_frag_t *frag = &skb_shinfo(skb)->frags[i]; skb_frag_t *frag = &skb_shinfo(skb)->frags[i];
len = frag->size; len = frag->size;
mapping = pci_map_page(tp->pdev, mapping = skb_frag_dma_map(&tp->pdev->dev, frag, 0,
frag->page, len, PCI_DMA_TODEVICE);
frag->page_offset,
len, PCI_DMA_TODEVICE);
tnapi->tx_buffers[entry].skb = NULL; tnapi->tx_buffers[entry].skb = NULL;
dma_unmap_addr_set(&tnapi->tx_buffers[entry], mapping, dma_unmap_addr_set(&tnapi->tx_buffers[entry], mapping,