tcp: fix tcp_poll() races
Status from this message: This series was applied to netdev/net-next.git (main)
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest4 patches 4 repliesApplied 4/4
- v14 patches 13 repliesSuperseded
Patches in v2 All 4 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | tcp: add tcp_done_with_error() helperinclude/ net/ net/ | +23 | 1 reply | Applied |
| 2/4 | tcp: fix race in tcp_write_err()net/ | +1 | 1 reply | Applied |
| 3/4 | tcp: fix races in tcp_abort()net/ | +1 | 1 reply | Applied |
| 4/4 | tcp: fix races in tcp_v[46]_err()net/ net/ | +6 | 1 reply | Applied |
Reviews trailers per patch
All 4 patches have a Reviewed-by or Acked-by.
| Patch | Neal Cardwell |
|---|---|
| 1/4 | A-b |
| 2/4 | A-b |
| 3/4 | A-b |
| 4/4 | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v2 net-next 0/4] tcp: fix tcp_poll() races
Flakes in packetdrill tests stressing epoll_wait() were root caused to bad ordering in tcp_write_err()
Precisely, we have to call sk_error_report() after tcp_done().
When fixing this issue, we discovered tcp_abort(), tcp_v4_err() and tcp_v6_err() had similar issues.
Since tcp_reset() has the correct ordering, first patch takes part of it and creates tcp_done_with_error() helper.
v2: added @err parameter to tcp_done_with_error()
as suggested by David Laight.
Eric Dumazet (4):
tcp: add tcp_done_with_error() helper
tcp: fix race in tcp_write_err()
tcp: fix races in tcp_abort()
tcp: fix races in tcp_v[46]_err()
include/net/tcp.h | 1 + net/ipv4/tcp.c | 8 ++------ net/ipv4/tcp_input.c | 32 +++++++++++++++++++++----------- net/ipv4/tcp_ipv4.c | 11 +++-------- net/ipv4/tcp_timer.c | 6 +----- net/ipv6/tcp_ipv6.c | 10 +++------- 6 files changed, 31 insertions(+), 37 deletions(-)
Signature · 1 line
2.45.1.288.g0e0cd299f1-goog