From 66fb9c6a8585faa1167f00d11773766e5abebd77 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Thu, 11 Jan 2024 10:58:04 +0100 Subject: [PATCH] 5.4-stable patches added patches: net-tls-update-curr-on-splice-as-well.patch --- ...et-tls-update-curr-on-splice-as-well.patch | 33 +++++++++++++++++++ queue-5.4/series | 1 + 2 files changed, 34 insertions(+) create mode 100644 queue-5.4/net-tls-update-curr-on-splice-as-well.patch diff --git a/queue-5.4/net-tls-update-curr-on-splice-as-well.patch b/queue-5.4/net-tls-update-curr-on-splice-as-well.patch new file mode 100644 index 00000000000..03e6055b5e9 --- /dev/null +++ b/queue-5.4/net-tls-update-curr-on-splice-as-well.patch @@ -0,0 +1,33 @@ +From c5a595000e2677e865a39f249c056bc05d6e55fd Mon Sep 17 00:00:00 2001 +From: John Fastabend +Date: Wed, 6 Dec 2023 15:27:05 -0800 +Subject: net: tls, update curr on splice as well + +From: John Fastabend + +commit c5a595000e2677e865a39f249c056bc05d6e55fd upstream. + +The curr pointer must also be updated on the splice similar to how +we do this for other copy types. + +Fixes: d829e9c4112b ("tls: convert to generic sk_msg interface") +Signed-off-by: John Fastabend +Reported-by: Jann Horn +Link: https://lore.kernel.org/r/20231206232706.374377-2-john.fastabend@gmail.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Greg Kroah-Hartman +--- + net/tls/tls_sw.c | 2 ++ + 1 file changed, 2 insertions(+) + +--- 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; diff --git a/queue-5.4/series b/queue-5.4/series index 4df9b084a84..ffe514a0e4c 100644 --- a/queue-5.4/series +++ b/queue-5.4/series @@ -29,3 +29,4 @@ ath10k-wait-until-copy-complete-is-actually-done-before-completing.patch ath10k-add-interrupt-summary-based-ce-processing.patch ath10k-keep-track-of-which-interrupts-fired-don-t-poll-them.patch ath10k-get-rid-of-per_ce_irq-hw-param.patch +net-tls-update-curr-on-splice-as-well.patch -- 2.47.3