diff options
author | Mary Ruthven <mruthven@chromium.org> | 2021-05-21 12:57:15 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-05-21 22:30:03 +0000 |
commit | 184d13a29dc9eaaad54bd65237f2bf67c155c4b9 (patch) | |
tree | d85d8f7ed5d3b517ffe90250a2a2528c8aaf1650 | |
parent | d62db9a9bab7b46fc7cd22570137ea873530d092 (diff) | |
download | chrome-ec-184d13a29dc9eaaad54bd65237f2bf67c155c4b9.tar.gz |
flash: enable OP_ERASE_BLOCK in standard images
This branch is being used to build eraseflashinfo images. Let RW try to
erase info1 even if it's not a DBG image. RO will block the erase
if the image isn't signed correctly.
BUG=b:187438971
TEST=none
Change-Id: I61a31cf7c4252396ce267fb6b4e54de37479335f
Signed-off-by: Mary Ruthven <mruthven@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2911497
Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
Commit-Queue: Vadim Bendebury <vbendeb@chromium.org>
-rw-r--r-- | chip/g/flash.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/chip/g/flash.c b/chip/g/flash.c index b13f071332..02f6c34bd8 100644 --- a/chip/g/flash.c +++ b/chip/g/flash.c @@ -199,12 +199,6 @@ static int do_flash_op(enum flash_op op, int is_info_bank, /* What are we doing? */ switch (op) { case OP_ERASE_BLOCK: -#ifndef CR50_DEV - if (is_info_bank) - /* Erasing the INFO bank from the RW section is - * unsupported. */ - return EC_ERROR_INVAL; -#endif opcode = 0x31415927; words = 0; /* don't care, really */ /* This number is based on the TSMC spec Nme=Terase/Tsme */ @@ -514,7 +508,7 @@ static int command_erase_flash_info(int argc, char **argv) mutex_unlock(&flash_mtx); if (rv != EC_SUCCESS) { - ccprintf("Failed to erase info space!\n"); + ccprintf("Failed to erase info space %d!\n", rv); goto exit; } |