]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum_span: Add APIs to get / put a SPAN agent
authorIdo Schimmel <idosch@mellanox.com>
Thu, 30 Apr 2020 17:01:08 +0000 (20:01 +0300)
committerDavid S. Miller <davem@davemloft.net>
Thu, 30 Apr 2020 20:02:32 +0000 (13:02 -0700)
commit640477de6ba4eedc36513079ed02ca1bd050078a
treecdeda56665312ac3a7288657f87f52140cb19c8a
parentef61c7bb35f5801e2192eba707d8b8d4f15fd76b
mlxsw: spectrum_span: Add APIs to get / put a SPAN agent

Given a netdev that packets should be mirrored to, create a SPAN agent
and return its identifier to the caller.

The SPAN agent is reference counted, as multiple tc-mirred actions can
point to the same destination netdev.

Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Reviewed-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum_span.c
drivers/net/ethernet/mellanox/mlxsw/spectrum_span.h