* [PATCH linux-next] net: sched: act_ct: remove redundant variable err
@ 2022-09-13 16:13 cgel.zte
2022-09-21 12:00 ` patchwork-bot+netdevbpf
0 siblings, 1 reply; 2+ messages in thread
From: cgel.zte @ 2022-09-13 16:13 UTC (permalink / raw)
To: jhs, xiyou.wangcong, jiri, davem
Cc: edumazet, kuba, pabeni, netdev, linux-kernel, Jinpeng Cui,
Zeal Robot
From: Jinpeng Cui <cui.jinpeng2@zte.com.cn>
Return value directly from pskb_trim_rcsum() instead of
getting value from redundant variable err.
Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Jinpeng Cui <cui.jinpeng2@zte.com.cn>
---
net/sched/act_ct.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/net/sched/act_ct.c b/net/sched/act_ct.c
index 4dd3fac42504..9d19710835b0 100644
--- a/net/sched/act_ct.c
+++ b/net/sched/act_ct.c
@@ -696,7 +696,6 @@ static bool tcf_ct_skb_nfct_cached(struct net *net, struct sk_buff *skb,
static int tcf_ct_skb_network_trim(struct sk_buff *skb, int family)
{
unsigned int len;
- int err;
switch (family) {
case NFPROTO_IPV4:
@@ -710,9 +709,7 @@ static int tcf_ct_skb_network_trim(struct sk_buff *skb, int family)
len = skb->len;
}
- err = pskb_trim_rcsum(skb, len);
-
- return err;
+ return pskb_trim_rcsum(skb, len);
}
static u8 tcf_ct_skb_nf_family(struct sk_buff *skb)
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH linux-next] net: sched: act_ct: remove redundant variable err
2022-09-13 16:13 [PATCH linux-next] net: sched: act_ct: remove redundant variable err cgel.zte
@ 2022-09-21 12:00 ` patchwork-bot+netdevbpf
0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-09-21 12:00 UTC (permalink / raw)
To: CGEL
Cc: jhs, xiyou.wangcong, jiri, davem, edumazet, kuba, pabeni, netdev,
linux-kernel, cui.jinpeng2, zealci
Hello:
This patch was applied to netdev/net-next.git (master)
by David S. Miller <davem@davemloft.net>:
On Tue, 13 Sep 2022 16:13:26 +0000 you wrote:
> From: Jinpeng Cui <cui.jinpeng2@zte.com.cn>
>
> Return value directly from pskb_trim_rcsum() instead of
> getting value from redundant variable err.
>
> Reported-by: Zeal Robot <zealci@zte.com.cn>
> Signed-off-by: Jinpeng Cui <cui.jinpeng2@zte.com.cn>
>
> [...]
Here is the summary with links:
- [linux-next] net: sched: act_ct: remove redundant variable err
https://git.kernel.org/netdev/net-next/c/2a566f0148ba
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-09-21 12:00 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-09-13 16:13 [PATCH linux-next] net: sched: act_ct: remove redundant variable err cgel.zte
2022-09-21 12:00 ` patchwork-bot+netdevbpf
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox