diff --git a/msm/vidc/msm_vidc_debug.c b/msm/vidc/msm_vidc_debug.c index 4b0f6090de40..b692f8c9f05b 100644 --- a/msm/vidc/msm_vidc_debug.c +++ b/msm/vidc/msm_vidc_debug.c @@ -728,10 +728,6 @@ inline bool is_print_allowed(u32 sid, u32 level) } /* Mock all the missing parts for successful compilation starts here */ -void do_gettimeofday(struct timeval *__ddl_tv) -{ -} - #ifndef CONFIG_VIDEOBUF2_CORE void vb2_queue_release(struct vb2_queue *q) { diff --git a/msm/vidc/msm_vidc_debug.h b/msm/vidc/msm_vidc_debug.h index 7b523eddb55f..389b0d9e9eb8 100644 --- a/msm/vidc/msm_vidc_debug.h +++ b/msm/vidc/msm_vidc_debug.h @@ -19,8 +19,6 @@ // void disable_irq_nosync(unsigned int irq); // void enable_irq(unsigned int irq); -void do_gettimeofday(struct timeval *__ddl_tv); - #ifndef CONFIG_VIDEOBUF2_CORE int vb2_reqbufs(struct vb2_queue *q, struct v4l2_requestbuffers *req); int vb2_qbuf(struct vb2_queue *q, struct media_device *mdev, @@ -234,7 +232,7 @@ static inline void tic(struct msm_vidc_inst *i, enum profiling_points p, memcpy(i->debug.pdata[p].name, b, 64); if ((msm_vidc_debug & VIDC_PERF) && i->debug.pdata[p].sampling) { - do_gettimeofday(&__ddl_tv); + __ddl_tv = ktime_to_timeval(ktime_get_real()); i->debug.pdata[p].start = (__ddl_tv.tv_sec * 1000) + (__ddl_tv.tv_usec / 1000); i->debug.pdata[p].sampling = false; @@ -247,7 +245,7 @@ static inline void toc(struct msm_vidc_inst *i, enum profiling_points p) if ((msm_vidc_debug & VIDC_PERF) && !i->debug.pdata[p].sampling) { - do_gettimeofday(&__ddl_tv); + __ddl_tv = ktime_to_timeval(ktime_get_real()); i->debug.pdata[p].stop = (__ddl_tv.tv_sec * 1000) + (__ddl_tv.tv_usec / 1000); i->debug.pdata[p].cumulative += i->debug.pdata[p].stop -