src/soc/stoneyridge: Add a check for CMOS failure
BUG=b:77345148 TEST=Pull power from grunt, verify CMOS power failure is detected. Reboot and verify that CMOS power failure is not detected. Change-Id: Idbf0254e197a6d282e618a98bced52ea5a44917f Signed-off-by: Martin Roth <martinroth@google.com> Reviewed-on: https://review.coreboot.org/25468 Reviewed-by: Aaron Durbin <adurbin@chromium.org> Reviewed-by: Marc Jones <marc@marcjonesconsulting.com> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
8dce5bcca5
commit
d738749d47
|
@ -17,11 +17,12 @@
|
|||
#include <soc/southbridge.h>
|
||||
#include <security/vboot/vboot_common.h>
|
||||
#include <security/vboot/vbnv.h>
|
||||
#include <pc80/mc146818rtc.h>
|
||||
|
||||
int vbnv_cmos_failed(void)
|
||||
{
|
||||
/* FIXME: RTC failure checking not supported. */
|
||||
return 0;
|
||||
/* If CMOS power has failed, the century will be set to 0xff */
|
||||
return cmos_read(RTC_CLK_ALTCENTURY) == 0xff;
|
||||
}
|
||||
|
||||
int vboot_platform_is_resuming(void)
|
||||
|
|
Loading…
Reference in New Issue