summaryrefslogtreecommitdiff
path: root/drivers/net/mlx4/mlx4.c
diff options
context:
space:
mode:
authorMoti Haimovsky <motih@mellanox.com>2018-07-25 17:47:39 +0300
committerShahaf Shuler <shahafs@mellanox.com>2018-08-02 12:34:16 +0200
commit2b4e423fd4c9ed5b0a4d1a0962f4af653b7324c5 (patch)
tree3e4195c190ff47f62191953b0ff6b96156a82841 /drivers/net/mlx4/mlx4.c
parente94be227b7ea025d8fd0ee5d79052a8c31d432c6 (diff)
downloaddpdk-2b4e423fd4c9ed5b0a4d1a0962f4af653b7324c5.zip
dpdk-2b4e423fd4c9ed5b0a4d1a0962f4af653b7324c5.tar.gz
dpdk-2b4e423fd4c9ed5b0a4d1a0962f4af653b7324c5.tar.xz
net/mlx4: check RSS queues number limitation
This patch verifies that the number of Rx queues configured for RSS is supported by the device hardware. RSS support in mlx4 requires contiguous chunk of QPs to be reserved, there is a hardware limitation on the amount of contiguous QPs which is reported by the hardware. Ignoring this value will cause Rx queues creation to fail. Cc: stable@dpdk.org Signed-off-by: Moti Haimovsky <motih@mellanox.com> Acked-by: Matan Azrad <matan@mellanox.com>
Diffstat (limited to 'drivers/net/mlx4/mlx4.c')
-rw-r--r--drivers/net/mlx4/mlx4.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/mlx4/mlx4.c b/drivers/net/mlx4/mlx4.c
index c67d2c0..defc0d4 100644
--- a/drivers/net/mlx4/mlx4.c
+++ b/drivers/net/mlx4/mlx4.c
@@ -673,6 +673,9 @@ mlx4_pci_probe(struct rte_pci_driver *pci_drv, struct rte_pci_device *pci_dev)
&device_attr_ex);
DEBUG("supported RSS hash fields mask: %016" PRIx64,
priv->hw_rss_sup);
+ priv->hw_rss_max_qps =
+ device_attr_ex.rss_caps.max_rwq_indirection_table_size;
+ DEBUG("MAX RSS queues %d", priv->hw_rss_max_qps);
priv->hw_fcs_strip = !!(device_attr_ex.raw_packet_caps &
IBV_RAW_PACKET_CAP_SCATTER_FCS);
DEBUG("FCS stripping toggling is %ssupported",