public inbox for passt-dev@passt.top
 help / color / mirror / code / Atom feed
* [PATCH v2 0/3] Fixes for spliced connections
@ 2022-10-12 15:45 Stefano Brivio
  2022-10-12 15:45 ` [PATCH v2 1/3] tcp, tcp_splice: Adjust comments to current meaning of inbound and outbound Stefano Brivio
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Stefano Brivio @ 2022-10-12 15:45 UTC (permalink / raw)
  To: passt-dev; +Cc: David Gibson

The most pressing problem fixed here is that spliced connections with
a remapped destination port would be attempted on the wrong side. This
is an old issue as indicated by the Fixes: tag.

Patch 1/3 restores sanity in comments before we attempt to fix the
issue, patch 2/3 fixes the actual issue, and patch 3/3 introduces
a minor rework on top to fix another issue, where if the user
explicitly configures a loopback address in a port binding we would
still create a non-spliced socket stealing the related connections.

v2:
 - rewrite 2/3 with David's idea of using bit in epoll reference
 - rebase, and use IPV4_IS_LOOPBACK in tcp_conn_from_sock() too

Stefano Brivio (3):
  tcp, tcp_splice: Adjust comments to current meaning of inbound and
    outbound
  tcp, tcp_splice: Fix port remapping for inbound, spliced connections
  Don't create 'tap' socket for ports that are bound to loopback only

 tcp.c        | 192 +++++++++++++++++++++++++++++++--------------------
 tcp.h        |   2 +
 tcp_splice.c |  22 +++---
 util.h       |   3 +
 4 files changed, 137 insertions(+), 82 deletions(-)

-- 
2.35.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-10-13  4:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-12 15:45 [PATCH v2 0/3] Fixes for spliced connections Stefano Brivio
2022-10-12 15:45 ` [PATCH v2 1/3] tcp, tcp_splice: Adjust comments to current meaning of inbound and outbound Stefano Brivio
2022-10-12 15:45 ` [PATCH v2 2/3] tcp, tcp_splice: Fix port remapping for inbound, spliced connections Stefano Brivio
2022-10-13  1:19   ` David Gibson
2022-10-12 15:45 ` [PATCH v2 3/3] tcp: Don't create 'tap' socket for ports that are bound to loopback only Stefano Brivio

Code repositories for project(s) associated with this public inbox

	https://passt.top/passt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for IMAP folder(s).