]> git.baikalelectronics.ru Git - kernel.git/commit
rtc: cmos: century support
authorSylvain Chouleur <sylvain.chouleur@intel.com>
Mon, 8 Jun 2015 09:45:19 +0000 (11:45 +0200)
committerAlexandre Belloni <alexandre.belloni@free-electrons.com>
Sat, 5 Sep 2015 11:19:09 +0000 (13:19 +0200)
commit40a32e804d49e7ee23e85c30be753141a08a1bd9
tree19905089bba8bb8b295b1916b059b8c14b46cbba
parente8114e65dc4585844d1e3ca431d7756894f3bb61
rtc: cmos: century support

If century field is supported by the RTC CMOS device, then we should use
it and then do not consider years greater that 169 as an error.

For information, the year field of the rtc_time structure contains the
value to add to 1970 to obtain the current year.

This was a hack to be able to support years for 1970 to 2069.
This patch remains compatible with this implementation.

Signed-off-by: Sylvain Chouleur <sylvain.chouleur@intel.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
include/asm-generic/rtc.h