]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum_acl: Add region association callback
authorIdo Schimmel <idosch@mellanox.com>
Wed, 18 Jul 2018 08:14:43 +0000 (11:14 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 18 Jul 2018 17:13:14 +0000 (02:13 +0900)
commita6b9c87daf5d1de84d915edb9f240276269df1f2
tree709d7cd1ad38158f1c845fa3809297858b7d9f5a
parent7a921a1e585a846e039239238aaec0a516477e14
mlxsw: spectrum_acl: Add region association callback

In Spectrum-2, ACL regions that use 8 or 12 key blocks require several
consecutive hardware regions.

In order to allow defragmentation, the device stores a mapping from a
logical region ID to an hardware region ID, which is similar to the page
table that is used to translate virtual addresses to physical addresses.

Add the region association callback to the region create sequence and
implement it as a NOP in Spectrum which does not require it.

Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum.h
drivers/net/ethernet/mellanox/mlxsw/spectrum1_acl_tcam.c
drivers/net/ethernet/mellanox/mlxsw/spectrum_acl_tcam.c