diff options
author | Eric Dumazet <edumazet@google.com> | 2017-06-01 17:18:36 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-06-02 14:28:25 -0400 |
commit | f4d01666616adeebe72f84ee6e9385e309805ba5 (patch) | |
tree | 8c4af232e0645be8be27fbeb6b64d9b796cabdd2 /net/ipv4/tcp_output.c | |
parent | 80b7d81912d807f161d55e9c2c9cc81061666f83 (diff) |
tcp: remove unnecessary skb_reset_tail_pointer()
__pskb_trim_head() does not need to reset skb tail pointer.
Also change the comments, __pskb_pull_head() does not exist.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/tcp_output.c')
-rw-r--r-- | net/ipv4/tcp_output.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c index 478f75baee31..e3aab1c1cf78 100644 --- a/net/ipv4/tcp_output.c +++ b/net/ipv4/tcp_output.c | |||
@@ -1328,9 +1328,8 @@ int tcp_fragment(struct sock *sk, struct sk_buff *skb, u32 len, | |||
1328 | return 0; | 1328 | return 0; |
1329 | } | 1329 | } |
1330 | 1330 | ||
1331 | /* This is similar to __pskb_pull_head() (it will go to core/skbuff.c | 1331 | /* This is similar to __pskb_pull_tail(). The difference is that pulled |
1332 | * eventually). The difference is that pulled data not copied, but | 1332 | * data is not copied, but immediately discarded. |
1333 | * immediately discarded. | ||
1334 | */ | 1333 | */ |
1335 | static int __pskb_trim_head(struct sk_buff *skb, int len) | 1334 | static int __pskb_trim_head(struct sk_buff *skb, int len) |
1336 | { | 1335 | { |
@@ -1365,7 +1364,6 @@ static int __pskb_trim_head(struct sk_buff *skb, int len) | |||
1365 | } | 1364 | } |
1366 | shinfo->nr_frags = k; | 1365 | shinfo->nr_frags = k; |
1367 | 1366 | ||
1368 | skb_reset_tail_pointer(skb); | ||
1369 | skb->data_len -= len; | 1367 | skb->data_len -= len; |
1370 | skb->len = skb->data_len; | 1368 | skb->len = skb->data_len; |
1371 | return len; | 1369 | return len; |