Shubhi Garg b60b757d9c rtc: fix year calculation in max77851 pmic rtc
Add +100 to year only if PMIC does not have separate alarm
enable registers. Since MAX77851 has separate alarm enable register
, MAX77851 RTC supports year calculation from 0..199 so we do not need
to add 100 on reading RTC YEAR register. Currently, default, driver is
adding +100 which is wrong. This change fixes rtc year calculation.

Bug 200749982

Change-Id: Ibaf1d2fb81e59cc21c22d509cf9ffc7b6005916c
Signed-off-by: Shubhi Garg <shgarg@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-5.10/+/2727859
(cherry picked from commit b43364942c67fdf7958a42bfad5fe02725da00e3)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-5.10/+/2728926
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2947785
Reviewed-by: svcacv <svcacv@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-09-14 13:25:47 -07:00
2022-12-07 23:57:14 -08:00
Description
No description provided
34 MiB