diff options
-rw-r--r-- | firmware/lib/vboot_api_kernel.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/firmware/lib/vboot_api_kernel.c b/firmware/lib/vboot_api_kernel.c index e2d14310..52d3f073 100644 --- a/firmware/lib/vboot_api_kernel.c +++ b/firmware/lib/vboot_api_kernel.c @@ -236,7 +236,13 @@ vb2_error_t VbSelectAndLoadKernel(struct vb2_context *ctx, VB2_TRY(vb2_broken_recovery_menu(ctx)); } else if (DIAGNOSTIC_UI && vb2api_diagnostic_ui_enabled(ctx) && vb2_nv_get(ctx, VB2_NV_DIAG_REQUEST)) { + /* + * Need to clear the request flag and commit nvdata changes + * immediately to avoid booting back into diagnostic tool when a + * forced system reset occurs. + */ vb2_nv_set(ctx, VB2_NV_DIAG_REQUEST, 0); + vb2ex_commit_data(ctx); /* Diagnostic boot. This has UI. */ VB2_TRY(vb2_diagnostic_menu(ctx)); |