I am working on Dragon board 410 and I am using Android 5.1.1 OS.
I want to use RTC of PMIC 8916. I am able to read time from the RTC but whenever try to set RTC time to system time, it is showing Invalid argument.
root@msm8916_64:/ # busybox hwclock -r
Thu Jan 1 02:03:57 1970 0.000000 seconds
root@msm8916_64:/ # busybox hwclock -w
hwclock: RTC_SET_TIME: Invalid argument
If I make qcom,qpnp-rtc-write = <1>; for RTC node in DTSI file, then the board is getting reboot while writing the RTC registers.
So, how to set RTC time of PMIC8916 ?