msm: camera: isp: Update camera timestamps to ktime API
Old API's returning struct timeval and struct timespec will be deprecated in future kernel versions as their tv_sec members will overflow in the year 2038 on 32-bit arhitectures. CRs-Fixed: 2564616 Change-Id: I6e3e37cf957daca992b66cad1134f49dd78961f5 Signed-off-by: Karthik Jayakumar <kjayakum@codeaurora.org>
This commit is contained in:
@@ -2795,7 +2795,7 @@ static int cam_ife_mgr_acquire_hw(void *hw_mgr_priv, void *acquire_hw_args)
|
||||
acquire_args->valid_acquired_hw =
|
||||
acquire_hw_info->num_inputs;
|
||||
|
||||
getnstimeofday64(&ife_ctx->ts);
|
||||
ktime_get_real_ts64(&ife_ctx->ts);
|
||||
CAM_INFO(CAM_ISP,
|
||||
"Acquire HW success with total_pix: %u total_rdi: %u is_dual: %u in ctx: %u",
|
||||
total_pix_port, total_rdi_port,
|
||||
|
@@ -3004,7 +3004,7 @@ static int cam_ife_csid_get_time_stamp(
|
||||
CAM_IFE_CSID_QTIMER_DIV_FACTOR);
|
||||
|
||||
if (!csid_hw->prev_boot_timestamp) {
|
||||
get_monotonic_boottime64(&ts);
|
||||
ktime_get_boottime_ts64(&ts);
|
||||
time_stamp->boot_timestamp =
|
||||
(uint64_t)((ts.tv_sec * 1000000000) +
|
||||
ts.tv_nsec);
|
||||
|
@@ -381,7 +381,7 @@ void cam_isp_hw_get_timestamp(struct cam_isp_timestamp *time_stamp)
|
||||
{
|
||||
struct timespec ts;
|
||||
|
||||
get_monotonic_boottime(&ts);
|
||||
ts = ktime_to_timespec(ktime_get_boottime());
|
||||
time_stamp->mono_time.tv_sec = ts.tv_sec;
|
||||
time_stamp->mono_time.tv_usec = ts.tv_nsec/1000;
|
||||
}
|
||||
|
Viittaa uudesa ongelmassa
Block a user