|
@@ -870,12 +870,10 @@ static int mlx5e_open_cq(struct mlx5e_channel *c,
|
|
|
if (err)
|
|
|
goto err_destroy_cq;
|
|
|
|
|
|
- err = mlx5_core_modify_cq_moderation(mdev, &cq->mcq,
|
|
|
- moderation_usecs,
|
|
|
- moderation_frames);
|
|
|
- if (err)
|
|
|
- goto err_destroy_cq;
|
|
|
-
|
|
|
+ if (MLX5_CAP_GEN(mdev, cq_moderation))
|
|
|
+ mlx5_core_modify_cq_moderation(mdev, &cq->mcq,
|
|
|
+ moderation_usecs,
|
|
|
+ moderation_frames);
|
|
|
return 0;
|
|
|
|
|
|
err_destroy_cq:
|
|
@@ -2218,6 +2216,8 @@ static int mlx5e_check_required_hca_cap(struct mlx5_core_dev *mdev)
|
|
|
}
|
|
|
if (!MLX5_CAP_ETH(mdev, self_lb_en_modifiable))
|
|
|
mlx5_core_warn(mdev, "Self loop back prevention is not supported\n");
|
|
|
+ if (!MLX5_CAP_GEN(mdev, cq_moderation))
|
|
|
+ mlx5_core_warn(mdev, "CQ modiration is not supported\n");
|
|
|
|
|
|
return 0;
|
|
|
}
|