[1/2] Revert "bus/pci: add Mellanox kernel driver type"

Message ID 1562795329-16652-2-git-send-email-david.marchand@redhat.com
State Superseded
Delegated to: Thomas Monjalon
Headers show
Series
  • Fixes on IOVA mode selection
Related show

Checks

Context Check Description
ci/Intel-compilation success Compilation OK
ci/mellanox-Performance-Testing success Performance Testing PASS
ci/intel-Performance-Testing success Performance Testing PASS
ci/checkpatch success coding style OK

Commit Message

David Marchand July 10, 2019, 9:48 p.m.
This reverts commit 0cb86518db57d35e0abc14d6703fad561a0310e2.

The pci bus now reports DC when faced with a device bound to an unknown
driver and, in such a case, the IOVA mode is selected against physical
address availability.

As a consequence, there is no reason for this special case for Mellanox
drivers.

Fixes: 703458e19c16 ("bus/pci: consider only usable devices for IOVA mode")

Signed-off-by: David Marchand <david.marchand@redhat.com>
---
 drivers/bus/pci/linux/pci.c             | 8 --------
 lib/librte_eal/common/include/rte_dev.h | 1 -
 2 files changed, 9 deletions(-)

Comments

Jerin Jacob Kollanukkaran July 16, 2019, 10:37 a.m. | #1
> -----Original Message-----
> From: David Marchand <david.marchand@redhat.com>
> Sent: Thursday, July 11, 2019 3:19 AM
> To: dev@dpdk.org
> Cc: anatoly.burakov@intel.com; Jerin Jacob Kollanukkaran
> <jerinj@marvell.com>; thomas@monjalon.net
> Subject: [EXT] [PATCH 1/2] Revert "bus/pci: add Mellanox kernel driver type"
> 
> This reverts commit 0cb86518db57d35e0abc14d6703fad561a0310e2.
> 
> The pci bus now reports DC when faced with a device bound to an unknown
> driver and, in such a case, the IOVA mode is selected against physical address
> availability.
> 
> As a consequence, there is no reason for this special case for Mellanox
> drivers.
> 
> Fixes: 703458e19c16 ("bus/pci: consider only usable devices for IOVA mode")
> 
> Signed-off-by: David Marchand <david.marchand@redhat.com>

Reviewed-by: Jerin Jacob <jerinj@marvell.com>

Patch

diff --git a/drivers/bus/pci/linux/pci.c b/drivers/bus/pci/linux/pci.c
index 33c8ea7..b12f10a 100644
--- a/drivers/bus/pci/linux/pci.c
+++ b/drivers/bus/pci/linux/pci.c
@@ -329,9 +329,6 @@ 
 			dev->kdrv = RTE_KDRV_IGB_UIO;
 		else if (!strcmp(driver, "uio_pci_generic"))
 			dev->kdrv = RTE_KDRV_UIO_GENERIC;
-		else if (!strcmp(driver, "mlx4_core") ||
-				!strcmp(driver, "mlx5_core"))
-			dev->kdrv = RTE_KDRV_NIC_MLX;
 		else
 			dev->kdrv = RTE_KDRV_UNKNOWN;
 	} else
@@ -591,11 +588,6 @@  enum rte_iova_mode
 		break;
 	}
 
-	case RTE_KDRV_NIC_MLX:
-		if ((pdrv->drv_flags & RTE_PCI_DRV_IOVA_AS_VA) == 0)
-			iova_mode = RTE_IOVA_PA;
-		break;
-
 	case RTE_KDRV_IGB_UIO:
 	case RTE_KDRV_UIO_GENERIC:
 		iova_mode = RTE_IOVA_PA;
diff --git a/lib/librte_eal/common/include/rte_dev.h b/lib/librte_eal/common/include/rte_dev.h
index 94829f6..c25e09e 100644
--- a/lib/librte_eal/common/include/rte_dev.h
+++ b/lib/librte_eal/common/include/rte_dev.h
@@ -63,7 +63,6 @@  enum rte_kernel_driver {
 	RTE_KDRV_VFIO,
 	RTE_KDRV_UIO_GENERIC,
 	RTE_KDRV_NIC_UIO,
-	RTE_KDRV_NIC_MLX,
 	RTE_KDRV_NONE,
 };