]> git.dujemihanovic.xyz Git - u-boot.git/commit
rtc: stm32: manage 2 digit limitation on year
authorPatrick Delaunay <patrick.delaunay@st.com>
Mon, 22 Jul 2019 12:50:21 +0000 (14:50 +0200)
committerPatrice Chotard <patrice.chotard@st.com>
Tue, 27 Aug 2019 07:36:56 +0000 (09:36 +0200)
commitfed51572c81192a9135380e88cfa445361dade5d
tree3d5304d28553fd0385240b84d3ab7eb7775e5173
parent0203050e57f5e0ad6c696cb64cfbc01fd08b67c5
rtc: stm32: manage 2 digit limitation on year

STM32 RTC manages only 2 digits for YEAR
(Year tens and units in BCD format in RTC_DR register).

With this patch, RTC driver assumes that tm->tm_years is between
2000 and 2099; tm->tm_year - 2000 have only 2 digit
(0 > and <= 99).

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
drivers/rtc/stm32_rtc.c