net/mlx5: Lag, free steering resources on LAG destroy failure
Subsystems (4)
Tariq Toukan
maintainerPATCH 1/1 net/mlx5: Lag, free steering resources on LAG destroy failure
From: Mark Bloch <[email protected]>
When firmware fails to destroy LAG, driver returns before releasing the steering resources, leaking the associated software objects.
The bond is no longer eligible for offload, and the driver cannot prevent its teardown. Release the steering resources even if LAG destruction fails. Preserve the error logging and return the original error after cleanup.
--- drivers/net/ethernet/mellanox/mlx5/core/lag/lag.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/net/ethernet/mellanox/mlx5/core/lag/lag.c +1 -2
@@ -1172,7 +1172,6 @@ int mlx5_deactivate_lag(struct mlx5_lag *ldev)"Failed to deactivate VF LAG; driver restart required\n" "Make sure all VFs are unbound prior to VF LAG activation or deactivation\n"); } -return err; }if (test_bit (MLX5_LAG_MODE_FLAG_HASH_BASED , &flags)) {
@@ -1182,7 +1181,7 @@ int mlx5_deactivate_lag(struct mlx5_lag *ldev)if (mlx5_lag_has_drop_rule (ldev))mlx5_lag_drop_rule_cleanup (ldev); -return 0 ; +return err; }bool mlx5_lag_check_prereq (struct mlx5_lag *ldev)
base-commit: 647b81ddefc6364290e67bf33c89d54971f8995e
Signature · 1 line
2.44.0
[email protected]
AI reviewThis is an automated message. This series looks like a fix, but its commit messages seem to be missing some information:
Hi!
This is an automated message. This series looks like a fix, but its commit messages seem to be missing some information:
- How the issue was discovered, e.g. hit in production, hit during development, syzbot report, manual code inspection, LLM or static analysis tool scan.
- Whether the issue was actually triggered, or is only theoretical (e.g. found by code inspection). If it was triggered please include the symptoms, like the stack trace or error messages.
Please do not repost the series just to address the above. Instead, reply to this email with the missing information, so that reviewers can take it into account. If the series needs another revision for other reasons, please include the information in the commit messages then.
The evaluation is done by an LLM so it may be wrong, if you think that is the case please reply and explain.
This patch was applied to netdev/net.git (main) by Jakub Kicinski <[email protected]>:
Hello:
This patch was applied to netdev/net.git (main)
by Jakub Kicinski <[email protected]>:
Quoted 11 lines · On Wed, 4 Nov 2026 20:39:47 +0200 you wrote:
From: Mark Bloch <[email protected]>
When firmware fails to destroy LAG, driver returns before releasing the steering resources, leaking the associated software objects.
The bond is no longer eligible for offload, and the driver cannot prevent its teardown. Release the steering resources even if LAG destruction fails. Preserve the error logging and return the original error after cleanup.
[...]
Here is the summary with links:
- [net] net/mlx5: Lag, free steering resources on LAG destroy failure
https://git.kernel.org/netdev/net/c/deceb70d1303
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html