diff --git a/include/net/tcp.h b/include/net/tcp.h index 741154d70a9a1c91a6a4e543cf24869aae766a87..96d6f233c6169a3f99a67dffa6ce39f05f69707b 100644 --- a/include/net/tcp.h +++ b/include/net/tcp.h @@ -1352,7 +1352,7 @@ static inline int tcp_win_from_space(const struct sock *sk, int space) /* Note: caller must be prepared to deal with negative returns */ static inline int tcp_space(const struct sock *sk) { - return tcp_win_from_space(sk, sk->sk_rcvbuf - + return tcp_win_from_space(sk, sk->sk_rcvbuf - sk->sk_backlog.len - atomic_read(&sk->sk_rmem_alloc)); }