Source
34
34
hdr->svc = IMX_SC_RPC_SVC_TIMER;
35
35
hdr->func = IMX_SC_TIMER_FUNC_GET_RTC_SEC1970;
36
36
hdr->size = 1;
37
37
38
38
ret = imx_scu_call_rpc(rtc_ipc_handle, &msg, true);
39
39
if (ret) {
40
40
dev_err(dev, "read rtc time failed, ret %d\n", ret);
41
41
return ret;
42
42
}
43
43
44
-
rtc_time_to_tm(msg.time, tm);
44
+
rtc_time64_to_tm(msg.time, tm);
45
45
46
46
return 0;
47
47
}
48
48
49
49
static int imx_sc_rtc_set_time(struct device *dev, struct rtc_time *tm)
50
50
{
51
51
struct arm_smccc_res res;
52
52
53
53
/* pack 2 time parameters into 1 register, 16 bits for each */
54
54
arm_smccc_smc(IMX_SIP_SRTC, IMX_SIP_SRTC_SET_TIME,