summaryrefslogtreecommitdiff
path: root/Makefile.rules
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2022-01-31 10:49:24 -0700
committerCommit Bot <commit-bot@chromium.org>2022-02-09 00:53:30 +0000
commit2e5b1b1f36ddab0a6769a0e016ba0ac92263dbfd (patch)
tree4395da83245f344f58124729ca9363fccf4f1f06 /Makefile.rules
parent395edacc422dff4b74ee2a594351421dbb9ae74e (diff)
downloadchrome-ec-2e5b1b1f36ddab0a6769a0e016ba0ac92263dbfd.tar.gz
Makefile: Switch to the Python script for CONFIG checking
This is the second attempt, fixing the problem with CONFIG_DAC and other options. These must be left in config_allowed but ignored if they show up as present in Kconfig. Leave the following in config_allowed since they are defined both as CONFIG options in ECOS and Kconfig options in Zephyr: AUDIO_CODEC DAC DMA EEPROM I2C_BITBANG PECI SPI UART_CONSOLE BUG=b:181323955 BRANCH=none TEST=./util/kconfig_check.py -c build/blipper/.config -a util/config_allowed.txt -p PLATFORM_EC_ -s zephyr/ -I ~/cosarm/src/third_party/zephyr/main -i DAC check See that this does not cause an error now Signed-off-by: Simon Glass <sjg@chromium.org> Change-Id: I1fc7ac9cde106c61dd28b30673830407aa8c1a29 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3425452 Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Diffstat (limited to 'Makefile.rules')
-rw-r--r--Makefile.rules23
1 files changed, 22 insertions, 1 deletions
diff --git a/Makefile.rules b/Makefile.rules
index 9808fa712d..39a18bb12f 100644
--- a/Makefile.rules
+++ b/Makefile.rules
@@ -230,7 +230,28 @@ print-boards:
$(sort $(boards)))
ifeq ($(ALLOW_CONFIG),)
-cmd_check_allowed = ./util/check_allowed.sh ${config} util/config_allowed.txt .
+
+# These are options defined by both ECOS and Zephyr. We need to tolerate this
+# rather than begging the user to drop them from config_allowed since when the
+# Zephyr Kconfig is not available (-I argument below does not point to the right
+# place), they will not be considered a problem.
+# You may add new options here if needed, although this should only occur if
+# Zephyr upstream happens to add the same option, since we are requiring new
+# ECOS options to have a corresponding Kconfig anyway.
+conflicting_options := \
+ AUDIO_CODEC \
+ DAC \
+ DMA \
+ EEPROM \
+ I2C_BITBANG \
+ PECI \
+ SPI \
+ UART_CONSOLE
+
+cmd_check_allowed = ./util/kconfig_check.py -c ${config} \
+ -a util/config_allowed.txt -p PLATFORM_EC_ -s zephyr/ \
+ -I $(abspath ../../../src/third_party/zephyr/main) \
+ $(foreach opt,$(conflicting_options),-i $(opt)) check
else
cmd_check_allowed = true
endif