Duncan Laurie has submitted this change and it was merged. ( https://review.coreboot.org/c/coreboot/+/32002 )
Change subject: mb/google/sarien: Add SKU for boards with signed EC ......................................................................
mb/google/sarien: Add SKU for boards with signed EC
To support both boards with the same firmware add a SKU for each variant that is used to include the proper EC firmware image to match what the EC is expecting.
BUG=b:119490232 TEST=tested by faking the EC response to ensure that the OS and firmware update tools are able to determine the correct model based on the value returned by the EC.
Change-Id: Iaa677975e0bccbee5ec8a39821fe1637f08270fa Signed-off-by: Duncan Laurie dlaurie@google.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/32002 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Furquan Shaikh furquan@google.com --- M src/mainboard/google/sarien/sku.c M src/mainboard/google/sarien/variants/arcada/include/variant/variant.h M src/mainboard/google/sarien/variants/sarien/include/variant/variant.h 3 files changed, 19 insertions(+), 8 deletions(-)
Approvals: build bot (Jenkins): Verified Furquan Shaikh: Looks good to me, approved
diff --git a/src/mainboard/google/sarien/sku.c b/src/mainboard/google/sarien/sku.c index 708793d..d0b48f0 100644 --- a/src/mainboard/google/sarien/sku.c +++ b/src/mainboard/google/sarien/sku.c @@ -14,15 +14,22 @@ */
#include <boardid.h> +#include <ec/google/wilco/commands.h> #include <smbios.h> #include <variant/variant.h>
uint32_t sku_id(void) { - return VARIANT_SKU_ID; + if (wilco_ec_signed_fw()) + return VARIANT_SKU_ID_SIGNED_EC; + else + return VARIANT_SKU_ID; }
const char *smbios_system_sku(void) { - return VARIANT_SKU_NAME; + if (wilco_ec_signed_fw()) + return VARIANT_SKU_NAME_SIGNED_EC; + else + return VARIANT_SKU_NAME; } diff --git a/src/mainboard/google/sarien/variants/arcada/include/variant/variant.h b/src/mainboard/google/sarien/variants/arcada/include/variant/variant.h index d128432..da1189e 100644 --- a/src/mainboard/google/sarien/variants/arcada/include/variant/variant.h +++ b/src/mainboard/google/sarien/variants/arcada/include/variant/variant.h @@ -16,8 +16,10 @@ #ifndef VARIANT_H #define VARIANT_H
-/* Arcada is SKU ID 2 */ -#define VARIANT_SKU_ID 2 -#define VARIANT_SKU_NAME "sku2" +/* Arcada is SKU ID 2 and 4 */ +#define VARIANT_SKU_ID 2 +#define VARIANT_SKU_NAME "sku2" +#define VARIANT_SKU_ID_SIGNED_EC 4 +#define VARIANT_SKU_NAME_SIGNED_EC "sku4"
#endif diff --git a/src/mainboard/google/sarien/variants/sarien/include/variant/variant.h b/src/mainboard/google/sarien/variants/sarien/include/variant/variant.h index d367505..bbb3e9e 100644 --- a/src/mainboard/google/sarien/variants/sarien/include/variant/variant.h +++ b/src/mainboard/google/sarien/variants/sarien/include/variant/variant.h @@ -16,8 +16,10 @@ #ifndef VARIANT_H #define VARIANT_H
-/* Sarien is SKU ID 1 */ -#define VARIANT_SKU_ID 1 -#define VARIANT_SKU_NAME "sku1" +/* Sarien is SKU ID 1 and 3 */ +#define VARIANT_SKU_ID 1 +#define VARIANT_SKU_NAME "sku1" +#define VARIANT_SKU_ID_SIGNED_EC 3 +#define VARIANT_SKU_NAME_SIGNED_EC "sku3"
#endif