]> www.infradead.org Git - users/willy/pagecache.git/commit
net/mlx5: Fix vport QoS cleanup on error
authorCarolina Jubran <cjubran@nvidia.com>
Tue, 25 Feb 2025 07:26:06 +0000 (09:26 +0200)
committerJakub Kicinski <kuba@kernel.org>
Thu, 27 Feb 2025 03:29:39 +0000 (19:29 -0800)
commit7f3528f7d2f98b70e19a6bb7b130fc82c079ac54
tree70b95f5ab8cf6a353e679c4f0ff3803001cc58a5
parent2d253726ff7106b39a44483b6864398bba8a2f74
net/mlx5: Fix vport QoS cleanup on error

When enabling vport QoS fails, the scheduling node was never freed,
causing a leak.

Add the missing free and reset the vport scheduling node pointer to
NULL.

Fixes: be034baba83e ("net/mlx5: Make vport QoS enablement more flexible for future extensions")
Signed-off-by: Carolina Jubran <cjubran@nvidia.com>
Reviewed-by: Cosmin Ratiu <cratiu@nvidia.com>
Reviewed-by: Dragos Tatulea <dtatulea@nvidia.com>
Signed-off-by: Tariq Toukan <tariqt@nvidia.com>
Link: https://patch.msgid.link/20250225072608.526866-2-tariqt@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/esw/qos.c