summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaxime Leroy <maxime.leroy@6wind.com>2013-09-02 17:14:10 +0200
committerThomas Monjalon <thomas.monjalon@6wind.com>2013-11-19 22:12:12 +0100
commit3c4724b05acc136ee08570c262fe0b736759846a (patch)
tree2df23bef59f2e2447684706eb2323f36040d375a
parent6228197cf074ed0637780e4b44b0a02cf717ef73 (diff)
downloaddpdk-stable-3c4724b05acc136ee08570c262fe0b736759846a.zip
dpdk-stable-3c4724b05acc136ee08570c262fe0b736759846a.tar.gz
dpdk-stable-3c4724b05acc136ee08570c262fe0b736759846a.tar.xz
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 <maxime.leroy@6wind.com> Acked-by: Ivan Boule <ivan.boule@6wind.com>
-rw-r--r--lib/librte_pmd_e1000/igb_rxtx.c7
-rw-r--r--lib/librte_pmd_ixgbe/ixgbe_rxtx.c7
2 files changed, 4 insertions, 10 deletions
diff --git a/lib/librte_pmd_e1000/igb_rxtx.c b/lib/librte_pmd_e1000/igb_rxtx.c
index 641ceea..8c1e2cc 100644
--- a/lib/librte_pmd_e1000/igb_rxtx.c
+++ b/lib/librte_pmd_e1000/igb_rxtx.c
@@ -1743,8 +1743,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;
@@ -1757,9 +1756,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 e1b90f9..ae9eda8 100644
--- a/lib/librte_pmd_ixgbe/ixgbe_rxtx.c
+++ b/lib/librte_pmd_ixgbe/ixgbe_rxtx.c
@@ -3215,8 +3215,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;
@@ -3232,9 +3231,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) {
/*