diff options
author | Shawn Nematbakhsh <shawnn@chromium.org> | 2015-09-07 13:47:48 -0700 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2015-09-16 14:49:32 -0700 |
commit | 1167cad6a88e45bbf6a5599f19d018cd6a8b5233 (patch) | |
tree | eaff44a061fa989b49a5c52fc58ef14f3ccb48c3 /include/config_std_internal_flash.h | |
parent | 558c465165acf494905fa59c822c7190b4646899 (diff) | |
download | chrome-ec-1167cad6a88e45bbf6a5599f19d018cd6a8b5233.tar.gz |
cleanup: Change meaning of storage offset CONFIGs
In order to support architectures with non-contiguous writable and
protected regions, change storage offsets to be relative to writable and
protected regions, rather than relative to "the start of the region of
storage belonging to the EC".
Spec doc available at https://goo.gl/fnzTvr.
BRANCH=None
BUG=chrome-os-partner:23796
TEST=With entire patch series, on both Samus and Glados:
- Verify 'version' EC console command is correct
- Verify 'flashrom -p ec -r read.bin' reads back EC image
- Verify software sync correctly flashes both EC and PD RW images
Signed-off-by: Shawn Nematbakhsh <shawnn@chromium.org>
Change-Id: I796f8e7305a6336495bd256a78774595cb16a2e4
Reviewed-on: https://chromium-review.googlesource.com/297823
Commit-Ready: Shawn N <shawnn@chromium.org>
Tested-by: Shawn N <shawnn@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'include/config_std_internal_flash.h')
-rw-r--r-- | include/config_std_internal_flash.h | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/include/config_std_internal_flash.h b/include/config_std_internal_flash.h index 51bd011304..35561a59da 100644 --- a/include/config_std_internal_flash.h +++ b/include/config_std_internal_flash.h @@ -67,11 +67,16 @@ #define CONFIG_RO_SIZE (CONFIG_FW_IMAGE_SIZE - CONFIG_FW_PSTATE_SIZE) #define CONFIG_RW_MEM_OFF (CONFIG_SHAREDLIB_MEM_OFF + \ CONFIG_SHAREDLIB_SIZE) -#define CONFIG_RW_STORAGE_OFF (CONFIG_SHAREDLIB_STORAGE_OFF + \ - CONFIG_SHAREDLIB_SIZE) +#define CONFIG_RW_STORAGE_OFF 0 #define CONFIG_RW_SIZE CONFIG_FW_IMAGE_SIZE -#define CONFIG_WP_OFF CONFIG_RO_STORAGE_OFF -#define CONFIG_WP_SIZE CONFIG_FW_IMAGE_SIZE +#define CONFIG_EC_PROTECTED_STORAGE_OFF 0 +#define CONFIG_EC_PROTECTED_STORAGE_SIZE CONFIG_RW_MEM_OFF +#define CONFIG_EC_WRITABLE_STORAGE_OFF CONFIG_RW_MEM_OFF +#define CONFIG_EC_WRITABLE_STORAGE_SIZE (CONFIG_FLASH_SIZE - \ + CONFIG_EC_WRITABLE_STORAGE_OFF) + +#define CONFIG_WP_STORAGE_OFF CONFIG_EC_PROTECTED_STORAGE_OFF +#define CONFIG_WP_STORAGE_SIZE CONFIG_EC_PROTECTED_STORAGE_SIZE #endif /* __CROS_EC_CONFIG_STD_INTERNAL_FLASH_H */ |