瀏覽代碼

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
Hardik Kantilal Patel 9 年之前
父節點
當前提交
732caef504
共有 1 個文件被更改,包括 7 次插入0 次删除
  1. 7 0
      qdf/linux/src/i_qdf_time.h

+ 7 - 0
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
 
 /**