mlxsw: spectrum_qdisc: Distinguish between ingress and egress triggers
authorPetr Machata <petrm@nvidia.com>
Sun, 10 Oct 2021 11:40:14 +0000 (14:40 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 12 Oct 2021 10:19:35 +0000 (11:19 +0100)
commit0908e42ad9a5965eb89028f286c1056bf56978b7
tree18d1c1f89f33b7704e4c645bec91db11044d5e96
parenta34dda7284304046adaca2685777e86927c58317
mlxsw: spectrum_qdisc: Distinguish between ingress and egress triggers

The following patches will configure the MLXSW_SP_SPAN_TRIGGER_ECN
mirroring trigger. This trigger is considered "egress", unlike the
previously-offloaded _EARLY_DROP. Add a helper to spectrum_span,
mlxsw_sp_span_trigger_is_ingress(), to classify triggers to ingress and
egress. Pass result of this instead of hardcoding true when calling
mlxsw_sp_span_analyzed_port_get()/_put().

Signed-off-by: Petr Machata <petrm@nvidia.com>
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c
drivers/net/ethernet/mellanox/mlxsw/spectrum_span.c
drivers/net/ethernet/mellanox/mlxsw/spectrum_span.h