mb/google/reef: Cache EC's SKU ID on Coral

Change-Id: I1925f51d63290b8d08366b622d5df3aab3a7484e
Signed-off-by: Patrick Georgi <pgeorgi@google.com>
Reviewed-on: https://review.coreboot.org/21737
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Sumeet R Pawnikar <sumeet.r.pawnikar@intel.com>
This commit is contained in:
Patrick Georgi 2017-09-28 17:59:18 +02:00
parent 0e1ea279d0
commit 53b8a82e72
1 changed files with 6 additions and 2 deletions

View File

@ -26,8 +26,12 @@ enum {
uint8_t variant_board_sku(void)
{
// we know that the values are in 0..255
return google_chromeec_get_sku_id();
static int sku = -1;
if (sku == -1)
sku = google_chromeec_get_sku_id();
return sku;
}
void variant_nhlt_oem_overrides(const char **oem_id,