* [PATCH net-next] bonding: delete always true device check
@ 2025-02-03 12:59 Leon Romanovsky
2025-02-04 12:49 ` Paolo Abeni
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Leon Romanovsky @ 2025-02-03 12:59 UTC (permalink / raw)
To: Jay Vosburgh
Cc: Leon Romanovsky, Andrew Lunn, David S. Miller, Eric Dumazet,
Hangbin Liu, Jakub Kicinski, netdev, Nikolay Aleksandrov,
Paolo Abeni
From: Leon Romanovsky <leonro@nvidia.com>
XFRM API makes sure that xs->xso.dev is valid in all XFRM offload
callbacks. There is no need to check it again.
Fixes: 1ddec5d0eec4 ("bonding: add common function to check ipsec device")
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
---
There is nothing urgent in this change, it can go to net-next too.
---
drivers/net/bonding/bond_main.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index bfb55c23380b..154e670d8075 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -432,9 +432,6 @@ static struct net_device *bond_ipsec_dev(struct xfrm_state *xs)
struct bonding *bond;
struct slave *slave;
- if (!bond_dev)
- return NULL;
-
bond = netdev_priv(bond_dev);
if (BOND_MODE(bond) != BOND_MODE_ACTIVEBACKUP)
return NULL;
--
2.48.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH net-next] bonding: delete always true device check
2025-02-03 12:59 [PATCH net-next] bonding: delete always true device check Leon Romanovsky
@ 2025-02-04 12:49 ` Paolo Abeni
2025-02-04 16:38 ` Nikolay Aleksandrov
2025-02-04 22:20 ` patchwork-bot+netdevbpf
2 siblings, 0 replies; 4+ messages in thread
From: Paolo Abeni @ 2025-02-04 12:49 UTC (permalink / raw)
To: Leon Romanovsky, Jay Vosburgh
Cc: Leon Romanovsky, Andrew Lunn, David S. Miller, Eric Dumazet,
Hangbin Liu, Jakub Kicinski, netdev, Nikolay Aleksandrov
On 2/3/25 1:59 PM, Leon Romanovsky wrote:
> From: Leon Romanovsky <leonro@nvidia.com>
>
> XFRM API makes sure that xs->xso.dev is valid in all XFRM offload
> callbacks. There is no need to check it again.
>
> Fixes: 1ddec5d0eec4 ("bonding: add common function to check ipsec device")
> Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Acked-by: Paolo Abeni <pabeni@redhat.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH net-next] bonding: delete always true device check
2025-02-03 12:59 [PATCH net-next] bonding: delete always true device check Leon Romanovsky
2025-02-04 12:49 ` Paolo Abeni
@ 2025-02-04 16:38 ` Nikolay Aleksandrov
2025-02-04 22:20 ` patchwork-bot+netdevbpf
2 siblings, 0 replies; 4+ messages in thread
From: Nikolay Aleksandrov @ 2025-02-04 16:38 UTC (permalink / raw)
To: Leon Romanovsky, Jay Vosburgh
Cc: Leon Romanovsky, Andrew Lunn, David S. Miller, Eric Dumazet,
Hangbin Liu, Jakub Kicinski, netdev, Paolo Abeni
On 2/3/25 14:59, Leon Romanovsky wrote:
> From: Leon Romanovsky <leonro@nvidia.com>
>
> XFRM API makes sure that xs->xso.dev is valid in all XFRM offload
> callbacks. There is no need to check it again.
>
> Fixes: 1ddec5d0eec4 ("bonding: add common function to check ipsec device")
> Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
> ---
> There is nothing urgent in this change, it can go to net-next too.
> ---
> drivers/net/bonding/bond_main.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
> index bfb55c23380b..154e670d8075 100644
> --- a/drivers/net/bonding/bond_main.c
> +++ b/drivers/net/bonding/bond_main.c
> @@ -432,9 +432,6 @@ static struct net_device *bond_ipsec_dev(struct xfrm_state *xs)
> struct bonding *bond;
> struct slave *slave;
>
> - if (!bond_dev)
> - return NULL;
> -
> bond = netdev_priv(bond_dev);
> if (BOND_MODE(bond) != BOND_MODE_ACTIVEBACKUP)
> return NULL;
Reviewed-by: Nikolay Aleksandrov <razor@blackwall.org>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH net-next] bonding: delete always true device check
2025-02-03 12:59 [PATCH net-next] bonding: delete always true device check Leon Romanovsky
2025-02-04 12:49 ` Paolo Abeni
2025-02-04 16:38 ` Nikolay Aleksandrov
@ 2025-02-04 22:20 ` patchwork-bot+netdevbpf
2 siblings, 0 replies; 4+ messages in thread
From: patchwork-bot+netdevbpf @ 2025-02-04 22:20 UTC (permalink / raw)
To: Leon Romanovsky
Cc: jv, leonro, andrew+netdev, davem, edumazet, liuhangbin, kuba,
netdev, razor, pabeni
Hello:
This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:
On Mon, 3 Feb 2025 14:59:23 +0200 you wrote:
> From: Leon Romanovsky <leonro@nvidia.com>
>
> XFRM API makes sure that xs->xso.dev is valid in all XFRM offload
> callbacks. There is no need to check it again.
>
> Fixes: 1ddec5d0eec4 ("bonding: add common function to check ipsec device")
> Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
>
> [...]
Here is the summary with links:
- [net-next] bonding: delete always true device check
https://git.kernel.org/netdev/net-next/c/546d98393abc
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] 4+ messages in thread
end of thread, other threads:[~2025-02-04 22:20 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-03 12:59 [PATCH net-next] bonding: delete always true device check Leon Romanovsky
2025-02-04 12:49 ` Paolo Abeni
2025-02-04 16:38 ` Nikolay Aleksandrov
2025-02-04 22:20 ` 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;
as well as URLs for NNTP newsgroup(s).