From: Hiroyuki Mikita <h.mikita89@gmail.com>
To: "Sanford, Robert" <rsanford@akamai.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
Thomas Monjalon <thomas.monjalon@6wind.com>
Subject: Re: [dpdk-dev] [PATCH] timer: fix incorrect pending-list manipulation
Date: Tue, 26 Jul 2016 00:16:38 +0900 [thread overview]
Message-ID: <CAO_n4D2Y1upC5CQ4YXCO4D0Mt0wrZQP5=Q0kTPdV_er=-YHUSA@mail.gmail.com> (raw)
In-Reply-To: <D3B81044.14462%rsanford@akamai.com>
Fixes: 9b15ba895b9f ("timer: use a skip list")
2016-07-23 7:05 GMT+09:00 Sanford, Robert <rsanford@akamai.com>:
>
>
> On 7/17/16 10:35 AM, "Hiroyuki Mikita" <h.mikita89@gmail.com> wrote:
>
>>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.
>>
>>Signed-off-by: Hiroyuki Mikita <h.mikita89@gmail.com>
>>---
>> lib/librte_timer/rte_timer.c | 2 ++
>> 1 file changed, 2 insertions(+)
>>
>>diff --git a/lib/librte_timer/rte_timer.c b/lib/librte_timer/rte_timer.c
>>index 3dcdab5..7457d32 100644
>>--- a/lib/librte_timer/rte_timer.c
>>+++ b/lib/librte_timer/rte_timer.c
>>@@ -543,6 +543,8 @@ void rte_timer_manage(void)
>> /* 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)
>>--
>>2.7.4
>>
>
> Acked-by: Robert Sanford <rsanford@akamai.com>
>
next prev parent reply other threads:[~2016-07-25 15:16 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-17 14:35 Hiroyuki Mikita
2016-07-22 22:05 ` Sanford, Robert
2016-07-25 15:16 ` Hiroyuki Mikita [this message]
2016-07-25 15:50 ` Thomas Monjalon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAO_n4D2Y1upC5CQ4YXCO4D0Mt0wrZQP5=Q0kTPdV_er=-YHUSA@mail.gmail.com' \
--to=h.mikita89@gmail.com \
--cc=dev@dpdk.org \
--cc=rsanford@akamai.com \
--cc=thomas.monjalon@6wind.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).