summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/ec/google/chromeec/Kconfig36
-rw-r--r--src/ec/google/chromeec/Makefile.mk12
2 files changed, 8 insertions, 40 deletions
diff --git a/src/ec/google/chromeec/Kconfig b/src/ec/google/chromeec/Kconfig
index e8a5d58ab0..7a8777fbdb 100644
--- a/src/ec/google/chromeec/Kconfig
+++ b/src/ec/google/chromeec/Kconfig
@@ -110,22 +110,10 @@ config EC_GOOGLE_CHROMEEC_RTC
Enable support for the real-time clock on the ChromeOS EC. This
uses the EC_CMD_RTC_GET_VALUE command to read the current time.
-choice
- prompt "Chrome EC firmware source"
- default EC_GOOGLE_CHROMEEC_FIRMWARE_NONE
-
- config EC_GOOGLE_CHROMEEC_FIRMWARE_NONE
- bool "No EC firmware is included"
- help
- No EC firmware is included in the image.
-
- config EC_GOOGLE_CHROMEEC_FIRMWARE_EXTERNAL
- bool "External EC firmware is included"
+config EC_GOOGLE_CHROMEEC_FIRMWARE_EXTERNAL
+ bool "Include an external EC firmware binary"
help
- Include EC firmware binary in the image from an external source.
- It is expected to be built externally.
-
-endchoice
+ Include a precompiled EC firmware binary in the image.
config EC_GOOGLE_CHROMEEC_FIRMWARE_FILE
string "Chrome EC firmware path and filename"
@@ -133,23 +121,11 @@ config EC_GOOGLE_CHROMEEC_FIRMWARE_FILE
help
The path and filename of the EC firmware file to use.
-choice
- prompt "Chrome EC firmware source for PD"
+config EC_GOOGLE_CHROMEEC_PD_FIRMWARE_EXTERNAL
+ bool "Include an external PD firmware binary"
depends on EC_GOOGLE_CHROMEEC_PD
- default EC_GOOGLE_CHROMEEC_PD_FIRMWARE_NONE
-
- config EC_GOOGLE_CHROMEEC_PD_FIRMWARE_NONE
- bool "No PD firmware is included"
- help
- No PD firmware is included in the image.
-
- config EC_GOOGLE_CHROMEEC_PD_FIRMWARE_EXTERNAL
- bool "External PD firmware is included"
help
- Include PD firmware binary in the image from an external source.
- It is expected to be built externally.
-
-endchoice
+ Include a precompiled PD firmware binary in the image.
config EC_GOOGLE_CHROMEEC_PD_FIRMWARE_FILE
string "Chrome EC firmware path and filename for PD"
diff --git a/src/ec/google/chromeec/Makefile.mk b/src/ec/google/chromeec/Makefile.mk
index a8d2960fe1..6465c2cd6d 100644
--- a/src/ec/google/chromeec/Makefile.mk
+++ b/src/ec/google/chromeec/Makefile.mk
@@ -57,7 +57,7 @@ CHROMEEC_SOURCE ?= $(top)/3rdparty/chromeec
# use to update the EC. ecrw is the main embedded controller's firmware,
# pdrw is for a USB PD controller.
-ifneq ($(CONFIG_EC_GOOGLE_CHROMEEC_FIRMWARE_NONE),y)
+ifeq ($(CONFIG_EC_GOOGLE_CHROMEEC_FIRMWARE_EXTERNAL),y)
cbfs-files-y += ecrw
ecrw-file := $(obj)/mainboard/$(MAINBOARDDIR)/ecrw
@@ -69,21 +69,17 @@ ecrw.hash-file := $(obj)/mainboard/$(MAINBOARDDIR)/ecrw.hash
ecrw.hash-name := ecrw.hash
ecrw.hash-type := raw
-ifeq ($(CONFIG_EC_GOOGLE_CHROMEEC_FIRMWARE_EXTERNAL),y)
CONFIG_EC_GOOGLE_CHROMEEC_FIRMWARE_FILE := $(call strip_quotes,$(CONFIG_EC_GOOGLE_CHROMEEC_FIRMWARE_FILE))
$(obj)/mainboard/$(MAINBOARDDIR)/ecrw: $(CONFIG_EC_GOOGLE_CHROMEEC_FIRMWARE_FILE)
cp $(CONFIG_EC_GOOGLE_CHROMEEC_FIRMWARE_FILE) $@
-endif
$(obj)/mainboard/$(MAINBOARDDIR)/ecrw.hash: $(obj)/mainboard/$(MAINBOARDDIR)/ecrw
openssl dgst -sha256 -binary $< > $@
endif
-ifeq ($(CONFIG_EC_GOOGLE_CHROMEEC_PD),y)
-
-ifneq ($(CONFIG_EC_GOOGLE_CHROMEEC_PD_FIRMWARE_NONE),y)
+ifeq ($(CONFIG_EC_GOOGLE_CHROMEEC_PD_FIRMWARE_EXTERNAL),y)
cbfs-files-y += pdrw
pdrw-file := $(obj)/mainboard/$(MAINBOARDDIR)/pdrw
@@ -95,12 +91,10 @@ pdrw.hash-file := $(obj)/mainboard/$(MAINBOARDDIR)/pdrw.hash
pdrw.hash-name := pdrw.hash
pdrw.hash-type := raw
-ifeq ($(CONFIG_EC_GOOGLE_CHROMEEC_PD_FIRMWARE_EXTERNAL),y)
CONFIG_EC_GOOGLE_CHROMEEC_PD_FIRMWARE_FILE := $(call strip_quotes,$(CONFIG_EC_GOOGLE_CHROMEEC_PD_FIRMWARE_FILE))
$(obj)/mainboard/$(MAINBOARDDIR)/pdrw: $(CONFIG_EC_GOOGLE_CHROMEEC_PD_FIRMWARE_FILE)
cp $(CONFIG_EC_GOOGLE_CHROMEEC_PD_FIRMWARE_FILE) $@
-endif
$(obj)/mainboard/$(MAINBOARDDIR)/pdrw.hash: $(obj)/mainboard/$(MAINBOARDDIR)/pdrw
openssl dgst -sha256 -binary $< > $@
@@ -108,5 +102,3 @@ $(obj)/mainboard/$(MAINBOARDDIR)/pdrw.hash: $(obj)/mainboard/$(MAINBOARDDIR)/pdr
endif
endif
-
-endif