diff options
author | Vadim Bendebury <vbendeb@chromium.org> | 2019-08-21 14:33:13 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2019-08-23 23:50:08 +0000 |
commit | 026e45300709faae9cc73d4f42f111fffab99120 (patch) | |
tree | dd04fd182aac0fba33cd855d25407d514ce7c5a8 /include/flash_log.h | |
parent | 481da547186bc9989068ceef73ccd1556a911dad (diff) | |
download | chrome-ec-026e45300709faae9cc73d4f42f111fffab99120.tar.gz |
nvmem: reinitialize on catastrophic errors
If there is an NVMEM corruption which causes a reboot, persisting
corruption would cause rolling reboot of the device.
It is a harsh remedy, but at least the device remains functional.
Added a log entry to explicitly report NVMEM reinitialization.
BRANCH=cr50, cr50-mp
BUG=b:139326267
TEST=verified by erasing a flash page assigned to NVMEM and rebooting
the device. Observed two new flash log entries.
Change-Id: Id292d7c66b81c03bbe3cd343ae75acb62d06582d
Signed-off-by: Vadim Bendebury <vbendeb@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1758805
Reviewed-by: Andrey Pronin <apronin@chromium.org>
Diffstat (limited to 'include/flash_log.h')
-rw-r--r-- | include/flash_log.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/flash_log.h b/include/flash_log.h index 64ee2703e3..e504df6ee7 100644 --- a/include/flash_log.h +++ b/include/flash_log.h @@ -65,7 +65,10 @@ enum nvmem_failure_type { NVMEMF_PRE_ERASE_MISMATCH = 10, NVMEMF_PAGE_LIST_OVERFLOW = 11, NVMEMF_CIPHER_ERROR = 12, - NVMEMF_CORRUPTED_INIT = 13 + NVMEMF_CORRUPTED_INIT = 13, + NVMEMF_CONTAINER_HASH_MISMATCH = 14, + NVMEMF_UNRECOVERABLE_INIT = 15, + NVMEMF_NVMEM_WIPE = 16, }; /* Not all nvmem failures require payload. */ |