UPSTREAM: tcp: fix a request socket leak

While the cited commit fixed a possible deadlock, it added a leak
of the request socket, since reqsk_put() must be called if the BPF
filter decided the ACK packet must be dropped.

Fixes: d624d276d1dd ("tcp: fix possible deadlock in TCP stack vs BPF filter")
Signed-off-by: Eric Dumazet <>
Acked-by: Alexei Starovoitov <>
Signed-off-by: David S. Miller <>
(cherry picked from commit 1f3b359f1004bd34b7b0bad70b93e3c7af92a37b)

Bug: 30950746
Change-Id: I59a1f0c70925ee4bd93ac277d785759958bd2b9e
2 files changed