From 251cbd837192aef656762186cb35da70eb45a848 Mon Sep 17 00:00:00 2001 From: Edward O'Callaghan Date: Tue, 29 Jul 2014 20:52:17 +1000 Subject: lenovo/t530/mainboard.c: Add EC info to SMBIOS As is in: 91175bb lenovo/x201 & x230: Add EC info to SMBIOS This is needed for the Linux driver for the Lenovo's to properly attach. Change-Id: Ib910b25f392d9d3d6362b6909ce9fd4eeae9a096 Signed-off-by: Edward O'Callaghan Reviewed-on: http://review.coreboot.org/6399 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer --- src/mainboard/lenovo/t530/mainboard.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'src/mainboard/lenovo/t530/mainboard.c') diff --git a/src/mainboard/lenovo/t530/mainboard.c b/src/mainboard/lenovo/t530/mainboard.c index b82ba7c085..5af6cec3da 100644 --- a/src/mainboard/lenovo/t530/mainboard.c +++ b/src/mainboard/lenovo/t530/mainboard.c @@ -169,12 +169,28 @@ static void mainboard_init(device_t dev) 0x42, 0x142); } +static int mainboard_smbios_data(device_t dev, int *handle, unsigned long *current) +{ + int len; + char tpec[] = "IBM ThinkPad Embedded Controller -[ ]-"; + const char *oem_strings[] = { + tpec, + }; + + h8_build_id_and_function_spec_version(tpec + 35, 17); + len = smbios_write_type11(current, (*handle)++, oem_strings, ARRAY_SIZE(oem_strings)); + + return len; +} + // mainboard_enable is executed as first thing after // enumerate_buses(). static void mainboard_enable(device_t dev) { dev->ops->init = mainboard_init; + dev->ops->get_smbios_data = mainboard_smbios_data; + #if CONFIG_VGA_ROM_RUN /* Install custom int15 handler for VGA OPROM */ mainboard_interrupt_handlers(0x15, &int15_handler); -- cgit v1.2.3