Message ID | 20210117080223.2107288-3-idosch@idosch.org |
---|---|
State | New |
Headers | show |
Series | None | expand |
diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c index 4ef12e3e021a..45cf6c027cac 100644 --- a/drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c +++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum_trap.c @@ -51,6 +51,8 @@ enum { enum { /* Packet was early dropped. */ MLXSW_SP_MIRROR_REASON_INGRESS_WRED = 9, + /* Packet was ECN marked. */ + MLXSW_SP_MIRROR_REASON_EGRESS_ECN = 13, }; static int mlxsw_sp_rx_listener(struct mlxsw_sp *mlxsw_sp, struct sk_buff *skb, @@ -1760,6 +1762,13 @@ mlxsw_sp2_trap_items_arr[] = { }, .is_source = true, }, + { + .trap = MLXSW_SP_TRAP_BUFFER_DROP(ECN_MARK), + .listeners_arr = { + MLXSW_SP_RXL_BUFFER_DISCARD(EGRESS_ECN), + }, + .is_source = true, + }, }; static int