This commit fixes incorrect pending-list manipulation
when getting list of expired timers in rte_timer_manage().
When timer_get_prev_entries() sets pending_head on prev,
the pending-list is broken.
The next of pending_head always becomes NULL.
In this depth level, it is not need to manipulate the list.
Fixes:
9b15ba895b9f ("timer: use a skip list")
Signed-off-by: Hiroyuki Mikita <h.mikita89@gmail.com>
Acked-by: Robert Sanford <rsanford@akamai.com>
/* break the existing list at current time point */
timer_get_prev_entries(cur_time, lcore_id, prev);
for (i = priv_timer[lcore_id].curr_skiplist_depth -1; i >= 0; i--) {
+ if (prev[i] == &priv_timer[lcore_id].pending_head)
+ continue;
priv_timer[lcore_id].pending_head.sl_next[i] =
prev[i]->sl_next[i];
if (prev[i]->sl_next[i] == NULL)