mb/google/zork: Add FP enable for Morphius

Add FP enable/disable based on SKU ID for Morphius. This is meant
to resolve a UMA issue with Morphius devices that had the FPMCU
populated on non-fp devices.  Since the FPMCU is present, and the
firmware enables the power GPIO's based on variant, not SKU, the
devices were reporting data on fingerprint errantly.

BUG=b:258040377
TEST=Flash to Morphius, test FP.
Disable test SKU, flash on Morphius, test FP.

Change-Id: If5794a9a1b7eb3daaa4cdfd1354dfb0c688624fd
Signed-off-by: Jon Murphy <jpmurphy@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/78622
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Eric Lai <ericllai@google.com>
Reviewed-by: Matt DeVillier <matt.devillier@amd.corp-partner.google.com>
This commit is contained in:
Jon Murphy 2023-10-23 20:34:37 -06:00 committed by Felix Held
parent 632ca01a04
commit 10201aa99d
2 changed files with 31 additions and 1 deletions

View File

@ -183,7 +183,7 @@ int variant_get_daughterboard_id(void)
return extract_field(FW_CONFIG_MASK_DB_INDEX, FW_CONFIG_DB_INDEX_SHIFT);
}
bool variant_has_fingerprint(void)
__weak bool variant_has_fingerprint(void)
{
if (CONFIG(VARIANT_HAS_FPMCU))
return true;

View File

@ -2,6 +2,17 @@
#include <baseboard/variants.h>
#define MORPHIUS_SKU_1 0x5A010010
#define MORPHIUS_SKU_2 0x5A010011
#define MORPHIUS_SKU_3 0x5A010012
#define MORPHIUS_SKU_4 0x5A010014
#define MORPHIUS_SKU_5 0x5A010029
#define MORPHIUS_SKU_11 0x5A010025
#define MORPHIUS_SKU_12 0x5A010026
#define MORPHIUS_SKU_13 0x5A010013
#define MORPHIUS_SKU_14 0x5A010028
#define MORPHIUS_SKU_15 0x5A010016
void variant_devtree_update(void)
{
/*
@ -10,3 +21,22 @@ void variant_devtree_update(void)
if (!(variant_has_emmc() || boot_is_factory_unprovisioned()))
DEV_PTR(emmc)->enabled = 0;
}
bool variant_has_fingerprint(void)
{
switch (sku_id()) {
case MORPHIUS_SKU_1:
case MORPHIUS_SKU_2:
case MORPHIUS_SKU_3:
case MORPHIUS_SKU_4:
case MORPHIUS_SKU_5:
case MORPHIUS_SKU_11:
case MORPHIUS_SKU_12:
case MORPHIUS_SKU_13:
case MORPHIUS_SKU_14:
case MORPHIUS_SKU_15:
return true;
default:
return false;
}
}