Skip to contentSkip to conversation

net/ixgbe: fix l3fwd start failed on VF

PATCH Superseded Yanglong Wu 3 participants 4 messages Nov 2, 2017 – Nov 7, 2017 Network drivers

v1 of 6 Superseded Latest is v6 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 net/ixgbe: fix l3fwd start failed on VF

VF can't run in multi queue module,if nb_q_per_pool was set as 1. Since the value of nb_q_per_pool pass through to max_rx_q and max_tx_q in VF.

Fixes 27b609cbd1c6 ("ethdev: move the multi-queue mode check to specific drivers")
---
 drivers/net/ixgbe/ixgbe_ethdev.c | 2 --
 1 file changed, 2 deletions(-)
drivers/net/ixgbe/ixgbe_ethdev.c +0 -2
index 14b9c5303..ae9c44421 100644
@@ -2222,8 +2222,6 @@ ixgbe_check_mq_mode(struct rte_eth_dev *dev)
 		case ETH_MQ_RX_NONE:
 			/* if nothing mq mode configure, use default scheme */
 			dev->data->dev_conf.rxmode.mq_mode = ETH_MQ_RX_VMDQ_ONLY;
-			if (RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool > 1)
-				RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool = 1;
 			break;
 		default: /* ETH_MQ_RX_DCB, ETH_MQ_RX_DCB_RSS or ETH_MQ_TX_DCB*/
 			/* SRIOV only works in VMDq enable mode */
Signature · 1 line
2.11.0
#1 lore raw

PATCH 2/2 net/ixgbe: fix l3fwd start failed on PF

which occurred when the SRIOV is active and tx_q > rx_q. The number of nb_q_per_pool should equeal to max number of queues supported by HW not nb_rx_q.

Fixes 27b609cbd1c6 (ethdev: move the multi-queue mode

check to specific drivers)

---
 drivers/net/ixgbe/ixgbe_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ixgbe/ixgbe_ethdev.c +1 -1
index ae9c44421..0f0641da1 100644
@@ -2180,7 +2180,7 @@ ixgbe_check_vf_rss_rxq_num(struct rte_eth_dev *dev, uint16_t nb_rx_q)
 		return -EINVAL;
 	}
 
-	RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool = nb_rx_q;
+	RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool = 128/RTE_ETH_DEV_SRIOV(dev).active;
 	RTE_ETH_DEV_SRIOV(dev).def_pool_q_idx = pci_dev->max_vfs * nb_rx_q;
 
 	return 0;
Signature · 1 line
2.11.0
#2 lore raw

Re: [PATCH 2/2] net/ixgbe: fix l3fwd start failed on PF

Hi,

Quoted 33 lines

-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Yanglong Wu
Sent: Thursday, November 2, 2017 5:05 PM
To: [email protected]
Cc: Wu, Yanglong <[email protected]>
Subject: [dpdk-dev] [PATCH 2/2] net/ixgbe: fix l3fwd start failed on PF

which occurred when the SRIOV is active and tx_q > rx_q. The number of nb_q_per_pool should equeal to max number of queues supported by HW not nb_rx_q.

Fixes 27b609cbd1c6 (ethdev: move the multi-queue mode

check to specific drivers)

---
 drivers/net/ixgbe/ixgbe_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ixgbe/ixgbe_ethdev.c +1 -2
index ae9c44421..0f0641da1 100644
@@ -2180,7 +2180,7 @@ ixgbe_check_vf_rss_rxq_num(struct rte_eth_dev *dev, uint16_t nb_rx_q)
 		return -EINVAL;
 	}
 
-	RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool = nb_rx_q;
+	RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool = 128/RTE_ETH_DEV_SRIOV(dev).active;
 	RTE_ETH_DEV_SRIOV(dev).def_pool_q_idx = pci_dev->max_vfs * nb_rx_q;
 
 	return 0;
--
Quoted 1 line

2.11.0

Not sure I understand what is the purpose of that patch... Do you want to prevent RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool = 1? Konstantin

#3 lore raw

Re: [PATCH 2/2] net/ixgbe: fix l3fwd start failed on PF

Quoted 43 lines

-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Ananyev, Konstantin
Sent: Thursday, November 2, 2017 10:06 PM
To: Wu, Yanglong <[email protected]>; [email protected]
Cc: Wu, Yanglong <[email protected]>
Subject: Re: [dpdk-dev] [PATCH 2/2] net/ixgbe: fix l3fwd start failed on PF

Hi,

drivers/net/ixgbe/ixgbe_ethdev.c ixgbe_check_vf_rss_rxq_num(struct rte_eth_dev *dev,

Quoted 24 lines

-----Original Message-----
From: dev [mailto:[email protected]] On Behalf Of Yanglong Wu
Sent: Thursday, November 2, 2017 5:05 PM
To: [email protected]
Cc: Wu, Yanglong <[email protected]>
Subject: [dpdk-dev] [PATCH 2/2] net/ixgbe: fix l3fwd start failed on PF

which occurred when the SRIOV is active and tx_q > rx_q. The number of nb_q_per_pool should equeal to max number of queues supported by HW not nb_rx_q.

Fixes 27b609cbd1c6 (ethdev: move the multi-queue mode

check to specific drivers)

---
 drivers/net/ixgbe/ixgbe_ethdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ixgbe/ixgbe_ethdev.c +0 -0
index ae9c44421..0f0641da1 100644
@@ -2180,7 +2180,7 @@ ixgbe_check_vf_rss_rxq_num(struct rte_eth_dev *dev,

uint16_t nb_rx_q)

Quoted 7 lines
drivers/net/ixgbe/ixgbe_ethdev.c +1 -1
 		return -EINVAL;
 	}
 
-	RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool = nb_rx_q;
+	RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool = 128/RTE_ETH_DEV_SRIOV(dev).active;
 	RTE_ETH_DEV_SRIOV(dev).def_pool_q_idx = pci_dev->max_vfs * nb_rx_q;
 
Quoted 8 lines
Quoted 3 lines
drivers/net/ixgbe/ixgbe_ethdev.c +0 -1
 	return 0;
--

2.11.0

Not sure I understand what is the purpose of that patch... Do you want to prevent RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool = 1? Konstantin

I think his purpose is to set the RTE_ETH_DEV_SRIOV(dev).nb_q_per_pool to be the max number of queues in one pool according to the how to split the queue index.

Now, for rss and virtualization mode, ixgbe has combination like 2 queues * 64 pools and 4 queues * 32 pools.

BTW, I think the title of this patch need to be reword. It looks confusing if it is a bug in ixgbe.

Quoted 3 lines