summaryrefslogtreecommitdiffstats
path: root/drivers/net/mlx4/mlx4_rxq.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/mlx4/mlx4_rxq.c')
-rw-r--r--drivers/net/mlx4/mlx4_rxq.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/mlx4/mlx4_rxq.c b/drivers/net/mlx4/mlx4_rxq.c
index 06030c2c..b3f70d6c 100644
--- a/drivers/net/mlx4/mlx4_rxq.c
+++ b/drivers/net/mlx4/mlx4_rxq.c
@@ -365,6 +365,12 @@ mlx4_rss_init(struct priv *priv)
if (priv->rss_init)
return 0;
+ if (priv->dev->data->nb_rx_queues > priv->hw_rss_max_qps) {
+ ERROR("RSS does not support more than %d queues",
+ priv->hw_rss_max_qps);
+ rte_errno = EINVAL;
+ return -rte_errno;
+ }
/* Prepare range for RSS contexts before creating the first WQ. */
ret = mlx4dv_set_context_attr(priv->ctx,
MLX4DV_SET_CTX_ATTR_LOG_WQS_RANGE_SZ,