mlxsw: spectrum_nve: Implement common NVE core
authorIdo Schimmel <idosch@mellanox.com>
Wed, 17 Oct 2018 08:53:14 +0000 (08:53 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 18 Oct 2018 00:45:07 +0000 (17:45 -0700)
commit6e6030bd5412182e064139821ffb09c373e46829
tree80be2e17f16d63a92a4a54b2bc3faf8e720fc85b
parent28e450333d4d1328710e258d38793c61658d4c95
mlxsw: spectrum_nve: Implement common NVE core

The Spectrum ASIC supports different types of NVE encapsulations (e.g.,
VxLAN, NVGRE) with more types to be supported by future ASICs.

Despite being different, all these encapsulations share some common
functionality such as the enablement of NVE encapsulation on a given
filtering identifier (FID) and the addition of remote VTEPs to the
linked-list of VTEPs that traffic should be flooded to.

Implement this common core and allow different ASICs to register
different operations for different encapsulation types.

Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Reviewed-by: Petr Machata <petrm@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/Makefile
drivers/net/ethernet/mellanox/mlxsw/spectrum.c
drivers/net/ethernet/mellanox/mlxsw/spectrum.h
drivers/net/ethernet/mellanox/mlxsw/spectrum_nve.c [new file with mode: 0644]
drivers/net/ethernet/mellanox/mlxsw/spectrum_nve.h [new file with mode: 0644]
drivers/net/ethernet/mellanox/mlxsw/spectrum_nve_vxlan.c [new file with mode: 0644]