DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH 0/2] timer bugs fixes
@ 2014-05-23 19:43 Vadim Suraev
  2014-05-23 19:43 ` [dpdk-dev] [PATCH 1/2] timer bug fix Vadim Suraev
  2014-05-23 19:43 ` [dpdk-dev] [PATCH 2/2] " Vadim Suraev
  0 siblings, 2 replies; 3+ messages in thread
From: Vadim Suraev @ 2014-05-23 19:43 UTC (permalink / raw)
  To: dev


Vadim Suraev (2):
Bug: when a periodic timer's callback is running, if another      
    timer is manipulated, the periodic timer is not reloaded.    
Solution: set the update flag only if the modified timer is      
    in RUNNING state
Bug: When a timer is running       - if rte_timer_stop is called, the
    pending decrement is       skipped (decremented only if the timer
    is pending) and due       to the update flag the future processing
    is skipped so the       timer is counted as pending while it is
    stopped. - the same       applies when rte_timer_reset is called
    but then the pending       statistics is additionally incremented
    so the timer is       counted pending twice.     
Solution:
    decrement the pending       statistics after returning from the
    callback. If       rte_timer_stop was called, it skipped
    decrementing the       pending statistics. If rte_time_reset was
    called, the       pending statistics was incremented. If neither
    was called       and the timer is periodic, the pending statistics
    is       incremented when it is reloaded

 lib/librte_timer/rte_timer.c |   12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

-- 
1.7.9.5

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-05-23 19:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-05-23 19:43 [dpdk-dev] [PATCH 0/2] timer bugs fixes Vadim Suraev
2014-05-23 19:43 ` [dpdk-dev] [PATCH 1/2] timer bug fix Vadim Suraev
2014-05-23 19:43 ` [dpdk-dev] [PATCH 2/2] " Vadim Suraev

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).