From e6f12d0d5025e276b9022ee2ff9a6d4d195029e8 Mon Sep 17 00:00:00 2001 From: Zhuohao Lee Date: Thu, 11 Mar 2021 12:07:57 +0800 Subject: [PATCH] rammus: get cbfs sar table name based on the sku id This patch overrides the get_wifi_sar_cbfs_filename() to return different sar table according to the sku id. BUG=b:173465272 TEST=checked bios log and the correct sar table was loaded. Change-Id: Ia30d760b1a029197d470818c73bfd2c00514652d Signed-off-by: Zhuohao Lee Reviewed-on: https://review.coreboot.org/c/coreboot/+/51413 Tested-by: build bot (Jenkins) Reviewed-by: Furquan Shaikh --- .../google/poppy/variants/rammus/mainboard.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/mainboard/google/poppy/variants/rammus/mainboard.c b/src/mainboard/google/poppy/variants/rammus/mainboard.c index 66e252739c..8c09b2a57e 100644 --- a/src/mainboard/google/poppy/variants/rammus/mainboard.c +++ b/src/mainboard/google/poppy/variants/rammus/mainboard.c @@ -4,6 +4,7 @@ #include #include #include +#include #define SKU_UNKNOWN 0xFFFFFFFF @@ -29,3 +30,17 @@ const char *smbios_system_sku(void) return sku_str; } + +const char *get_wifi_sar_cbfs_filename(void) +{ + const char *filename = NULL; + uint32_t sku_id; + + sku_id = variant_board_sku(); + if (sku_id & 0x200) + filename = "wifi_sar-shyvana.hex"; + else + filename = "wifi_sar-leona.hex"; + + return filename; +}