summaryrefslogtreecommitdiff
path: root/include/flash.h
diff options
context:
space:
mode:
authorRandall Spangler <rspangler@chromium.org>2013-05-24 15:07:27 -0700
committerChromeBot <chrome-bot@google.com>2013-06-03 14:32:38 -0700
commitb490e866dc14b55a99e53d14ade4543daeba157a (patch)
treec005129068632cbebb8684c96810ba60f28bbd15 /include/flash.h
parente52aba6ecac45d2c27acc78316e835620840408a (diff)
downloadchrome-ec-b490e866dc14b55a99e53d14ade4543daeba157a.tar.gz
Clean up flash section defines and increase lm4 image size
The firmware defines had two almost-identical sets. Coalesce into one consistent set. Link had 256 KB flash, but only allowed 2 80KB images. Future LM4-based platforms (slippy/peppy/falco/etc) will now use the entire flash, with RO=124KB, pstate=4KB, RW=128KB. This matches what the STM32 platforms do, where pstate is contiguous with the RO firmware. No functional change to STM32-based platforms. BUG=chrome-os-partner:19176 BRANCH=none TEST=build all platforms and dump_fmap ec.bin. - stm32-based platforms should report RO=61440@0, RW=65536@0x10000 - link should report RO=81920@0, RW=81920@0x14000 - slippy should report RO=129024@0, RW=131072@0x20000 Change-Id: I20b1d95c16250d9a5d228ead06eef03d96548823 Signed-off-by: Randall Spangler <rspangler@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/56655
Diffstat (limited to 'include/flash.h')
-rw-r--r--include/flash.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/include/flash.h b/include/flash.h
index 4bcbb8eb8f..2079032a0a 100644
--- a/include/flash.h
+++ b/include/flash.h
@@ -15,18 +15,18 @@
#define PHYSICAL_BANKS (CONFIG_FLASH_PHYSICAL_SIZE / CONFIG_FLASH_BANK_SIZE)
/* Read-only firmware offset and size in units of flash banks */
-#define RO_BANK_OFFSET (CONFIG_SECTION_RO_OFF / CONFIG_FLASH_BANK_SIZE)
-#define RO_BANK_COUNT (CONFIG_SECTION_RO_SIZE / CONFIG_FLASH_BANK_SIZE)
+#define RO_BANK_OFFSET (CONFIG_FW_RO_OFF / CONFIG_FLASH_BANK_SIZE)
+#define RO_BANK_COUNT (CONFIG_FW_RO_SIZE / CONFIG_FLASH_BANK_SIZE)
/* Read-write firmware offset and size in units of flash banks */
-#define RW_BANK_OFFSET (CONFIG_SECTION_RW_OFF / CONFIG_FLASH_BANK_SIZE)
-#define RW_BANK_COUNT (CONFIG_SECTION_RW_SIZE / CONFIG_FLASH_BANK_SIZE)
+#define RW_BANK_OFFSET (CONFIG_FW_RW_OFF / CONFIG_FLASH_BANK_SIZE)
+#define RW_BANK_COUNT (CONFIG_FW_RW_SIZE / CONFIG_FLASH_BANK_SIZE)
/* Persistent protection state flash offset / size / bank */
-#define PSTATE_OFFSET CONFIG_SECTION_FLASH_PSTATE_OFF
-#define PSTATE_SIZE CONFIG_SECTION_FLASH_PSTATE_SIZE
-#define PSTATE_BANK (PSTATE_OFFSET / CONFIG_FLASH_BANK_SIZE)
-#define PSTATE_BANK_COUNT (PSTATE_SIZE / CONFIG_FLASH_BANK_SIZE)
+#define PSTATE_OFFSET CONFIG_FW_PSTATE_OFF
+#define PSTATE_SIZE CONFIG_FW_PSTATE_SIZE
+#define PSTATE_BANK (PSTATE_OFFSET / CONFIG_FLASH_BANK_SIZE)
+#define PSTATE_BANK_COUNT (PSTATE_SIZE / CONFIG_FLASH_BANK_SIZE)
/*****************************************************************************/
/* Low-level methods, for use by flash_common. */