Skip to content
Commit d7599245 authored by Alexandre Belloni's avatar Alexandre Belloni
Browse files

rtc: ls1x: add range



While the year is encoded on 32 bits in SYS_TOYWRITE1i/SYS_TOYREAD1. The
Loongson 1c datasheet states that the range is from 0 to 99.

The current code exceeds this range and seems to be working, I deduce that
the leap year algorithm will fail in 2100.

Anyway, alarm registers only encode the year on 14 bits so with alarm
support, the range will always be limited to 0 to 16383.

Signed-off-by: default avatarAlexandre Belloni <alexandre.belloni@bootlin.com>
parent 14dc3ec5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment