[coreboot-gerrit] Change in ...coreboot[master]: mediatek/mt8183: Add option SOC_MEDIATEK_MT8183_MINIMAL_BOOTBLOCK

You-Cheng Syu (Code Review) gerrit at coreboot.org
Thu Dec 20 10:46:05 CET 2018


You-Cheng Syu has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/30330


Change subject: mediatek/mt8183: Add option SOC_MEDIATEK_MT8183_MINIMAL_BOOTBLOCK
......................................................................

mediatek/mt8183: Add option SOC_MEDIATEK_MT8183_MINIMAL_BOOTBLOCK

Some boards may to want minimize bootblock size by moving some
initializations from bootblock to later stages. We could have a new
option to eliminate the initializations in bootblock.

BRANCH=none
BUG=b:120588396
TEST=build successfully

Change-Id: I7d482f06a8cc97be0c390ed863aa3ac05d4a3459
Signed-off-by: You-Cheng Syu <youcheng at google.com>
---
M src/soc/mediatek/mt8183/Kconfig
M src/soc/mediatek/mt8183/Makefile.inc
M src/soc/mediatek/mt8183/bootblock.c
3 files changed, 10 insertions(+), 1 deletion(-)



  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/30/30330/1

diff --git a/src/soc/mediatek/mt8183/Kconfig b/src/soc/mediatek/mt8183/Kconfig
index b58be7f..5dc490c 100644
--- a/src/soc/mediatek/mt8183/Kconfig
+++ b/src/soc/mediatek/mt8183/Kconfig
@@ -19,4 +19,8 @@
 	select VBOOT_STARTS_IN_BOOTBLOCK
 	select VBOOT_SEPARATE_VERSTAGE
 
+config SOC_MEDIATEK_MT8183_MINIMAL_BOOTBLOCK
+	bool
+	default n
+
 endif
diff --git a/src/soc/mediatek/mt8183/Makefile.inc b/src/soc/mediatek/mt8183/Makefile.inc
index b981e45..7faabac 100644
--- a/src/soc/mediatek/mt8183/Makefile.inc
+++ b/src/soc/mediatek/mt8183/Makefile.inc
@@ -3,11 +3,14 @@
 bootblock-y += auxadc.c
 bootblock-y += bootblock.c
 bootblock-y += ../common/gpio.c gpio.c
-bootblock-y += ../common/pll.c pll.c
 bootblock-$(CONFIG_SPI_FLASH) += ../common/spi.c spi.c
 bootblock-y += ../common/timer.c
 bootblock-y += ../common/uart.c
+
+ifneq ($(CONFIG_SOC_MEDIATEK_MT8183_MINIMAL_BOOTBLOCK),y)
+bootblock-y += ../common/pll.c pll.c
 bootblock-y += ../common/wdt.c
+endif
 
 decompressor-y += decompressor.c
 decompressor-y += ../common/mmu_operations.c
diff --git a/src/soc/mediatek/mt8183/bootblock.c b/src/soc/mediatek/mt8183/bootblock.c
index d7d5c2d..ff79c15 100644
--- a/src/soc/mediatek/mt8183/bootblock.c
+++ b/src/soc/mediatek/mt8183/bootblock.c
@@ -13,6 +13,7 @@
  * GNU General Public License for more details.
  */
 
+#if !IS_ENABLED(CONFIG_SOC_MEDIATEK_MT8183_MINIMAL_BOOTBLOCK)
 #include <bootblock_common.h>
 #include <soc/pll.h>
 #include <soc/wdt.h>
@@ -22,3 +23,4 @@
 	mt_pll_init();
 	mtk_wdt_init();
 }
+#endif

-- 
To view, visit https://review.coreboot.org/c/coreboot/+/30330
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I7d482f06a8cc97be0c390ed863aa3ac05d4a3459
Gerrit-Change-Number: 30330
Gerrit-PatchSet: 1
Gerrit-Owner: You-Cheng Syu <youcheng at google.com>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20181220/e40e7dcc/attachment-0001.html>


More information about the coreboot-gerrit mailing list