summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorVincent Palatin <vpalatin@chromium.org>2018-02-26 12:57:20 +0100
committerchrome-bot <chrome-bot@chromium.org>2018-03-01 16:13:10 -0800
commit045aef2cda7284dae0afc04957a42320f0497149 (patch)
tree98e48aac93a97b736ceba2d48baef7a7ea4ab145 /Makefile
parent2e9ea7bf8510dcb8f915fc080564c520249711aa (diff)
downloadchrome-ec-045aef2cda7284dae0afc04957a42320f0497149.tar.gz
make EC_FEATURE_RWSIG definition more useful
Also define the EC_FEATURE_RWSIG feature bit if the RO firmware contains the RWSIG task but not the RW. Given the RWSIG verification task is not terribly useful in RW (where it is never executed), it can be skipped there but the host program trying to detect RWSIG usage (e.g. flashrom) still wants to be able to detect it. In order to be able to do so, add the HAS_TASK_xXx_RO and HAS_TASK_xXx_RW flags which define the tasks defined in the other partition (at compilation-time you might still run a frankeinstein combo). Fix ectool 'inventory' to avoid segfaulting on missing feature string definition. Signed-off-by: Vincent Palatin <vpalatin@chromium.org> BRANCH=none BUG=b:36125319 TEST=on ZerbleBarn, run 'ectool inventory', also uses flashrom to re-flash the RW partition. Change-Id: I224a6cc4aef956204792a2cc04ad12aaed5abf47 Reviewed-on: https://chromium-review.googlesource.com/937262 Commit-Ready: Vincent Palatin <vpalatin@chromium.org> Tested-by: Vincent Palatin <vpalatin@chromium.org> Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 4 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 0df7553f22..82932b6b93 100644
--- a/Makefile
+++ b/Makefile
@@ -105,8 +105,10 @@ _tsk_cfg:= $(filter $(_tsk_cfg_ro), $(_tsk_cfg_rw))
_tsk_cfg_ro:= $(filter-out $(_tsk_cfg), $(_tsk_cfg_ro))
_tsk_cfg_rw:= $(filter-out $(_tsk_cfg), $(_tsk_cfg_rw))
-CPPFLAGS_RO+=$(foreach t,$(_tsk_cfg_ro),-D$(t))
-CPPFLAGS_RW+=$(foreach t,$(_tsk_cfg_rw),-D$(t))
+CPPFLAGS_RO+=$(foreach t,$(_tsk_cfg_ro),-D$(t)) \
+ $(foreach t,$(_tsk_cfg_rw),-D$(t)_RW)
+CPPFLAGS_RW+=$(foreach t,$(_tsk_cfg_rw),-D$(t)) \
+ $(foreach t,$(_tsk_cfg_ro),-D$(t)_RO)
CPPFLAGS+=$(foreach t,$(_tsk_cfg),-D$(t))
_flag_cfg_ro:=$(shell $(CPP) $(CPPFLAGS) -P -dM -Ichip/$(CHIP) \