summaryrefslogtreecommitdiff
path: root/src/vendorcode/google/chromeos
diff options
context:
space:
mode:
Diffstat (limited to 'src/vendorcode/google/chromeos')
-rw-r--r--src/vendorcode/google/chromeos/vboot_handoff.c6
-rw-r--r--src/vendorcode/google/chromeos/vboot_loader.c4
2 files changed, 9 insertions, 1 deletions
diff --git a/src/vendorcode/google/chromeos/vboot_handoff.c b/src/vendorcode/google/chromeos/vboot_handoff.c
index 1a66f56828..7ef2c7ee5a 100644
--- a/src/vendorcode/google/chromeos/vboot_handoff.c
+++ b/src/vendorcode/google/chromeos/vboot_handoff.c
@@ -54,6 +54,12 @@ int vboot_enable_recovery(void)
return !!(vbho->init_params.out_flags & VB_INIT_OUT_ENABLE_RECOVERY);
}
+int __attribute__((weak)) clear_recovery_mode_switch(void)
+{
+ // Can be implemented by a mainboard
+ return 0;
+}
+
int vboot_skip_display_init(void)
{
struct vboot_handoff *vbho;
diff --git a/src/vendorcode/google/chromeos/vboot_loader.c b/src/vendorcode/google/chromeos/vboot_loader.c
index 240b6b6fc5..80e2aea1bb 100644
--- a/src/vendorcode/google/chromeos/vboot_loader.c
+++ b/src/vendorcode/google/chromeos/vboot_loader.c
@@ -245,8 +245,10 @@ static void vboot_invoke_wrapper(struct vboot_handoff *vboot_handoff)
iflags = &vboot_handoff->init_params.flags;
if (get_developer_mode_switch())
*iflags |= VB_INIT_FLAG_DEV_SWITCH_ON;
- if (get_recovery_mode_switch())
+ if (get_recovery_mode_switch()) {
+ clear_recovery_mode_switch();
*iflags |= VB_INIT_FLAG_REC_BUTTON_PRESSED;
+ }
if (get_write_protect_state())
*iflags |= VB_INIT_FLAG_WP_ENABLED;
if (vboot_get_sw_write_protect())