BACKPORT: tcp: add tcp_ooo_try_coalesce() helper

In case skb in out_or_order_queue is the result of
multiple skbs coalescing, we would like to get a proper gso_segs
counter tracking, so that future tcp_drop() can report an accurate
number.

I chose to not implement this tracking for skbs in receive queue,
since they are not dropped, unless socket is disconnected.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Acked-by: Soheil Hassas Yeganeh <soheil@google.com>
Acked-by: Yuchung Cheng <ycheng@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit 58152ecbbcc6a0ce7fddd5bf5f6ee535834ece0c)

BUG=chromium:866800
TEST=tcp connection test

Change-Id: I45b52be7bc812b41c8375a76a86f843fd0847d31
Signed-off-by: Guenter Roeck <groeck@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1148928
Reviewed-by: Daniel Wang <wonderfly@google.com>
Reviewed-by: Dylan Reid <dgreid@chromium.org>
(cherry picked from commit c52650426c2d42a8468dfc02c1c26d40a12974cd)
Signed-off-by: Guenter Roeck <groeck@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1151398
1 file changed