]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5: E-Switch, Properly refer to the esw manager vport
authorBodong Wang <bodong@mellanox.com>
Thu, 8 Nov 2018 20:37:04 +0000 (22:37 +0200)
committerSaeed Mahameed <saeedm@mellanox.com>
Sat, 16 Feb 2019 01:25:56 +0000 (17:25 -0800)
commitfb4a79625a82d8638c88e5688c4ca1a1e302ef44
treed469ac6c34d850adb78e7e1bf0ba379955c01ffd
parent42a97799828d9c237508b3e87792fc18e19d38c0
net/mlx5: E-Switch, Properly refer to the esw manager vport

In SmartNIC mode, the eswitch manager is not necessarily the PF
(vport 0). Use a helper function to get the correct eswitch manager
vport number and cache on the eswitch instance for fast reference.

Signed-off-by: Bodong Wang <bodong@mellanox.com>
Signed-off-by: Eli Cohen <eli@mellanox.com>
Reviewed-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/eswitch.c
drivers/net/ethernet/mellanox/mlx5/core/eswitch.h
drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c
include/linux/mlx5/vport.h