diff options
author | Patrick Rudolph <siro@das-labor.org> | 2018-11-01 17:48:37 +0100 |
---|---|---|
committer | Patrick Rudolph <siro@das-labor.org> | 2018-11-07 18:12:39 +0000 |
commit | 6b931125459250a015f6de438dbf9c23e9cd6d75 (patch) | |
tree | 9e730502527fb236b5ad24c57b9e71a83f41811f /src/southbridge/intel/lynxpoint/pmutil.c | |
parent | f19a07b2e4d82b60a8ff6ab0ad29b42f67170485 (diff) | |
download | coreboot-6b931125459250a015f6de438dbf9c23e9cd6d75.tar.xz |
sb/intel: Deduplicate vbnv_cmos_failed and rtc_init
* Move all implementations to into common folder.
* Add rtc.c for rtc based functions
Allows all Intel based platforms to use VBOOT_VBNV_CMOS.
Change-Id: Ia494e6d418af6f907c648376674776c54d95ba71
Signed-off-by: Patrick Rudolph <siro@das-labor.org>
Reviewed-on: https://review.coreboot.org/29427
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Diffstat (limited to 'src/southbridge/intel/lynxpoint/pmutil.c')
-rw-r--r-- | src/southbridge/intel/lynxpoint/pmutil.c | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/src/southbridge/intel/lynxpoint/pmutil.c b/src/southbridge/intel/lynxpoint/pmutil.c index e96d683bb2..b14c1f7c91 100644 --- a/src/southbridge/intel/lynxpoint/pmutil.c +++ b/src/southbridge/intel/lynxpoint/pmutil.c @@ -24,7 +24,6 @@ #include <device/pci.h> #include <device/pci_def.h> #include <console/console.h> -#include <security/vboot/vbnv.h> #include "pch.h" #if IS_ENABLED(CONFIG_INTEL_LYNXPOINT_LP) @@ -554,18 +553,3 @@ void disable_gpe(u32 mask) gpe0_en &= ~mask; outl(gpe0_en, get_pmbase() + gpe0_reg); } - -int rtc_failure(void) -{ -#if defined(__SIMPLE_DEVICE__) - pci_devfn_t dev = PCI_DEV(0, 31, 0); -#else - struct device *dev = dev_find_slot(0, PCI_DEVFN(31, 0)); -#endif - return !!(pci_read_config8(dev, GEN_PMCON_3) & RTC_BATTERY_DEAD); -} - -int vbnv_cmos_failed(void) -{ - return rtc_failure(); -} |