From: Linhaifeng <haifeng.lin@huawei.com>
To: Jerin Jacob <jerinjacobk@gmail.com>
Cc: Gavin Hu <Gavin.Hu@arm.com>, "dev@dpdk.org" <dev@dpdk.org>,
"thomas@monjalon.net" <thomas@monjalon.net>,
chenchanghu <chenchanghu@huawei.com>,
xudingke <xudingke@huawei.com>,
"Lilijun (Jerry)" <jerry.lilijun@huawei.com>,
Honnappa Nagarahalli <Honnappa.Nagarahalli@arm.com>,
Steve Capper <Steve.Capper@arm.com>, nd <nd@arm.com>
Subject: [dpdk-dev] [PATCH v7] eal/arm64: fix rdtsc precise version
Date: Thu, 12 Mar 2020 01:08:33 +0000 [thread overview]
Message-ID: <4099DE2E54AFAD489356C6C9161D53339729FF27@DGGEML502-MBX.china.huawei.com> (raw)
In order to get more accurate the cntvct_el0 reading,
SW must invoke isb.
Fixes: ccad39ea0712 ("eal/arm: add cpu cycle operations for ARMv8")
Cc: stable@dpdk.org
Reviewed-by: David Marchand <david.marchand@redhat.com>
Reviewed-by: Jerin Jacob <jerinjacobk@gmail.com>
Reviewed-by: Gavin Hu <gavin.hu@arm.com>
Signed-off-by: Haifeng Lin <haifeng.lin@huawei.com>
---
lib/librte_eal/common/include/arch/arm/rte_cycles_64.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/librte_eal/common/include/arch/arm/rte_cycles_64.h b/lib/librte_eal/common/include/arch/arm/rte_cycles_64.h
index 68e7c7338..da557b6a1 100644
--- a/lib/librte_eal/common/include/arch/arm/rte_cycles_64.h
+++ b/lib/librte_eal/common/include/arch/arm/rte_cycles_64.h
@@ -62,7 +62,7 @@ rte_rdtsc(void)
static inline uint64_t
rte_rdtsc_precise(void)
{
- rte_mb();
+ asm volatile("isb" : : : "memory");
return rte_rdtsc();
}
--
2.24.1.windows.2
next reply other threads:[~2020-03-12 1:08 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-12 1:08 Linhaifeng [this message]
2020-03-13 10:06 ` David Marchand
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=4099DE2E54AFAD489356C6C9161D53339729FF27@DGGEML502-MBX.china.huawei.com \
--to=haifeng.lin@huawei.com \
--cc=Gavin.Hu@arm.com \
--cc=Honnappa.Nagarahalli@arm.com \
--cc=Steve.Capper@arm.com \
--cc=chenchanghu@huawei.com \
--cc=dev@dpdk.org \
--cc=jerinjacobk@gmail.com \
--cc=jerry.lilijun@huawei.com \
--cc=nd@arm.com \
--cc=thomas@monjalon.net \
--cc=xudingke@huawei.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).