net/mlx5: set representor to first PF in bonding mode
authorXueming Li <xuemingl@nvidia.com>
Tue, 17 Nov 2020 11:01:38 +0000 (11:01 +0000)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 20 Nov 2020 20:10:05 +0000 (21:10 +0100)
commite6818853c022e3ae62d05421860063f7a6c731af
tree0d993e4e875bdfb5d0224575744f2d32e1a602a3
parent38c6dc20394b28abd0440dbdd2f9309eb4c95ccc
net/mlx5: set representor to first PF in bonding mode

When the representor device was set to PF1 in bonding mode, iterating
device iterator that looking for representors by bonding device failed
to match PF0 pci address with PF1 address. So detaching PF bonding
device only detached all representors on PF0.

This patch registers all representors of PF1 with PF0 as PCI device.

Signed-off-by: Xueming Li <xuemingl@nvidia.com>
Reviewed-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
drivers/net/mlx5/linux/mlx5_os.c
drivers/net/mlx5/mlx5.c
drivers/net/mlx5/mlx5.h