]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5: E-Switch, Check group pointer before reading bw_share value
authorDmytro Linkin <dlinkin@nvidia.com>
Wed, 17 Nov 2021 09:47:21 +0000 (11:47 +0200)
committerSaeed Mahameed <saeedm@nvidia.com>
Wed, 1 Dec 2021 06:35:04 +0000 (22:35 -0800)
commitdc38095ab60c27769047d2331935b339387bd162
tree63afc42757c136ff233d30069cf04d04e3fd1361
parent7b26393473e7215c228569db32c373127cf236cf
net/mlx5: E-Switch, Check group pointer before reading bw_share value

If log_esw_max_sched_depth is not supported group pointer of the vport
is NULL. Hence, check the pointer before reading bw_share value.

Fixes: f6b97bcb1b0d ("net/mlx5: E-switch, Allow to add vports to rate groups")
Signed-off-by: Dmytro Linkin <dlinkin@nvidia.com>
Reviewed-by: Roi Dayan <roid@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
drivers/net/ethernet/mellanox/mlx5/core/esw/qos.c