[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANn89iL7bO-vspoqTvyWZ22vp7qgiC+jC7fPm8XTtoiF8k+2EQ@mail.gmail.com>
Date: Thu, 11 Nov 2021 17:16:32 -0800
From: Eric Dumazet <edumazet@...gle.com>
To: patchwork-bot+netdevbpf@...nel.org
Cc: luo penghao <cgel.zte@...il.com>, davem@...emloft.net,
yoshfuji@...ux-ipv6.org, dsahern@...nel.org, kuba@...nel.org,
netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
luo.penghao@....com.cn, zealci@....com.cn
Subject: Re: [PATCH linux-next] ipv6: Remove assignment to 'newinet'
On Thu, Nov 11, 2021 at 4:41 PM <patchwork-bot+netdevbpf@...nel.org> wrote:
>
> Hello:
>
> This patch was applied to netdev/net-next.git (master)
> by Jakub Kicinski <kuba@...nel.org>:
>
> On Thu, 11 Nov 2021 09:23:46 +0000 you wrote:
> > From: luo penghao <luo.penghao@....com.cn>
> >
> > The same statement will overwrite it afterwards. meanwhile, the
> > assignment is in the if statement, the variable will not be used
> >
> > Reported-by: Zeal Robot <zealci@....com.cn>
> > Signed-off-by: luo penghao <luo.penghao@....com.cn>
> >
> > [...]
>
> Here is the summary with links:
> - [linux-next] ipv6: Remove assignment to 'newinet'
> https://git.kernel.org/netdev/net-next/c/70bf363d7adb
>
> You are awesome, thank you!
> --
> Deet-doot-dot, I am a bot.
> https://korg.docs.kernel.org/patchwork/pwbot.html
>
>
But why ?
All these bots, trying to send the same patches to multiple trees....
commit 70bf363d7adb3a428773bc905011d0ff923ba747
Author: Nghia Le <nghialm78@...il.com>
Date: Thu Nov 4 21:37:40 2021 +0700
ipv6: remove useless assignment to newinet in tcp_v6_syn_recv_sock()
The newinet value is initialized with inet_sk() in a block code to
handle sockets for the ETH_P_IP protocol. Along this code path,
newinet is never read. Thus, assignment to newinet is needless and
can be removed.
Signed-off-by: Nghia Le <nghialm78@...il.com>
Reviewed-by: Eric Dumazet <edumazet@...gle.com>
Link: https://lore.kernel.org/r/20211104143740.32446-1-nghialm78@gmail.com
Signed-off-by: Jakub Kicinski <kuba@...nel.org>
diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c
index 2cc9b0e53ad1c8e2d35fc9c6dbd1e90fee40b632..551fce49841d7f53a111b0435855634cece2b40a
100644
--- a/net/ipv6/tcp_ipv6.c
+++ b/net/ipv6/tcp_ipv6.c
@@ -1263,7 +1263,6 @@ static struct sock *tcp_v6_syn_recv_sock(const
struct sock *sk, struct sk_buff *
inet_sk(newsk)->pinet6 = tcp_inet6_sk(newsk);
- newinet = inet_sk(newsk);
newnp = tcp_inet6_sk(newsk);
newtp = tcp_sk(newsk);
Powered by blists - more mailing lists