From 467cce4d1c9d366ca0830a9add8c0a02396dab36 Mon Sep 17 00:00:00 2001 From: Shelley Chen Date: Wed, 7 Mar 2018 14:22:28 -0800 Subject: mb/google/poppy/variants/nami: Define smbios_mainboard_sku to return SKU IDs Return proper SKU IDs so that mosys can return the proper variant. BUG=b:74059798 BRANCH=None TEST=./util/abuild/abuild -p none -t google/poppy -x -a Change-Id: I665fa491de6e277fea5cc071b1f04a21317bccba Signed-off-by: Shelley Chen Reviewed-on: https://review.coreboot.org/25028 Tested-by: build bot (Jenkins) Reviewed-by: Furquan Shaikh --- src/mainboard/google/poppy/variants/nami/mainboard.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'src/mainboard/google/poppy/variants') diff --git a/src/mainboard/google/poppy/variants/nami/mainboard.c b/src/mainboard/google/poppy/variants/nami/mainboard.c index 5b3e2ea6a6..e2bc8958a3 100644 --- a/src/mainboard/google/poppy/variants/nami/mainboard.c +++ b/src/mainboard/google/poppy/variants/nami/mainboard.c @@ -13,10 +13,15 @@ * GNU General Public License for more details. */ +#include +#include +#include #include #include #include -#include +#include +#include +#include #define SKU_UNKNOWN 0xFFFF #define SKU_0_NAMI 0x3A7B @@ -49,3 +54,12 @@ void variant_devtree_update(void) break; } } + +const char *smbios_mainboard_sku(void) +{ + static char sku_str[9]; /* sku{0..65535} (basically up to FFFF) */ + + snprintf(sku_str, sizeof(sku_str), "sku%d", board_sku_id()); + + return sku_str; +} -- cgit v1.2.3