aboutsummaryrefslogtreecommitdiff
path: root/src/vboot
diff options
context:
space:
mode:
authorAaron Durbin <adurbin@chromium.org>2017-09-15 11:01:17 -0600
committerAaron Durbin <adurbin@chromium.org>2017-09-20 23:53:23 +0000
commit9fde0d780dd0abd24119ff6f7854b4b5939ce7d2 (patch)
tree2a42e542b93e2dc73712182a634a9483f512cc1a /src/vboot
parentaa51cd5c12596b0b6d5f61eb1108091bf3a4fd3f (diff)
vboot: remove init_vbnv_cmos()
Instead of having each potential caller deal with the differences of cmos_init() and init_vbnv_cmos() when VBOOT is enabled put the correct logic within the callee, cmos_init(), for handling the vbnv in CMOS. The internal __cmos_init() routine returns when the CMOS area was cleared. BUG=b:63054105 Change-Id: Ia124bcd61d3ac03e899a4ecf3645fc4b7a558f03 Signed-off-by: Aaron Durbin <adurbin@chromium.org> Reviewed-on: https://review.coreboot.org/21549 Reviewed-by: Furquan Shaikh <furquan@google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/vboot')
-rw-r--r--src/vboot/vbnv.h1
-rw-r--r--src/vboot/vbnv_cmos.c13
2 files changed, 0 insertions, 14 deletions
diff --git a/src/vboot/vbnv.h b/src/vboot/vbnv.h
index 30da6a50c5..7a0bf92f40 100644
--- a/src/vboot/vbnv.h
+++ b/src/vboot/vbnv.h
@@ -30,7 +30,6 @@ int vboot_wants_oprom(void);
/* CMOS backend */
void read_vbnv_cmos(uint8_t *vbnv_copy);
void save_vbnv_cmos(const uint8_t *vbnv_copy);
-void init_vbnv_cmos(int rtc_fail);
/* Flash backend */
void read_vbnv_flash(uint8_t *vbnv_copy);
diff --git a/src/vboot/vbnv_cmos.c b/src/vboot/vbnv_cmos.c
index b7ef3e767f..8bdcb31f9c 100644
--- a/src/vboot/vbnv_cmos.c
+++ b/src/vboot/vbnv_cmos.c
@@ -68,19 +68,6 @@ void save_vbnv_cmos(const uint8_t *vbnv_copy)
cmos_write(vbnv_copy[i], CONFIG_VBOOT_VBNV_OFFSET + 14 + i);
}
-void init_vbnv_cmos(int rtc_fail)
-{
- uint8_t vbnv[VBOOT_VBNV_BLOCK_SIZE];
-
- if (rtc_fail)
- read_vbnv_cmos(vbnv);
-
- cmos_init(rtc_fail);
-
- if (rtc_fail)
- save_vbnv_cmos(vbnv);
-}
-
#if IS_ENABLED(CONFIG_VBOOT_VBNV_CMOS_BACKUP_TO_FLASH)
static void back_up_vbnv_cmos(void *unused)
{