OSDN Git Service

net/mlx5: Introduce vport metadata matching bits and enum constants
authorJianbo Liu <jianbol@mellanox.com>
Tue, 25 Jun 2019 17:47:50 +0000 (17:47 +0000)
committerSaeed Mahameed <saeedm@mellanox.com>
Wed, 26 Jun 2019 19:01:28 +0000 (12:01 -0700)
commit65c0f2c1663649217455a73d48b1c303f133180a
tree661ecd5f2d08a7de1231bf85166b4dbb3f0d2f0e
parent792c4e9d0bbb53b34bf1c07c2ef25609d746c57d
net/mlx5: Introduce vport metadata matching bits and enum constants

When a dual-port VHCA sends a RoCE packet on its non-native port, and
the packet arrives to its affiliated vport FDB, a mismatch might occur
on the rules that match the packet source vport. So we replace the
match on source port with the match on metadata that was configured in
ingress ACL, and that metadata will be passed further also to the NIC
RX table of the eswitch manager.

Introduce vport metadata matching bits and enum constants as a pre-step
towards metadata matching.
    o metadata type C registers in the misc parameters 2 fields.
    o esw_uplink_ingress_acl bit in esw cap. If it set, the device supports
      ingress ACL for the uplink vport.
    o fdb_to_vport_reg_* bits in flow table cap and esw vport context, to
      support propagating the metadata to the nic rx through the loopback
      path.
    o flow_source in flow context, to indicate the known origin of packets.
    o enum constants, to support the above bits.

Signed-off-by: Jianbo Liu <jianbol@mellanox.com>
Reviewed-by: Eli Britstein <elibr@mellanox.com>
Reviewed-by: Roi Dayan <roid@mellanox.com>
Reviewed-by: Mark Bloch <markb@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
include/linux/mlx5/mlx5_ifc.h