summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorDino Li <Dino.Li@ite.com.tw>2017-03-20 15:00:39 +0800
committerchrome-bot <chrome-bot@chromium.org>2017-03-20 23:12:05 -0700
commit75602486bb01e03ccab24c85c60fbc0783f2068b (patch)
treeaf63ce848fabf1cf535a9bfe1948358b8a5ea7c9 /core
parent87e78e383a0ed469e78f5fadfd6c38bdccc8d913 (diff)
downloadchrome-ec-75602486bb01e03ccab24c85c60fbc0783f2068b.tar.gz
nds32: lds: compute image size at link time
Signed-off-by: Dino Li <dino.li@ite.com.tw> BRANCH=none BUG=b:36228568 TEST=Check '__image_size' of map file and binary size for both RO and RW images. Change-Id: I43b58a199a30827293531505de30f0ddfb72b917 Reviewed-on: https://chromium-review.googlesource.com/456664 Commit-Ready: Dino Li <Dino.Li@ite.com.tw> Tested-by: Dino Li <Dino.Li@ite.com.tw> Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'core')
-rw-r--r--core/nds32/ec.lds.S3
1 files changed, 1 insertions, 2 deletions
diff --git a/core/nds32/ec.lds.S b/core/nds32/ec.lds.S
index 1451c5a17c..df4a7aeaa8 100644
--- a/core/nds32/ec.lds.S
+++ b/core/nds32/ec.lds.S
@@ -214,8 +214,7 @@ SECTIONS
} > IRAM
- /* TODO(b:36228568): Properly compute image size for nds32. */
- __image_size = 0;
+ __image_size = LOADADDR(.data) + SIZEOF(.data) - FW_OFF(SECTION);
#ifdef CONFIG_LPC
.h2ram (NOLOAD) : {