From 781164e25bdf3e99233ab585f02c72525cfb79c5 Mon Sep 17 00:00:00 2001 From: David Gibson Date: Thu, 18 Jul 2024 15:26:41 +1000 Subject: flow: Helper to create sockets based on flowside We have upcoming use cases where it's useful to create new bound socket based on information from the flow table. Add flowside_sock_l4() to do this for either PIF_HOST or PIF_SPLICE sockets. Signed-off-by: David Gibson Signed-off-by: Stefano Brivio --- flow.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'flow.h') diff --git a/flow.h b/flow.h index e3a778a..bf6b845 100644 --- a/flow.h +++ b/flow.h @@ -164,6 +164,9 @@ static inline bool flowside_eq(const struct flowside *left, left->fport == right->fport; } +int flowside_sock_l4(const struct ctx *c, enum epoll_type type, uint8_t pif, + const struct flowside *tgt, uint32_t data); + /** * struct flow_common - Common fields for packet flows * @state: State of the flow table entry -- cgit v1.2.3