* [PATCH net-next] tls: support send/recv queue read in the repair mode
@ 2024-06-21 11:05 Michio Honda
2024-06-25 14:57 ` Jakub Kicinski
0 siblings, 1 reply; 3+ messages in thread
From: Michio Honda @ 2024-06-21 11:05 UTC (permalink / raw)
To: netdev
From df3350858eda825014ac75dced0cede9de4de302 Mon Sep 17 00:00:00 2001
From: Michio Honda <michio.honda@ed.ac.uk>
Date: Thu, 20 Jun 2024 22:05:15 +0100
Subject: [PATCH net-next] tls: support send/recv queue read in the repair mode
TCP REPAIR needs to read the data in the send or receive queue.
This patch forwards those to TCP.
Signed-off-by: Michio Honda <michio.honda@ed.ac.uk>
---
net/tls/tls_sw.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/net/tls/tls_sw.c b/net/tls/tls_sw.c
index 305a412785f5..25b239a9b748 100644
--- a/net/tls/tls_sw.c
+++ b/net/tls/tls_sw.c
@@ -1973,6 +1973,14 @@ int tls_sw_recvmsg(struct sock *sk,
bool bpf_strp_enabled;
bool zc_capable;
+ struct tcp_sock *tp = tcp_sk(sk);
+
+ if (unlikely(tp->repair)) {
+ if (tp->repair_queue == TCP_SEND_QUEUE ||
+ tp->repair_queue == TCP_RECV_QUEUE)
+ return tcp_recvmsg(sk, msg, len, flags, addr_len);
+ }
+
if (unlikely(flags & MSG_ERRQUEUE))
return sock_recv_errqueue(sk, msg, len, SOL_IP, IP_RECVERR);
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-06-25 17:25 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-21 11:05 [PATCH net-next] tls: support send/recv queue read in the repair mode Michio Honda
2024-06-25 14:57 ` Jakub Kicinski
2024-06-25 17:24 ` Michio Honda
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 NNTP newsgroup(s).