aboutgitcodebugslistschat
path: root/passt.h
diff options
context:
space:
mode:
authorDavid Gibson <david@gibson.dropbear.id.au>2024-01-16 11:50:38 +1100
committerStefano Brivio <sbrivio@redhat.com>2024-01-22 23:35:25 +0100
commit02e092b4feb8abf9f9beb77a9155ad75b0e4e3d5 (patch)
treeb9f2358b8cf8b72b5c8d306b9618f4898d5107fb /passt.h
parent70121ca1ec8480805569a77e71a00d4add4b29af (diff)
downloadpasst-02e092b4feb8abf9f9beb77a9155ad75b0e4e3d5.tar
passt-02e092b4feb8abf9f9beb77a9155ad75b0e4e3d5.tar.gz
passt-02e092b4feb8abf9f9beb77a9155ad75b0e4e3d5.tar.bz2
passt-02e092b4feb8abf9f9beb77a9155ad75b0e4e3d5.tar.lz
passt-02e092b4feb8abf9f9beb77a9155ad75b0e4e3d5.tar.xz
passt-02e092b4feb8abf9f9beb77a9155ad75b0e4e3d5.tar.zst
passt-02e092b4feb8abf9f9beb77a9155ad75b0e4e3d5.zip
tcp, tcp_splice: Avoid double layered dispatch for connected TCP sockets
Currently connected TCP sockets have the same epoll type, whether they're for a "tap" connection or a spliced connection. This means that tcp_sock_handler() has to do a secondary check on the type of the connection to call the right function. We can avoid this by adding a new epoll type and dispatching directly to the right thing. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Diffstat (limited to 'passt.h')
-rw-r--r--passt.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/passt.h b/passt.h
index f54023a..82b0fcf 100644
--- a/passt.h
+++ b/passt.h
@@ -51,6 +51,8 @@ enum epoll_type {
EPOLL_TYPE_NONE = 0,
/* Connected TCP sockets */
EPOLL_TYPE_TCP,
+ /* Connected TCP sockets (spliced) */
+ EPOLL_TYPE_TCP_SPLICE,
/* Listening TCP sockets */
EPOLL_TYPE_TCP_LISTEN,
/* timerfds used for TCP timers */