stats: refactor vlib counters
Change-Id: I09d2da73eff42c52ba1373acc99ff28f283a6725
Type: improvement
Signed-off-by: Damjan Marion <damarion@cisco.com>
diff --git a/src/vlib/stats/init.c b/src/vlib/stats/init.c
index d24c158..3dba102 100644
--- a/src/vlib/stats/init.c
+++ b/src/vlib/stats/init.c
@@ -17,7 +17,7 @@
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 @@
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;
}