summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorAya Levin <ayal@nvidia.com>2021-04-21 14:26:31 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-06-03 09:00:36 +0200
commitbbd00c4d50db3558c01b008a98f994063d5c9c4e (patch)
treed9ff1f23c1c44ea8d9d2ce804a4c66596af9e41b /include/linux
parent02a8da446b498f2fa4adf61209c1c666d825b7aa (diff)
net/mlx5e: Fix error path of updating netdev queues
commit 5e7923acbd86d0ff29269688d8a9c47ad091dd46 upstream. Avoid division by zero in the error flow. In the driver TC number can be either 1 or 8. When TC count is set to 1, driver zero netdev->num_tc. Hence, need to convert it back from 0 to 1 in the error flow. Fixes: fa3748775b92 ("net/mlx5e: Handle errors from netif_set_real_num_{tx,rx}_queues") Signed-off-by: Aya Levin <ayal@nvidia.com> Reviewed-by: Maxim Mikityanskiy <maximmi@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@nvidia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux')
0 files changed, 0 insertions, 0 deletions