diff options
author | Eric Dumazet <eric.dumazet@gmail.com> | 2010-04-14 15:59:40 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-04-14 16:11:33 -0700 |
commit | e743d31312d00932391b123dfac3324d2b9e8c81 (patch) | |
tree | e5ac3aacbfdde1fe8eb44c4e010085915da5ea05 /drivers/net/benet | |
parent | b4bf665c5761837f693e87ab27870a5868185ccc (diff) |
drivers: net: use skb_headlen()
replaces (skb->len - skb->data_len) occurrences by skb_headlen(skb)
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/benet')
-rw-r--r-- | drivers/net/benet/be_main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/benet/be_main.c b/drivers/net/benet/be_main.c index 18e0a80d3e61..fa10f13242c3 100644 --- a/drivers/net/benet/be_main.c +++ b/drivers/net/benet/be_main.c @@ -432,7 +432,7 @@ static int make_tx_wrbs(struct be_adapter *adapter, map_head = txq->head; if (skb->len > skb->data_len) { - int len = skb->len - skb->data_len; + int len = skb_headlen(skb); busaddr = pci_map_single(pdev, skb->data, len, PCI_DMA_TODEVICE); if (pci_dma_mapping_error(pdev, busaddr)) @@ -1098,7 +1098,7 @@ static void be_tx_compl_process(struct be_adapter *adapter, u16 last_index) cur_index = txq->tail; wrb = queue_tail_node(txq); unmap_tx_frag(adapter->pdev, wrb, (unmap_skb_hdr && - sent_skb->len > sent_skb->data_len)); + skb_headlen(sent_skb))); unmap_skb_hdr = false; num_wrbs++; |