Skip to contentSkip to conversation

net/memif: fix multi-process device probe error

PATCH Superseded Phil Yang 2 participants 6 messages Aug 1, 2019 – Aug 6, 2019 Network drivers

lore
Share & tools
lore

Phil Yang

author
#0 lore raw

PATCH 1/1 net/memif: fix multi-process device probe error

Fixes c41a04958b ("net/memif: support multi-process")
---
 drivers/net/memif/rte_eth_memif.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/memif/rte_eth_memif.c +1 -1
index bcda426..a59f809 100644
@@ -1265,7 +1265,7 @@ rte_pmd_memif_probe(struct rte_vdev_device *vdev)
 		eth_dev->dev_ops = &ops;
 		eth_dev->device = &vdev->device;
 		eth_dev->rx_pkt_burst = eth_memif_rx;
-		eth_dev->tx_pkt_burst = eth_memif_rx;
+		eth_dev->tx_pkt_burst = eth_memif_tx;
 
 		if (!rte_eal_primary_proc_alive(NULL)) {
 			MIF_LOG(ERR, "Primary process is missing");
Signature · 1 line
2.7.4
#1 lore raw

01/08/2019 12:35, Phil Yang:

drivers/net/memif/rte_eth_memif.c rte_pmd_memif_probe(struct rte_vdev_device *vdev) · line 1268

Quoted 13 lines
Fixes c41a04958b ("net/memif: support multi-process")

---

drivers/net/memif/rte_eth_memif.c +1 -1
@@ -1265,7 +1265,7 @@ rte_pmd_memif_probe(struct rte_vdev_device *vdev)
 		eth_dev->dev_ops = &ops;
 		eth_dev->device = &vdev->device;
 		eth_dev->rx_pkt_burst = eth_memif_rx;
-		eth_dev->tx_pkt_burst = eth_memif_rx;
+		eth_dev->tx_pkt_burst = eth_memif_tx;

It is not a probe error, but malfunctioning device, right? What is the current behaviour? You could better explain the symptom in the commit log, and the root cause (typo).

#2 lore raw

02/08/2019 23:01, Thomas Monjalon:

Quoted 18 lines

01/08/2019 12:35, Phil Yang:

drivers/net/memif/rte_eth_memif.c rte_pmd_memif_probe(struct rte_vdev_device *vdev) · line 1268

Quoted 13 lines
Fixes c41a04958b ("net/memif: support multi-process")

---

drivers/net/memif/rte_eth_memif.c +1 -1
@@ -1265,7 +1265,7 @@ rte_pmd_memif_probe(struct rte_vdev_device *vdev)
 		eth_dev->dev_ops = &ops;
 		eth_dev->device = &vdev->device;
 		eth_dev->rx_pkt_burst = eth_memif_rx;
-		eth_dev->tx_pkt_burst = eth_memif_rx;
+		eth_dev->tx_pkt_burst = eth_memif_tx;

It is not a probe error, but malfunctioning device, right? What is the current behaviour? You could better explain the symptom in the commit log, and the root cause (typo).

Nobody is replying or sending a v2?
Jakub?

#3 lore raw
Quoted 15 lines

-----Original Message-----
From: Thomas Monjalon <[email protected]>
Sent: Tuesday, August 6, 2019 4:08 PM
To: Phil Yang (Arm Technology China) <[email protected]>; [email protected]
Cc: [email protected]; [email protected]; [email protected]; Gavin Hu (Arm Technology China) <[email protected]>; Honnappa Nagarahalli <[email protected]>; nd <[email protected]>
Subject: Re: [dpdk-dev] [PATCH] net/memif: fix multi-process device probe error

02/08/2019 23:01, Thomas Monjalon:

Quoted 3 lines

01/08/2019 12:35, Phil Yang:

Quoted 2 lines
Fixes c41a04958b ("net/memif: support multi-process")
Quoted 13 lines
Quoted 6 lines

drivers/net/memif/rte_eth_memif.c rte_pmd_memif_probe(struct

Quoted 6 lines

---

drivers/net/memif/rte_eth_memif.c +0 -0
@@ -1265,7 +1265,7 @@ rte_pmd_memif_probe(struct

rte_vdev_device *vdev)

Quoted 6 lines
Quoted 5 lines
drivers/net/memif/rte_eth_memif.c +1 -1
 		eth_dev->dev_ops = &ops;
 		eth_dev->device = &vdev->device;
 		eth_dev->rx_pkt_burst = eth_memif_rx;
-		eth_dev->tx_pkt_burst = eth_memif_rx;
+		eth_dev->tx_pkt_burst = eth_memif_tx;

Hi Thomas,

Sorry for the later response.

Quoted 1 line
Quoted 1 line

It is not a probe error, but malfunctioning device, right?

Yes, agree.

Quoted 2 lines
Quoted 2 lines

What is the current behaviour? You could better explain the symptom in the commit log, and the root cause (typo).

Since testpmd has issues working as a secondary process, so I cannot get the typo for this issue. But in logically, the memif PMD should use eth_memif_tx in the egress path.

I will update the commit log in v2.

Quoted 4 lines

Nobody is replying or sending a v2?
Jakub?

Thanks,
Phil

author
#4 lore raw

PATCH v2 1/1 net/memif: fix multi-process malfunctioning device

In reply to Phil Yang

When working as a secondary process, it uses eth_memif_rx in PMD egress. It should be eth_memif_tx.

Fixes c41a04958b ("net/memif: support multi-process")

---
v2:
Add descriptions in commit log.

v1:
Initial version.

 drivers/net/memif/rte_eth_memif.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/memif/rte_eth_memif.c +1 -1
index bcda426..a59f809 100644
@@ -1265,7 +1265,7 @@ rte_pmd_memif_probe(struct rte_vdev_device *vdev)
 		eth_dev->dev_ops = &ops;
 		eth_dev->device = &vdev->device;
 		eth_dev->rx_pkt_burst = eth_memif_rx;
-		eth_dev->tx_pkt_burst = eth_memif_rx;
+		eth_dev->tx_pkt_burst = eth_memif_tx;
 
 		if (!rte_eal_primary_proc_alive(NULL)) {
 			MIF_LOG(ERR, "Primary process is missing");
Signature · 1 line
2.7.4
#5 lore raw

Re: [dpdk-dev] [PATCH v2] net/memif: fix multi-process malfunctioning device

06/08/2019 10:45, Phil Yang:

Quoted 7 lines

When working as a secondary process, it uses eth_memif_rx in PMD egress. It should be eth_memif_tx.

Fixes c41a04958b ("net/memif: support multi-process")

Applied, thanks

Instead of the vague "malfunctioning device",
I replaced with "Tx" in the title.