diff options
author | Paolo Abeni <pabeni@redhat.com> | 2024-02-15 19:25:30 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2024-03-01 13:16:49 +0100 |
commit | 8affdbb3e2ef6b6a3a467b87dc336dc601dc2ed9 (patch) | |
tree | 4fd2f6b7e1095f911ed3832753d4b1e5d394d96a /net/tls/tls_main.c | |
parent | eb3693454baab7d784d3b56c96a99c106e49ce14 (diff) |
mptcp: fix lockless access in subflow ULP diag
commit b8adb69a7d29c2d33eb327bca66476fb6066516b upstream.
Since the introduction of the subflow ULP diag interface, the
dump callback accessed all the subflow data with lockless.
We need either to annotate all the read and write operation accordingly,
or acquire the subflow socket lock. Let's do latter, even if slower, to
avoid a diffstat havoc.
Fixes: 5147dfb50832 ("mptcp: allow dumping subflow context to userspace")
Cc: stable@vger.kernel.org
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Reviewed-by: Mat Martineau <martineau@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/tls/tls_main.c')
-rw-r--r-- | net/tls/tls_main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/tls/tls_main.c b/net/tls/tls_main.c index 7ee3c8b03a39..2bbacd9b97e5 100644 --- a/net/tls/tls_main.c +++ b/net/tls/tls_main.c @@ -800,7 +800,7 @@ static void tls_update(struct sock *sk, struct proto *p, } } -static int tls_get_info(const struct sock *sk, struct sk_buff *skb) +static int tls_get_info(struct sock *sk, struct sk_buff *skb) { u16 version, cipher_type; struct tls_context *ctx; |