summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/mellanox/mlxsw/spectrum.h
diff options
context:
space:
mode:
authorJiri Pirko <jiri@mellanox.com>2019-02-07 11:22:51 +0000
committerDavid S. Miller <davem@davemloft.net>2019-02-08 15:02:49 -0800
commit29a2102a29085f5505d86bd3cbfe11c6fa08340d (patch)
tree5d9e489d5c98ee918b8cee5d1741ceb63187cb5a /drivers/net/ethernet/mellanox/mlxsw/spectrum.h
parentc4c2dc54293c556b8a05b9da024f92f8225a9eb8 (diff)
mlxsw: spectrum_acl: Implement basic ERP rehash hits creation
Introduce an initial implementation of rehash logic in ERP code. Currently, the rehash is considered as needed only in case number of roots in the hints is smaller than the number of roots actually in use. In that case return hints pointer and let it be obtained through the callpath through the Spectrum-2 TCAM op. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlxsw/spectrum.h')
-rw-r--r--drivers/net/ethernet/mellanox/mlxsw/spectrum.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum.h b/drivers/net/ethernet/mellanox/mlxsw/spectrum.h
index 4fe0996c7cdd..6432a1ce51f3 100644
--- a/drivers/net/ethernet/mellanox/mlxsw/spectrum.h
+++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum.h
@@ -708,6 +708,8 @@ struct mlxsw_sp_acl_tcam_ops {
void (*region_fini)(struct mlxsw_sp *mlxsw_sp, void *region_priv);
int (*region_associate)(struct mlxsw_sp *mlxsw_sp,
struct mlxsw_sp_acl_tcam_region *region);
+ void * (*region_rehash_hints_get)(void *region_priv);
+ void (*region_rehash_hints_put)(void *hints_priv);
size_t chunk_priv_size;
void (*chunk_init)(void *region_priv, void *chunk_priv,
unsigned int priority);