From 732caef504a89b2c5f20b83df49ef70e86a102d2 Mon Sep 17 00:00:00 2001 From: Hardik Kantilal Patel Date: Thu, 21 Apr 2016 13:57:47 -0700 Subject: [PATCH] qcacmn:: Change QTIMER API as per 4.4 kernel Use arch_counter_get_cntvct API for QTIMER API on Kernel 4.4. CRs-Fixed: 999964 Change-Id: Ia28c6759cfecfdcc7bd938089b3198eac7dcd961 --- qdf/linux/src/i_qdf_time.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/qdf/linux/src/i_qdf_time.h b/qdf/linux/src/i_qdf_time.h index 6623a3dce6fd..fc5e6ab3bc50 100644 --- a/qdf/linux/src/i_qdf_time.h +++ b/qdf/linux/src/i_qdf_time.h @@ -204,10 +204,17 @@ static inline uint64_t __qdf_get_monotonic_boottime(void) * * Return: QTIMER(19.2 MHz) clock ticks */ +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 4, 0)) +static inline uint64_t __qdf_get_log_timestamp(void) +{ + return arch_counter_get_cntvct(); +} +#else static inline uint64_t __qdf_get_log_timestamp(void) { return arch_counter_get_cntpct(); } +#endif /* LINUX_VERSION_CODE */ #else /**