From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 12AA1A0A0E; Wed, 12 May 2021 16:40:31 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9842F4003F; Wed, 12 May 2021 16:40:30 +0200 (CEST) Received: from wout2-smtp.messagingengine.com (wout2-smtp.messagingengine.com [64.147.123.25]) by mails.dpdk.org (Postfix) with ESMTP id D68FB4003E for ; Wed, 12 May 2021 16:40:28 +0200 (CEST) Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 7289C1624; Wed, 12 May 2021 10:40:27 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Wed, 12 May 2021 10:40:27 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=fm1; bh= aRjYldta1lVWpTPBpM4eBlINUwmjBWEE/7xH9dy5b/4=; b=bLwiWOOofdvvw40S AXmcRSI7sBH2rUFBg2xFWWUFMhNIZm8RQEaDqjK2rP7Imwzln0aOnenmQMKpjTeK 9F2Vk9gVhMjM0hrsqo8IwFWjdXASbzlfcUDX1ugwbFY6RtJAWWbnnFPPwcnUgHMi C6HalQt/16R/Y7X2HYZyzmDV3N8YM49YtVV0ocf/2l9kISbARY6scCUUw7kwx3H8 Qni9NTocKye0t2mi9LYQk1w9rWvop7gvf+k0CWpU0fTFCd4cm1P1x6YlzJb/7FbQ WJRcGFKFXeR6yC+qLvSpKKya169hp/LzQhl61F1CcjcbU11Vuazd1RnqUWEn/Wog ba1dsQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=aRjYldta1lVWpTPBpM4eBlINUwmjBWEE/7xH9dy5b /4=; b=F99XCRbFTb/5c1og2zXOxJYl2yqx4gw8/Po30XbtD4fUEwKm4Sy/gJDx5 gUCOhSnlfBSTYS7MYheUgUqq9QC5xPB0tVXEGuPGIQTioPL1kKTT7ni8S7Vu1cEG kdFirLy1c5M2BAjGihBwfUVlwhXo2m4LaI+LgpfdeO3j2rf6kHjyWspgEN/1YsoI VrUsrgP1bH89hdkEHACkXpEKWeQXv3SLMW9VLiAEFMk+sGIA1tWd/ezOb02ni7GK mt4OCQIqq1HredoDkU6fMwpt16LaN80ct2VK8PJknon0PrfNnMOzTvXf19w0wPF7 Ju1dyPJxLmocMhahv4QrzdHnvZXAQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrvdehvddgjeeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkfgjfhgggfgtsehtufertddttddvnecuhfhrohhmpefvhhhomhgr shcuofhonhhjrghlohhnuceothhhohhmrghssehmohhnjhgrlhhonhdrnhgvtheqnecugg ftrfgrthhtvghrnhepudeggfdvfeduffdtfeeglefghfeukefgfffhueejtdetuedtjeeu ieeivdffgeehnecukfhppeejjedrudefgedrvddtfedrudekgeenucevlhhushhtvghruf hiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehthhhomhgrshesmhhonhhjrghl ohhnrdhnvght X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 12 May 2021 10:40:25 -0400 (EDT) From: Thomas Monjalon To: "Min Hu (Connor)" Cc: dev@dpdk.org, ferruh.yigit@intel.com, david.marchand@redhat.com, rsanford@akamai.com, erik.g.carrillo@intel.com Date: Wed, 12 May 2021 16:40:23 +0200 Message-ID: <9211549.cYOHRHQMzY@thomas> In-Reply-To: <1620293376-41815-1-git-send-email-humin29@huawei.com> References: <1618470748-12369-1-git-send-email-humin29@huawei.com> <1620293376-41815-1-git-send-email-humin29@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH v2] examples/timer: fix incorrect time interval X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 06/05/2021 11:29, Min Hu (Connor): > From: Chengchang Tang > > Timer sample example assumes that the frequency of the timer is about > 2Ghz to control the period of calling rte_timer_manage(). But this > assumption is easy to fail. For example. the frequency of tsc on ARM64 > is much less than 2Ghz. > > This patch uses the frequency of the current timer to calculate the > correct time interval to ensure consistent result on all platforms. > > In addition, the rte_rdtsc() is replaced with the more recommended > rte_get_timer_cycles function in this patch. > > Fixes: af75078fece3 ("first public release") > Cc: stable@dpdk.org > > Signed-off-by: Chengchang Tang > Signed-off-by: Min Hu (Connor) Applied, thanks