as3277: Fix month-off-by-one error for RTC driver

Hardware / Coreboot - Julius Werner [chromium.org] - 17 April 2015 02:20 UTC

The AS3277 RTC code seems to closely follow the corresponding Linux driver. Unfortunately, while coreboot (and even other parts of Linux, like mktime()) directly follows the standard IBM PC RTC time representation (except for the BCD part), Linux' struct rtc_time decided to use 0-based (instead of 1-based) months instead.

This patch removes the faulty month offset that was copied into our driver so that we will generate correct timestamps again.

BRANCH=nyan BUG=chrome-os-partner:34108 TEST=firmware_EventLog (pre-release version) gets further than before (and then craps up on unrelated problems with suspend/resume events).

Change-Id: Ica221a8bcfd7c1c6cd7ba382d760b586d511e3a3

90d0acb as3277: Fix month-off-by-one error for RTC driver
src/drivers/ams/as3722rtc.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

Upstream: review.coreboot.org


  • Share