]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit - drivers/net/ethernet/mellanox/mlxsw/spectrum_span.c
mlxsw: spectrum_span: Add driver private info to parms_set() callback
authorIdo Schimmel <idosch@mellanox.com>
Tue, 14 Jul 2020 14:20:57 +0000 (17:20 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 14 Jul 2020 21:50:49 +0000 (14:50 -0700)
commitf4a626e2ca09aeffd30509349759fb30379fe83f
treec4e91a010420fe468d1ee4ec25d2837a715fb8eb
parent34e4ace56f106f6fc5050b8e4c6041bca78a431c
mlxsw: spectrum_span: Add driver private info to parms_set() callback

The parms_set() callback is supposed to fill in the parameters for the
SPAN agent, such as the destination port and encapsulation info, if any.

When mirroring to the CPU port we cannot resolve the destination port
(the CPU port) without access to the driver private info.

Pass the driver private info to parms_set() callback so that it could be
used later on to resolve the CPU port.

Reviewed-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: Petr Machata <petrm@mellanox.com>
Signed-off-by: Ido Schimmel <idosch@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