1
0
Fork 0
mirror of https://passt.top/passt synced 2025-06-17 12:45:34 +02:00

tcp: Partially unify tcp_timer() and tcp_splice_timer()

These two functions scan all the non-splced and spliced connections
respectively and perform timed updates on them.  Avoid scanning the now
unified table twice, by having tcp_timer scan it once calling the
relevant per-connection function for each one.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
This commit is contained in:
David Gibson 2022-11-17 16:58:48 +11:00 committed by Stefano Brivio
parent 0eef48c4be
commit 34476511f7
4 changed files with 41 additions and 46 deletions

View file

@ -201,5 +201,8 @@ extern union tcp_conn tc[];
void tcp_splice_conn_update(struct ctx *c, struct tcp_splice_conn *new);
void tcp_table_compact(struct ctx *c, union tcp_conn *hole);
void tcp_splice_destroy(struct ctx *c, struct tcp_splice_conn *conn);
void tcp_splice_timer(struct ctx *c, struct tcp_splice_conn *conn);
void tcp_splice_pipe_refill(const struct ctx *c);
#endif /* TCP_CONN_H */