]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5: E-switch, Enable metadata on own vport
authorParav Pandit <parav@mellanox.com>
Mon, 28 Oct 2019 23:35:28 +0000 (23:35 +0000)
committerSaeed Mahameed <saeedm@mellanox.com>
Fri, 1 Nov 2019 21:40:27 +0000 (14:40 -0700)
commit44d5534b3a5c97b05fd34add93c50cb915919ef6
treec599bacb8e593c63c58a246c57357a3d24a05fce
parente749ce63c1f7eb5b700f843b97a9a2f709d482a9
net/mlx5: E-switch, Enable metadata on own vport

Currently on ECPF, metadata is enabled on the ECPF vport = 0xfffe
(manager vport).
Metadata when supported, must be enabled on own vport which is
used to pass metadata to vport of NIC Rx Flow Table.

Due to this error, traffic tagged by ingress ACL is not processed
correctly at NIC rx flow table level which is supposed to work
on metadata tag.

Hence, instead of working on eswitch manager vport, always working on
eswitch own vport regardless of PF or ECPF.

Given that mlx5_eswitch_query/modify_esw_vport_context() is used to
access other vport in legacy mode and own vport settings in switchdev mode,
extend low level API to explicitly specify other_vport.

Fixes: 14495ffb689f ("net/mlx5: E-Switch, Pass metadata from FDB to eswitch manager")
Signed-off-by: Parav Pandit <parav@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