google/*: Clean up Kconfg board selection for Google MTK boards
This patch tries to standardize and simplify the Kconfig option layout
for Google boards with MediaTek SoCs and align them to the scheme used
with other Arm-based Google boards.
Change-Id: I40880e7609ba703d0053ad01da742871e54d4e7a
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/79063
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
diff --git a/src/mainboard/google/corsola/Kconfig b/src/mainboard/google/corsola/Kconfig
index 805a83a..fe6e6d6 100644
--- a/src/mainboard/google/corsola/Kconfig
+++ b/src/mainboard/google/corsola/Kconfig
@@ -1,8 +1,36 @@
## SPDX-License-Identifier: GPL-2.0-only
-# Umbrella option to be selected by variant boards.
config BOARD_GOOGLE_CORSOLA_COMMON
- def_bool n
+ def_bool BOARD_GOOGLE_KINGLER_COMMON || \
+ BOARD_GOOGLE_KRABBY_COMMON || \
+ BOARD_GOOGLE_STARYU_COMMON
+
+config BOARD_GOOGLE_KINGLER_COMMON
+ def_bool BOARD_GOOGLE_KINGLER || \
+ BOARD_GOOGLE_PONYTA || \
+ BOARD_GOOGLE_STEELIX || \
+ BOARD_GOOGLE_VOLTORB
+
+config BOARD_GOOGLE_KRABBY_COMMON
+ def_bool BOARD_GOOGLE_CHINCHOU || \
+ BOARD_GOOGLE_KRABBY || \
+ BOARD_GOOGLE_MAGIKARP || \
+ BOARD_GOOGLE_TENTACRUEL
+
+config BOARD_GOOGLE_STARYU_COMMON
+ def_bool BOARD_GOOGLE_STARMIE
+ select MIPI_PANEL_STA_HIMAX83102_J02
+ select MIPI_PANEL_STA_ILI9882T
+
+if BOARD_GOOGLE_CORSOLA_COMMON
+
+config CORSOLA_SDCARD_INIT
+ def_bool BOARD_GOOGLE_MAGIKARP || \
+ BOARD_GOOGLE_TENTACRUEL || \
+ BOARD_GOOGLE_KINGLER_COMMON
+
+config BOARD_SPECIFIC_OPTIONS
+ def_bool y
select SOC_MEDIATEK_MT8186
select BOARD_ROMSIZE_KB_8192
select MAINBOARD_HAS_CHROMEOS
@@ -21,62 +49,19 @@
select MAINBOARD_HAS_TPM2 if VBOOT
select MAINBOARD_HAS_NATIVE_VGA_INIT
select HAVE_LINEAR_FRAMEBUFFER
+ select DRIVER_ANALOGIX_ANX7625 if BOARD_GOOGLE_CHINCHOU || \
+ BOARD_GOOGLE_KINGLER || \
+ BOARD_GOOGLE_PONYTA || \
+ BOARD_GOOGLE_STEELIX || \
+ BOARD_GOOGLE_VOLTORB
+ select DRIVER_PARADE_PS8640 if BOARD_GOOGLE_KRABBY || \
+ BOARD_GOOGLE_MAGIKARP || \
+ BOARD_GOOGLE_STEELIX || \
+ BOARD_GOOGLE_TENTACRUEL
select RTC
select FW_CONFIG
select FW_CONFIG_SOURCE_CHROMEEC_CBI
-config BOARD_GOOGLE_KINGLER_COMMON
- def_bool n
- select BOARD_GOOGLE_CORSOLA_COMMON
-
-config BOARD_GOOGLE_KRABBY_COMMON
- def_bool n
- select BOARD_GOOGLE_CORSOLA_COMMON
-
-config BOARD_GOOGLE_STARYU_COMMON
- def_bool n
- select BOARD_GOOGLE_CORSOLA_COMMON
-
-config BOARD_GOOGLE_KINGLER
- select BOARD_GOOGLE_KINGLER_COMMON
- select DRIVER_ANALOGIX_ANX7625
-
-config BOARD_GOOGLE_PONYTA
- select BOARD_GOOGLE_KINGLER_COMMON
- select DRIVER_ANALOGIX_ANX7625
-
-config BOARD_GOOGLE_STEELIX
- select BOARD_GOOGLE_KINGLER_COMMON
- select DRIVER_ANALOGIX_ANX7625
- select DRIVER_PARADE_PS8640
-
-config BOARD_GOOGLE_VOLTORB
- select BOARD_GOOGLE_KINGLER_COMMON
- select DRIVER_ANALOGIX_ANX7625
-
-config BOARD_GOOGLE_KRABBY
- select BOARD_GOOGLE_KRABBY_COMMON
- select DRIVER_PARADE_PS8640
-
-config BOARD_GOOGLE_CHINCHOU
- select BOARD_GOOGLE_KRABBY_COMMON
- select DRIVER_ANALOGIX_ANX7625
-
-config BOARD_GOOGLE_TENTACRUEL
- select BOARD_GOOGLE_KRABBY_COMMON
- select DRIVER_PARADE_PS8640
-
-config BOARD_GOOGLE_MAGIKARP
- select BOARD_GOOGLE_KRABBY_COMMON
- select DRIVER_PARADE_PS8640
-
-config BOARD_GOOGLE_STARMIE
- select BOARD_GOOGLE_STARYU_COMMON
- select MIPI_PANEL_STA_HIMAX83102_J02
- select MIPI_PANEL_STA_ILI9882T
-
-if BOARD_GOOGLE_CORSOLA_COMMON
-
config VBOOT
select EC_GOOGLE_CHROMEEC_SWITCHES
select VBOOT_VBNV_FLASH
@@ -101,13 +86,6 @@
int
default 7
-config SDCARD_INIT
- bool
- default y if BOARD_GOOGLE_MAGIKARP
- default y if BOARD_GOOGLE_TENTACRUEL
- default y if BOARD_GOOGLE_KINGLER_COMMON
- default n if BOARD_GOOGLE_KRABBY_COMMON
-
config DRIVER_TPM_SPI_BUS
hex
default 0x2