{net, RDMA}/mlx5: Extend send to vport rules
authorMark Bloch <mbloch@nvidia.com>
Tue, 3 Aug 2021 23:19:49 +0000 (16:19 -0700)
committerSaeed Mahameed <saeedm@nvidia.com>
Thu, 5 Aug 2021 20:49:24 +0000 (13:49 -0700)
commit979bf468fc543444eb750c8f8817407f509bd504
treea666373ae3c1a82fbb0b320a6ebb5462c79298c7
parent6aeb16a1345e480bd395b9168570e93c902a05f3
{net, RDMA}/mlx5: Extend send to vport rules

In shared FDB there is only one eswitch which is active and it receives
traffic from all representors and all vports in the HCA.

While the Ethernet representor will always reside on its native PF
the IB representor will not. Extend send to vport rule creation to
support such flows. Need to account for source vport that sends the
traffic (on which the representors resides) and the target eswitch
the traffic which reach.

Signed-off-by: Mark Bloch <mbloch@nvidia.com>
Reviewed-by: Mark Zhang <markzhang@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
drivers/infiniband/hw/mlx5/ib_rep.c
drivers/net/ethernet/mellanox/mlx5/core/en_rep.c
drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c
include/linux/mlx5/eswitch.h