summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2013-07-19 15:18:52 -0600
committerChromeBot <chrome-bot@google.com>2013-07-19 18:01:49 -0700
commitdb347953e1a463abcb50669988b3f45bd7fbb826 (patch)
tree64eaf437860d50ce73c1a07cfa4bbcb6f369d4f3
parentc243537dda10b1f48b08d444d3cc22673e8edcf1 (diff)
downloadchrome-ec-db347953e1a463abcb50669988b3f45bd7fbb826.tar.gz
Add an enum for the number of flash regions
Add an enum for the number of flash regions so we can keep track of all the possible regions. (This is used in U-Boot which wants to declare an array of all possible regions.) BUG=chromium:244019 BRANCH=none TEST=manual Build EC for pit. Change-Id: I494d857f1388dcc5c64b1cd580cf0084bdef0212 Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/62701 Reviewed-by: Randall Spangler <rspangler@chromium.org>
-rw-r--r--include/ec_commands.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/ec_commands.h b/include/ec_commands.h
index b9df4898b5..de1d9a870a 100644
--- a/include/ec_commands.h
+++ b/include/ec_commands.h
@@ -722,7 +722,7 @@ struct ec_response_flash_protect {
enum ec_flash_region {
/* Region which holds read-only EC image */
- EC_FLASH_REGION_RO,
+ EC_FLASH_REGION_RO = 0,
/* Region which holds rewritable EC image */
EC_FLASH_REGION_RW,
/*
@@ -730,6 +730,8 @@ enum ec_flash_region {
* EC_FLASH_REGION_RO)
*/
EC_FLASH_REGION_WP_RO,
+ /* Number of regions */
+ EC_FLASH_REGION_COUNT,
};
struct ec_params_flash_region_info {