From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-yw0-f179.google.com (mail-yw0-f179.google.com [209.85.161.179]) by dpdk.org (Postfix) with ESMTP id 745BE47D0 for ; Thu, 21 Jul 2016 12:34:55 +0200 (CEST) Received: by mail-yw0-f179.google.com with SMTP id r9so70657667ywg.0 for ; Thu, 21 Jul 2016 03:34:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=Kzx4v6AiaE03F1vAZqQcuOjFbxnZ/mrLxuZRXMXK1Q4=; b=x+ax4cru9oJK8JmKr6BaymE8rRQDfSa3KAKWd8nUfwILJLZu795qPmOVIKY4wp0NED Zi3uBYzhyfOnvYP0FhQ0OnSKC6Xdmghl9gOVyxtCEcJDAL7ywe3rysb5ZsEFHoHDkSvF ryjlnay15ChNtxLW5qV1DpEE3VwEevORwjWooFXHf/1kHpMrT5THtmJTcjXcqah6EA5q CdTTSYmNwlN2V3zuC+vjPDiDyRfpSZKrPKs78FRPKFiD5jJnOmRPTtD2m7KyFBcBPOOp XmhJ8Jp0WUHEpSUtIyZFg7xBGXNxtwwZg1ZvatvlfrPRhGGnIpZU5qTaMPLU9ax7w3cU ZeWg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=Kzx4v6AiaE03F1vAZqQcuOjFbxnZ/mrLxuZRXMXK1Q4=; b=Ie2gAyBaqdw89l334rLP+RU7fBsQoPTAl5zzji/LQjGWVE63PEOmbeV3BlFKk4H4uH xD0Q813+SWO4euCysqcknFDXv+nu/dAl1Dv/l2ajzTNfNXFcZu5jikO4BoL/XpOXNzxA n0Zi9gHEpke5vgBYKGooSJGV0t6tE5Ww9wJxE1P7gQJ0lgy2j0MICWfRkycuROTObSTT eZISsLFom54nvTNAMsQzotvDTVOouguiisTdAZ5ZSbnw9xsr/MCPyvhiExEuu+s+A+MG eL9V9xDg06VkVOVxi69oJjFM+gCixo8Q9Vir5KxuIzL/LdS2RFEs/BisWgJIbZY8Jnlo B6hQ== X-Gm-Message-State: ALyK8tLAoLVtb9CfFsDu0w3AEE5FVz2xZroiqPeVhZpcJr14JySGnaizByYIpBtB77x4oO65C0hojJD04y64cA== X-Received: by 10.129.164.85 with SMTP id b82mr34196227ywh.310.1469097294905; Thu, 21 Jul 2016 03:34:54 -0700 (PDT) MIME-Version: 1.0 Received: by 10.37.36.87 with HTTP; Thu, 21 Jul 2016 03:34:35 -0700 (PDT) In-Reply-To: References: <1468778880-25515-1-git-send-email-h.mikita89@gmail.com> From: Hiroyuki Mikita Date: Thu, 21 Jul 2016 19:34:35 +0900 Message-ID: To: "Sanford, Robert" Cc: "dev@dpdk.org" , Thomas Monjalon Content-Type: text/plain; charset=UTF-8 Subject: Re: [dpdk-dev] [PATCH] timer: fix break list when timer_cb reset running timer X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Jul 2016 10:34:55 -0000 Hi Robert, Thank you for reviewing. In the following case, the skip list is broken. - Timer A and timer B are configured on the same lcore, in the same pending list. - The expire time of timer A is earlier than that of timer B. - rte_timer_manage() is called on the lcore after the expire time of timer B. - The callback of timer A resets timer B. In rte_timer_manage() process, both timers are expired at the same time, so the running list includes both timers. States of both timers are transited from PENDING to RUNNING, then callbacks are executed sequentially. The callback of timer A resets timer B which is still RUNNING, so timer B is added to the pending-list. In this time, timer B is in both the running list and the pending list. It means that the running list is chained to the pending list. Both lists are broken. Regards, Hiroyuki