Patch "ipv6: ip6_finish_output2: set sk into newly allocated nskb" has been added to the 5.4-stable tree

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

 



This is a note to let you know that I've just added the patch titled

    ipv6: ip6_finish_output2: set sk into newly allocated nskb

to the 5.4-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     ipv6-ip6_finish_output2-set-sk-into-newly-allocated-.patch
and it can be found in the queue-5.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 52e9c39deecb202d0c8fa43a15faa9c709d4f0f9
Author: Vasily Averin <vvs@xxxxxxxxxxxxx>
Date:   Mon Jul 19 10:55:14 2021 +0300

    ipv6: ip6_finish_output2: set sk into newly allocated nskb
    
    [ Upstream commit 2d85a1b31dde84038ea07ad825c3d8d3e71f4344 ]
    
    skb_set_owner_w() should set sk not to old skb but to new nskb.
    
    Fixes: 5796015fa968 ("ipv6: allocate enough headroom in ip6_finish_output2()")
    Signed-off-by: Vasily Averin <vvs@xxxxxxxxxxxxx>
    Link: https://lore.kernel.org/r/70c0744f-89ae-1869-7e3e-4fa292158f4b@xxxxxxxxxxxxx
    Signed-off-by: Jakub Kicinski <kuba@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/net/ipv6/ip6_output.c b/net/ipv6/ip6_output.c
index f26ef5606d8a..fc913f09606d 100644
--- a/net/ipv6/ip6_output.c
+++ b/net/ipv6/ip6_output.c
@@ -73,7 +73,7 @@ static int ip6_finish_output2(struct net *net, struct sock *sk, struct sk_buff *
 
 			if (likely(nskb)) {
 				if (skb->sk)
-					skb_set_owner_w(skb, skb->sk);
+					skb_set_owner_w(nskb, skb->sk);
 				consume_skb(skb);
 			} else {
 				kfree_skb(skb);



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux