summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/myricom
diff options
context:
space:
mode:
authorEric Dumazet <edumazet@google.com>2022-06-30 15:07:50 +0000
committerDavid S. Miller <davem@davemloft.net>2022-07-02 16:22:25 +0100
commit504148fedb854299972d164b001357b888a9193e (patch)
tree6039f99c8ba79b59026808ea7d9de215d1c59903 /drivers/net/ethernet/myricom
parent04740c53cac4bf93b5233a0d774d7f39620378e1 (diff)
net: add skb_[inner_]tcp_all_headers helpers
Most drivers use "skb_transport_offset(skb) + tcp_hdrlen(skb)" to compute headers length for a TCP packet, but others use more convoluted (but equivalent) ways. Add skb_tcp_all_headers() and skb_inner_tcp_all_headers() helpers to harmonize this a bit. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/myricom')
-rw-r--r--drivers/net/ethernet/myricom/myri10ge/myri10ge.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/myricom/myri10ge/myri10ge.c b/drivers/net/ethernet/myricom/myri10ge/myri10ge.c
index 61497c3e4cfb..971dde8c3286 100644
--- a/drivers/net/ethernet/myricom/myri10ge/myri10ge.c
+++ b/drivers/net/ethernet/myricom/myri10ge/myri10ge.c
@@ -2692,7 +2692,7 @@ again:
* send loop that we are still in the
* header portion of the TSO packet.
* TSO header can be at most 1KB long */
- cum_len = -(skb_transport_offset(skb) + tcp_hdrlen(skb));
+ cum_len = -skb_tcp_all_headers(skb);
/* for IPv6 TSO, the checksum offset stores the
* TCP header length, to save the firmware from