diff options
author | Damjan Marion <damarion@cisco.com> | 2022-03-14 13:04:38 +0100 |
---|---|---|
committer | Florin Coras <florin.coras@gmail.com> | 2022-03-14 20:30:06 +0000 |
commit | 58fd481d73dce9c276facb42b9a9c3488c25417d (patch) | |
tree | f299759229f606fdf83722c6682665e06e286fad /src/vlib/stats/init.c | |
parent | 92991e5c690e8ad55f9cf0fdb81c26c1d1143b7d (diff) |
stats: refactor vlib counters
Change-Id: I09d2da73eff42c52ba1373acc99ff28f283a6725
Type: improvement
Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vlib/stats/init.c')
-rw-r--r-- | src/vlib/stats/init.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/vlib/stats/init.c b/src/vlib/stats/init.c index d24c1580a88..3dba1022b52 100644 --- a/src/vlib/stats/init.c +++ b/src/vlib/stats/init.c @@ -17,7 +17,7 @@ vector_rate_collector_fn (vlib_stats_collector_data_t *d) f64 vector_rate = 0.0; u32 i, n_threads = vlib_get_n_threads (); - vlib_stats_validate_counter_vector (d->entry_index, n_threads - 1); + vlib_stats_validate (d->entry_index, 0, n_threads - 1); for (i = 0; i < n_threads; i++) { @@ -118,7 +118,7 @@ vlib_stats_init (vlib_main_t *vm) reg.entry_index = vlib_stats_add_counter_vector ("/sys/vector_rate_per_worker"); vlib_stats_register_collector_fn (®); - vlib_stats_validate_counter_vector (reg.entry_index, vlib_get_n_threads ()); + vlib_stats_validate (reg.entry_index, 0, vlib_get_n_threads ()); return 0; } |