MCPcopy Create free account
hub / github.com/F-Stack/f-stack / rte_timer_stop_all

Function rte_timer_stop_all

dpdk/lib/timer/rte_timer.c:973–1003  ·  view source on GitHub ↗

Walk pending lists, stopping timers and calling user-specified function */

Source from the content-addressed store, hash-verified

971
972/* Walk pending lists, stopping timers and calling user-specified function */
973int
974rte_timer_stop_all(uint32_t timer_data_id, unsigned int *walk_lcores,
975 int nb_walk_lcores,
976 rte_timer_stop_all_cb_t f, void *f_arg)
977{
978 int i;
979 struct priv_timer *priv_timer;
980 uint32_t walk_lcore;
981 struct rte_timer *tim, *next_tim;
982 struct rte_timer_data *timer_data;
983
984 TIMER_DATA_VALID_GET_OR_ERR_RET(timer_data_id, timer_data, -EINVAL);
985
986 for (i = 0; i < nb_walk_lcores; i++) {
987 walk_lcore = walk_lcores[i];
988 priv_timer = &timer_data->priv_timer[walk_lcore];
989
990 for (tim = priv_timer->pending_head.sl_next[0];
991 tim != NULL;
992 tim = next_tim) {
993 next_tim = tim->sl_next[0];
994
995 __rte_timer_stop(tim, timer_data);
996
997 if (f)
998 f(tim, f_arg);
999 }
1000 }
1001
1002 return 0;
1003}
1004
1005int64_t
1006rte_timer_next_ticks(void)

Callers 1

swtim_uninitFunction · 0.85

Calls 1

__rte_timer_stopFunction · 0.85

Tested by

no test coverage detected