[dpdk-dev] [PATCH 2/5] eal/ppc64: define architecture specific rdtsc hz
Jerin Jacob
jerin.jacob at caviumnetworks.com
Sun Aug 13 09:03:47 CEST 2017
CC: Chao Zhu <chaozhu at linux.vnet.ibm.com>
Signed-off-by: Jerin Jacob <jerin.jacob at caviumnetworks.com>
---
lib/librte_eal/common/include/arch/ppc_64/rte_cycles.h | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/lib/librte_eal/common/include/arch/ppc_64/rte_cycles.h b/lib/librte_eal/common/include/arch/ppc_64/rte_cycles.h
index 8fa6fc60b..20243fb29 100644
--- a/lib/librte_eal/common/include/arch/ppc_64/rte_cycles.h
+++ b/lib/librte_eal/common/include/arch/ppc_64/rte_cycles.h
@@ -79,6 +79,19 @@ rte_rdtsc(void)
return tsc.tsc_64;
}
+/**
+ * Get the number of rdtsc cycles in one second if the architecture supports.
+ *
+ * @return
+ * The number of rdtsc cycles in one second. Return zero if the architecture
+ * support is not available.
+ */
+static inline uint64_t
+rte_rdtsc_arch_hz(void)
+{
+ return 0;
+}
+
static inline uint64_t
rte_rdtsc_precise(void)
{
--
2.14.0
More information about the dev
mailing list