brintos

brintos / linux-shallow public Read only

0
0
Text · 822 B · 15c8d4d Raw
26 lines · c
1/* SPDX-License-Identifier: BSD-3-Clause OR GPL-2.0 */2/* Copyright (c) 2017-2018 Mellanox Technologies. All rights reserved */3 4#ifndef _MLXSW_SPECTRUM_CNT_H5#define _MLXSW_SPECTRUM_CNT_H6 7#include "core.h"8#include "spectrum.h"9 10enum mlxsw_sp_counter_sub_pool_id {11	MLXSW_SP_COUNTER_SUB_POOL_RIF,12	MLXSW_SP_COUNTER_SUB_POOL_FLOW,13};14 15int mlxsw_sp_counter_alloc(struct mlxsw_sp *mlxsw_sp,16			   enum mlxsw_sp_counter_sub_pool_id sub_pool_id,17			   unsigned int *p_counter_index);18void mlxsw_sp_counter_free(struct mlxsw_sp *mlxsw_sp,19			   enum mlxsw_sp_counter_sub_pool_id sub_pool_id,20			   unsigned int counter_index);21int mlxsw_sp_counter_pool_init(struct mlxsw_sp *mlxsw_sp);22void mlxsw_sp_counter_pool_fini(struct mlxsw_sp *mlxsw_sp);23int mlxsw_sp_counter_resources_register(struct mlxsw_core *mlxsw_core);24 25#endif26