* [PATCH net-next] ipv6: Remove redundant unlikely()
@ 2024-10-08 8:54 Tobias Klauser
2024-10-09 12:04 ` Simon Horman
2024-10-10 2:50 ` patchwork-bot+netdevbpf
0 siblings, 2 replies; 5+ messages in thread
From: Tobias Klauser @ 2024-10-08 8:54 UTC (permalink / raw)
To: netdev
Cc: David S. Miller, David Ahern, Eric Dumazet, Jakub Kicinski,
Paolo Abeni
IS_ERR_OR_NULL() already implies unlikely().
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
---
net/ipv6/ip6_output.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/ipv6/ip6_output.c b/net/ipv6/ip6_output.c
index 205673179b3c..f7b4608bb316 100644
--- a/net/ipv6/ip6_output.c
+++ b/net/ipv6/ip6_output.c
@@ -127,7 +127,7 @@ static int ip6_finish_output2(struct net *net, struct sock *sk, struct sk_buff *
nexthop = rt6_nexthop(dst_rt6_info(dst), daddr);
neigh = __ipv6_neigh_lookup_noref(dev, nexthop);
- if (unlikely(IS_ERR_OR_NULL(neigh))) {
+ if (IS_ERR_OR_NULL(neigh)) {
if (unlikely(!neigh))
neigh = __neigh_create(&nd_tbl, nexthop, dev, false);
if (IS_ERR(neigh)) {
--
2.43.0
^ permalink raw reply related [flat|nested] 5+ messages in thread* Re: [PATCH net-next] ipv6: Remove redundant unlikely()
2024-10-08 8:54 [PATCH net-next] ipv6: Remove redundant unlikely() Tobias Klauser
@ 2024-10-09 12:04 ` Simon Horman
2024-10-10 2:50 ` patchwork-bot+netdevbpf
1 sibling, 0 replies; 5+ messages in thread
From: Simon Horman @ 2024-10-09 12:04 UTC (permalink / raw)
To: Tobias Klauser
Cc: netdev, David S. Miller, David Ahern, Eric Dumazet,
Jakub Kicinski, Paolo Abeni
On Tue, Oct 08, 2024 at 10:54:54AM +0200, Tobias Klauser wrote:
> IS_ERR_OR_NULL() already implies unlikely().
>
> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Looking at the implementation of IS_ERR_OR_NULL() I agree.
Reviewed-by: Simon Horman <horms@kernel.org>
...
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH net-next] ipv6: Remove redundant unlikely()
2024-10-08 8:54 [PATCH net-next] ipv6: Remove redundant unlikely() Tobias Klauser
2024-10-09 12:04 ` Simon Horman
@ 2024-10-10 2:50 ` patchwork-bot+netdevbpf
1 sibling, 0 replies; 5+ messages in thread
From: patchwork-bot+netdevbpf @ 2024-10-10 2:50 UTC (permalink / raw)
To: Tobias Klauser; +Cc: netdev, davem, dsahern, edumazet, kuba, pabeni
Hello:
This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:
On Tue, 8 Oct 2024 10:54:54 +0200 you wrote:
> IS_ERR_OR_NULL() already implies unlikely().
>
> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
> ---
> net/ipv6/ip6_output.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Here is the summary with links:
- [net-next] ipv6: Remove redundant unlikely()
https://git.kernel.org/netdev/net-next/c/3a1beabe1159
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] 5+ messages in thread
* [PATCH net-next] ipv6: Remove redundant unlikely()
@ 2017-09-26 9:22 Tobias Klauser
2017-09-26 16:54 ` David Miller
0 siblings, 1 reply; 5+ messages in thread
From: Tobias Klauser @ 2017-09-26 9:22 UTC (permalink / raw)
To: netdev; +Cc: David S. Miller, Alexey Kuznetsov, Hideaki YOSHIFUJI
IS_ERR() already implies unlikely(), so it can be omitted.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
---
net/ipv6/addrconf.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index 96861c702c06..13c3b697f8c0 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -3297,7 +3297,7 @@ static int fixup_permanent_addr(struct inet6_dev *idev,
struct rt6_info *rt, *prev;
rt = addrconf_dst_alloc(idev, &ifp->addr, false);
- if (unlikely(IS_ERR(rt)))
+ if (IS_ERR(rt))
return PTR_ERR(rt);
/* ifp->rt can be accessed outside of rtnl */
--
2.13.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
end of thread, other threads:[~2024-10-10 2:50 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-08 8:54 [PATCH net-next] ipv6: Remove redundant unlikely() Tobias Klauser
2024-10-09 12:04 ` Simon Horman
2024-10-10 2:50 ` patchwork-bot+netdevbpf
-- strict thread matches above, loose matches on Subject: below --
2017-09-26 9:22 Tobias Klauser
2017-09-26 16:54 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).