[missing stable fix on 5.x] [PATCH] net: tls, update curr on splice as well

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Dec 14, 2023 at 8:45 PM John Fastabend <john.fastabend@xxxxxxxxx> wrote:
> commit c5a595000e2677e865a39f249c056bc05d6e55fd upstream.
>
> Backport of upstream fix for tls on 6.1 and lower kernels.
> The curr pointer must also be updated on the splice similar to how
> we do this for other copy types.
>
> Cc: stable@xxxxxxxxxxxxxxx # 6.1.x-

I think this Cc marker was wrong - the commit message says "on 6.1 and
lower kernels", but this marker seems to say "6.1 and *newer*
kernels". The current status is that this issue is fixed on 6.6.7 and
6.1.69, but not on the 5.x stable kernels.

> Reported-by: Jann Horn <jannh@xxxxxxxxxx>
> Fixes: d829e9c4112b ("tls: convert to generic sk_msg interface")
> Signed-off-by: John Fastabend <john.fastabend@xxxxxxxxx>
> ---
>  net/tls/tls_sw.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/net/tls/tls_sw.c b/net/tls/tls_sw.c
> index 2e60bf06adff..0323040d34bc 100644
> --- a/net/tls/tls_sw.c
> +++ b/net/tls/tls_sw.c
> @@ -1225,6 +1225,8 @@ static int tls_sw_do_sendpage(struct sock *sk, struct page *page,
>                 }
>
>                 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;
> --
> 2.33.0
>





[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux