net/mlx5: support VF PCI address on Windows
authorTal Shnaiderman <talshn@nvidia.com>
Mon, 28 Dec 2020 12:32:47 +0000 (14:32 +0200)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 8 Jan 2021 15:03:08 +0000 (16:03 +0100)
commite7252614cdffb356cb2458b03ce90f4d6c884ed9
treef4b7e4bea025538dfce4f0b16f96e035355ceb25
parent93f4ece91a1f6b338cbe3272cfdadde5b402fa3d
net/mlx5: support VF PCI address on Windows

Support VF BDF scanning by checking both the BDF and raw BDF provided by
DevX. In Linux a PCI address is formatted as: domain, bus, device,
function (DBDF).  This is right for both a PF and a VF. In Windows a PF
also has a DBDF format, but the domain is always 0, while a VF has a
special "domain" called "Virtual PCI Bus, Serial" (for example: "Virtual
PCI Bus Slot 2 Serial 2") or segment.  The full VF format under Windows
is called raw DBF.  Windows special domain must be considered and DevX
must be called to support it.

Signed-off-by: Tal Shnaiderman <talshn@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
drivers/net/mlx5/windows/mlx5_os.c