aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Fastabend <john.fastabend@gmail.com>2023-12-06 15:27:05 -0800
committerLee Jones <joneslee@google.com>2024-02-06 16:11:08 +0000
commit1b3143b9b166f4b76bfd3d46339b0b3b84f2db64 (patch)
tree9f789d9ca4f7fae4b96bde1fbebe071fd45ff4fd
parentbf4c80bc43586ecaeb309954c0edc5dc3b226240 (diff)
downloadhikey-linaro-1b3143b9b166f4b76bfd3d46339b0b3b84f2db64.tar.gz
UPSTREAM: net: tls, update curr on splice as well
commit c5a595000e2677e865a39f249c056bc05d6e55fd upstream. The curr pointer must also be updated on the splice similar to how we do this for other copy types. Bug: 322282717 Fixes: d829e9c4112b ("tls: convert to generic sk_msg interface") Signed-off-by: John Fastabend <john.fastabend@gmail.com> Reported-by: Jann Horn <jannh@google.com> Link: https://lore.kernel.org/r/20231206232706.374377-2-john.fastabend@gmail.com Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> (cherry picked from commit ba5efd8544fa62ae85daeb36077468bf2ce974ab) Signed-off-by: Lee Jones <joneslee@google.com> Change-Id: If942207e6338993096c9fbc8ce4c23a6bbecaf2e
-rw-r--r--net/tls/tls_sw.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/net/tls/tls_sw.c b/net/tls/tls_sw.c
index 62bc7e5c58e5..38592d0871a3 100644
--- a/net/tls/tls_sw.c
+++ b/net/tls/tls_sw.c
@@ -1211,6 +1211,8 @@ alloc_payload:
}
sk_msg_page_add(msg_pl, page, copy, offset);
+ msg_pl->sg.copybreak = 0;
+ msg_pl->sg.curr = msg_pl->sg.end;
sk_mem_charge(sk, copy);
offset += copy;