diff options
author | tim <tim2.lin@ite.corp-partner.google.com> | 2019-11-20 16:04:17 +0800 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2019-11-22 11:22:04 +0000 |
commit | f4e7f8be8f9ddccd6da1be7e630b3002bbad4292 (patch) | |
tree | c40c5077d4ee87b215e7bd971f154e94d841eb87 /core/riscv-rv32i/ec.lds.S | |
parent | 85b276f5158a544229073f24834147bb2ae5ebb8 (diff) | |
download | chrome-ec-f4e7f8be8f9ddccd6da1be7e630b3002bbad4292.tar.gz |
core/nds32 and riscv-rv32i/ec.lds.S: no assert if section is not present
When the h2ram section is not present, we don't need the
assert to check the space whether enough or not.
BUG=none
BRANCH=none
TEST=No error when we don't define configration of
CONFIG_HOSTCMD_x86 or CONFIG_H2RAM_SIZE.
Change-Id: Id5d0e674f65cfdb220bc996c597740390000d861
Signed-off-by: tim <tim2.lin@ite.corp-partner.google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1868132
Reviewed-by: Jett Rink <jettrink@chromium.org>
Diffstat (limited to 'core/riscv-rv32i/ec.lds.S')
-rw-r--r-- | core/riscv-rv32i/ec.lds.S | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/core/riscv-rv32i/ec.lds.S b/core/riscv-rv32i/ec.lds.S index 683e8f3e3c..53e6b99599 100644 --- a/core/riscv-rv32i/ec.lds.S +++ b/core/riscv-rv32i/ec.lds.S @@ -255,9 +255,10 @@ SECTIONS #endif __h2ram_end = .; } > H2RAM -#endif + ASSERT((__h2ram_end) <= (CONFIG_H2RAM_BASE + CONFIG_H2RAM_SIZE), "Not enough space for h2ram section.") +#endif #if !(defined(SECTION_IS_RO) && defined(CONFIG_FLASH)) /DISCARD/ : { |