diff options
author | Yotam Gigi <yotamg@mellanox.com> | 2017-10-03 09:58:10 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-10-03 10:06:30 -0700 |
commit | a0040c8c935548e1efb1a28f07f15d7ec7918055 (patch) | |
tree | 7500e0719d131947af088773127846c817c23db3 /drivers/net/ethernet/mellanox/mlxsw/trap.h | |
parent | 267872435515185e2e600a721fdddeea90f96ffa (diff) | |
download | linux-stable-a0040c8c935548e1efb1a28f07f15d7ec7918055.tar.gz linux-stable-a0040c8c935548e1efb1a28f07f15d7ec7918055.tar.bz2 linux-stable-a0040c8c935548e1efb1a28f07f15d7ec7918055.zip |
mlxsw: spectrum: Add trap for multicast trap-and-forward routes
When a multicast route is configured with trap-and-forward action, the
packets should be marked with skb->offload_mr_fwd_mark, in order to prevent
the packets from being forwarded again by the kernel ipmr module.
Due to this, it is not possible to use the already existing multicast trap
(MLXSW_TRAP_ID_ACL1) as the packet should be marked differently. Add the
MLXSW_TRAP_ID_ACL2 which is for trap-and-forward multicast routes, and set
the offload_mr_fwd_mark skb field in its handler.
Signed-off-by: Yotam Gigi <yotamg@mellanox.com>
Reviewed-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlxsw/trap.h')
-rw-r--r-- | drivers/net/ethernet/mellanox/mlxsw/trap.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlxsw/trap.h b/drivers/net/ethernet/mellanox/mlxsw/trap.h index a98103539f6b..ec6cef8267ae 100644 --- a/drivers/net/ethernet/mellanox/mlxsw/trap.h +++ b/drivers/net/ethernet/mellanox/mlxsw/trap.h @@ -93,6 +93,8 @@ enum { MLXSW_TRAP_ID_ACL0 = 0x1C0, /* Multicast trap used for routes with trap action */ MLXSW_TRAP_ID_ACL1 = 0x1C1, + /* Multicast trap used for routes with trap-and-forward action */ + MLXSW_TRAP_ID_ACL2 = 0x1C2, MLXSW_TRAP_ID_MAX = 0x1FF }; |