summaryrefslogtreecommitdiff
path: root/src/security/vboot/vboot_common.c
diff options
context:
space:
mode:
authorJoel Kitching <kitching@google.com>2019-06-16 16:44:26 +0800
committerJulius Werner <jwerner@chromium.org>2019-06-21 00:50:48 +0000
commita06cd6c29e5f2fb05210eb185b84c887791df989 (patch)
treeb60b02553e9e9a448bc6a4344411a0ad20aca95a /src/security/vboot/vboot_common.c
parentc10af299aeed2a7d530fbabbaa55947d64712333 (diff)
downloadcoreboot-a06cd6c29e5f2fb05210eb185b84c887791df989.tar.xz
vboot: remove vboot_handoff_get_recovery_reason
Two functions retrieve vboot recovery_reason: * vboot_handoff_get_recovery_reason * vboot_get_recovery_reason_shared_data Previously, when CBMEM comes online, a vboot_handoff data structure is created, and depending on the architecture, coreboot may eventually lose access to vboot_working_data. After implementing vboot_working_data CBMEM migration, vboot_working_data is always guaranteed to be accessible. vboot_get_recovery_reason_shared_data is corrected to also allow accessing vboot_working_data in ramstage and postcar. Now, vboot_handoff_get_recovery reason returning a valid recovery reason implies that vboot_get_recovery_reason_shared_data should *also* return a valid recovery reason. Thus we may remove the former. BUG=b:124141368, b:124192753 TEST=make clean && make test-abuild BRANCH=none Change-Id: Iac216dc968dd155d9d4f8bd0f2dfd5034762f9a0 Signed-off-by: Joel Kitching <kitching@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/33532 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Furquan Shaikh <furquan@google.com> Reviewed-by: Julius Werner <jwerner@chromium.org>
Diffstat (limited to 'src/security/vboot/vboot_common.c')
-rw-r--r--src/security/vboot/vboot_common.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/src/security/vboot/vboot_common.c b/src/security/vboot/vboot_common.c
index ff8e6c896c..a18bf23f92 100644
--- a/src/security/vboot/vboot_common.c
+++ b/src/security/vboot/vboot_common.c
@@ -93,19 +93,6 @@ int vboot_handoff_check_recovery_flag(void)
return vboot_get_handoff_flag(VB_INIT_OUT_ENABLE_RECOVERY);
}
-int vboot_handoff_get_recovery_reason(void)
-{
- struct vboot_handoff *vbho;
- VbSharedDataHeader *sd;
-
- if (vboot_get_handoff_info((void **)&vbho, NULL))
- return 0;
-
- sd = (VbSharedDataHeader *)vbho->shared_data;
-
- return sd->recovery_reason;
-}
-
/* ============================ VBOOT REBOOT ============================== */
void __weak vboot_platform_prepare_reboot(void)
{