net/mlx5: E-switch, Don't update group if qos is not enabled
authorChris Mi <cmi@nvidia.com>
Sun, 2 Oct 2022 04:56:31 +0000 (21:56 -0700)
committerJakub Kicinski <kuba@kernel.org>
Mon, 3 Oct 2022 23:55:29 +0000 (16:55 -0700)
commit909ffe462a18041f064656b796999bb524c72a66
tree5b021d1c5812222eae1e6fb97e763890ca121388
parent8c9cc1eb90c13ee3ec2a8a52af4e564a9b161047
net/mlx5: E-switch, Don't update group if qos is not enabled

Currently, qos group will be updated and qos will be enabled when
unregistering devlink port. Actually no need to update group if qos
is not enabled.

Add a check to prevent unnecessary enabling and disabling qos for
every port.

Signed-off-by: Chris Mi <cmi@nvidia.com>
Reviewed-by: Dmytro Linkin <dlinkin@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/esw/qos.c