summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--common/rwsig.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/common/rwsig.c b/common/rwsig.c
index 1af7189cc0..86d77144d8 100644
--- a/common/rwsig.c
+++ b/common/rwsig.c
@@ -269,6 +269,12 @@ void rwsig_task(void *u)
if (system_get_image_copy() != EC_IMAGE_RO)
goto exit;
+ /* Stay in RO if we were asked to when reset. */
+ if (system_get_reset_flags() & EC_RESET_FLAG_STAY_IN_RO) {
+ rwsig_status = RWSIG_ABORTED;
+ goto exit;
+ }
+
rwsig_status = RWSIG_IN_PROGRESS;
if (!rwsig_check_signature()) {
rwsig_status = RWSIG_INVALID;