summaryrefslogtreecommitdiff
path: root/src/mainboard/google
diff options
context:
space:
mode:
authorBhanu Prakash Maiya <bhanumaiya@google.com>2020-08-11 21:05:40 -0700
committerAaron Durbin <adurbin@chromium.org>2020-08-13 22:59:21 +0000
commitf852137c810044491eb216d70a18ae0fcb298a8b (patch)
treeab143705428b0abbfd03799bc573a5bdd1a1a75a /src/mainboard/google
parent7b54c15a676636961ae7d449e439a89acf669ec6 (diff)
mb/google/zork: Remove validity checks for FW_CONFIG in CBI
After confirming that all zork variants and phases have valid FW_CONFIG value in CBI, this patch is dropping FW_CONFIG validity checks like VARIANT_HAS_FW_CONFIG and VARIANT_BOARD_VER_FW_CONFIG_VALID in Kconfig and will also remove associated helper functions. BRANCH=none BUG=b:162344105,b:152817444 TEST=Check if FW_CONFIG bits can be read in coreboot and FW_CONIFG helper function do not return 0 if board has a valid FW_CONFIG in CBI. Signed-off-by: Bhanu Prakash Maiya <bhanumaiya@google.com> Change-Id: I633dc7c500ef8759f3fffb0db6b76d96257c3c9a Reviewed-on: https://review.coreboot.org/c/coreboot/+/44422 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Aaron Durbin <adurbin@chromium.org> Reviewed-by: Furquan Shaikh <furquan@google.com>
Diffstat (limited to 'src/mainboard/google')
-rw-r--r--src/mainboard/google/zork/Kconfig12
-rw-r--r--src/mainboard/google/zork/variants/baseboard/helpers.c26
-rw-r--r--src/mainboard/google/zork/variants/baseboard/include/baseboard/variants.h2
3 files changed, 0 insertions, 40 deletions
diff --git a/src/mainboard/google/zork/Kconfig b/src/mainboard/google/zork/Kconfig
index 1e1b790835..c4a8f330bd 100644
--- a/src/mainboard/google/zork/Kconfig
+++ b/src/mainboard/google/zork/Kconfig
@@ -143,18 +143,6 @@ config PICASSO_FW_B_POSITION
Location of the AMD firmware in the RW_B region. This is the
start of the RW-A region + 64 bytes for the cbfs header.
-config VARIANT_HAS_FW_CONFIG
- bool
- help
- Honor FW_CONFIG in CBI.
-
-config VARIANT_BOARD_VER_FW_CONFIG_VALID
- int
- default 256
- depends on VARIANT_HAS_FW_CONFIG
- help
- Which board version did FW_CONFIG become valid in CBI.
-
config VARIANT_SUPPORTS_PRE_V3_SCHEMATICS
bool
default y if BOARD_GOOGLE_TREMBYLE
diff --git a/src/mainboard/google/zork/variants/baseboard/helpers.c b/src/mainboard/google/zork/variants/baseboard/helpers.c
index 7dc9fd3bd1..3f2b0688c7 100644
--- a/src/mainboard/google/zork/variants/baseboard/helpers.c
+++ b/src/mainboard/google/zork/variants/baseboard/helpers.c
@@ -48,36 +48,10 @@ enum {
FW_CONFIG_SHIFT_FAN = 27,
};
-int variant_fw_config_valid(void)
-{
- static uint32_t board_version;
- const uint32_t bv_valid = CONFIG_VARIANT_BOARD_VER_FW_CONFIG_VALID;
-
- if (!CONFIG(VARIANT_HAS_FW_CONFIG))
- return 0;
-
- /* Fast path for non-zero board version. */
- if (board_version >= bv_valid)
- return 1;
-
- if (google_chromeec_cbi_get_board_version(&board_version)) {
- printk(BIOS_ERR, "Unable to obtain board version for FW_CONFIG\n");
- return 0;
- }
-
- if (board_version >= bv_valid)
- return 1;
-
- return 0;
-}
-
static int get_fw_config(uint32_t *val)
{
static uint32_t known_value;
- if (!variant_fw_config_valid())
- return -1;
-
if (known_value) {
*val = known_value;
return 0;
diff --git a/src/mainboard/google/zork/variants/baseboard/include/baseboard/variants.h b/src/mainboard/google/zork/variants/baseboard/include/baseboard/variants.h
index 93aad0ff5a..98ba56530a 100644
--- a/src/mainboard/google/zork/variants/baseboard/include/baseboard/variants.h
+++ b/src/mainboard/google/zork/variants/baseboard/include/baseboard/variants.h
@@ -56,8 +56,6 @@ const fsp_dxio_descriptor *baseboard_get_dxio_descriptors(size_t *num);
const fsp_ddi_descriptor *baseboard_get_ddi_descriptors(size_t *num);
/* Retrieve attributes from FW_CONFIG in CBI. */
-/* Return 1 if FW_CONFIG expected to be valid, else 0. */
-int variant_fw_config_valid(void);
/* Return 0 if non-existent, 1 if present. */
int variant_has_emmc(void);
/* Return 0 if non-existent, 1 if present. */