From 6d448e3aa6c84487ec6d3fcc09cf015e4433619d Mon Sep 17 00:00:00 2001 From: Furquan Shaikh Date: Fri, 22 Jul 2016 08:28:57 -0700 Subject: google/chromeos: Add recovery module in vboot2 Add recovery module in vboot2 that checks if a recovery request is pending and returns appropriate reason code: 1. Checks if recovery mode is initiated by EC. 2. Checks if recovery request is present in VBNV. 3. Checks if recovery request is present in handoff for post-cbmem stages. 4. Checks if vboot verification is complete and looks up selected region to identify if recovery is requested by vboot library. BUG=chrome-os-partner:55431 Change-Id: I31e332a4d014a185df2434c3730954e08dc27281 Signed-off-by: Furquan Shaikh Reviewed-on: https://review.coreboot.org/15800 Reviewed-by: Aaron Durbin Tested-by: build bot (Jenkins) --- src/vendorcode/google/chromeos/vboot_common.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/vendorcode/google/chromeos/vboot_common.h') diff --git a/src/vendorcode/google/chromeos/vboot_common.h b/src/vendorcode/google/chromeos/vboot_common.h index ae135fe66f..266ce4f6b3 100644 --- a/src/vendorcode/google/chromeos/vboot_common.h +++ b/src/vendorcode/google/chromeos/vboot_common.h @@ -25,6 +25,12 @@ /* Locate vboot area by name. Returns 0 on success and -1 on error. */ int vboot_named_region_device(const char *name, struct region_device *rdev); +/* + * Function to check if there is a request to enter recovery mode. Returns + * reason code if request to enter recovery mode is present, otherwise 0. + */ +int vboot_check_recovery_request(void); + /* ========================== VBOOT HANDOFF APIs =========================== */ /* * The vboot_handoff structure contains the data to be consumed by downstream -- cgit v1.2.3