From: Maxime Leroy Date: Mon, 2 Sep 2013 15:14:10 +0000 (+0200) Subject: igb/ixgbe: allow RSS with only one Rx queue X-Git-Tag: spdx-start~11019 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=3aa1e71982f866648e698e5713e2d818491479ff;p=dpdk.git igb/ixgbe: allow RSS with only one Rx queue It should be possible to enable RSS with one Rx queue. RSS hash can be useful independently of the number of Rx queues. Applications can use RSS hash to identify different IP flows. Signed-off-by: Maxime Leroy Acked-by: Ivan Boule --- diff --git a/lib/librte_pmd_e1000/igb_rxtx.c b/lib/librte_pmd_e1000/igb_rxtx.c index 7e7bd4b854..cb3b10a582 100644 --- a/lib/librte_pmd_e1000/igb_rxtx.c +++ b/lib/librte_pmd_e1000/igb_rxtx.c @@ -1753,8 +1753,7 @@ igb_dev_mq_rx_configure(struct rte_eth_dev *dev) /* * SRIOV inactive scheme */ - if (dev->data->nb_rx_queues > 1) - switch (dev->data->dev_conf.rxmode.mq_mode) { + switch (dev->data->dev_conf.rxmode.mq_mode) { case ETH_MQ_RX_RSS: igb_rss_configure(dev); break; @@ -1767,9 +1766,7 @@ igb_dev_mq_rx_configure(struct rte_eth_dev *dev) default: igb_rss_disable(dev); break; - } - else - igb_rss_disable(dev); + } } return 0; diff --git a/lib/librte_pmd_ixgbe/ixgbe_rxtx.c b/lib/librte_pmd_ixgbe/ixgbe_rxtx.c index b63aefe136..7415ddc0f7 100644 --- a/lib/librte_pmd_ixgbe/ixgbe_rxtx.c +++ b/lib/librte_pmd_ixgbe/ixgbe_rxtx.c @@ -3226,8 +3226,7 @@ ixgbe_dev_mq_rx_configure(struct rte_eth_dev *dev) * SRIOV inactive scheme * any DCB/RSS w/o VMDq multi-queue setting */ - if (dev->data->nb_rx_queues > 1) - switch (dev->data->dev_conf.rxmode.mq_mode) { + switch (dev->data->dev_conf.rxmode.mq_mode) { case ETH_MQ_RX_RSS: ixgbe_rss_configure(dev); break; @@ -3243,9 +3242,7 @@ ixgbe_dev_mq_rx_configure(struct rte_eth_dev *dev) case ETH_MQ_RX_NONE: /* if mq_mode is none, disable rss mode.*/ default: ixgbe_rss_disable(dev); - } - else - ixgbe_rss_disable(dev); + } } else { switch (RTE_ETH_DEV_SRIOV(dev).active) { /*