Furquan Shaikh has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33534 )
Change subject: vboot: relocate code to log and clear recovery mode switch ......................................................................
Patch Set 1: Code-Review+2
(1 comment)
https://review.coreboot.org/#/c/33534/1/src/security/vboot/vboot_logic.c File src/security/vboot/vboot_logic.c:
https://review.coreboot.org/#/c/33534/1/src/security/vboot/vboot_logic.c@285 PS1, Line 285: vboot_log_and_clear_recovery_mode_switch Just thinking out loud: This should have the same effect as before because - 1. !VBOOT_STARTS_IN_ROMSTAGE --> Earlier it was done in vboot_fill_handoff which was a cbmem init hook and now vboot_log_and_clear_recovery_mode_switch is run in cbmem init hook of its own.
2. VBOOT_STARTS_IN_ROMSTAGE --> vboot_fill_handoff was called after verstage_main returns and recovery reason is saved to VBNV. Now, vboot_log_and_clear_recovery_mode_switch is called at the end of verstage main and before recovery reason is saved to VBNV. However, saving of VBNV should be independent of logging/clearing recovery switches.