OSDN Git Service

tcp: set recv_skip_hint when tcp_inq is less than PAGE_SIZE
authorSoheil Hassas Yeganeh <soheil@google.com>
Wed, 26 Sep 2018 20:57:03 +0000 (16:57 -0400)
committerDavid S. Miller <davem@davemloft.net>
Tue, 2 Oct 2018 05:36:56 +0000 (22:36 -0700)
commit8f2b02931175ca56ddb1fe1a2393c34d97a25aa0
tree5ce71db49075b5052e2d2d33efd67152e0589e90
parent2240c12d7d3de741ffbcf22d7a96358a450051ac
tcp: set recv_skip_hint when tcp_inq is less than PAGE_SIZE

When we have less than PAGE_SIZE of data on receive queue,
we set recv_skip_hint to 0. Instead, set it to the actual
number of bytes available.

Signed-off-by: Soheil Hassas Yeganeh <soheil@google.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/tcp.c