Piotr Kleinschmidt has uploaded this change for review.
src/arch/x86/smbios.c: add SMBIOS type 16 structure
Change-Id: I590ebf89ecb3f97a9ce028ca34696e5809d66d49
Signed-off-by: Piotr Kleinschmidt <piotr.kleins@gmail.com>
---
M src/arch/x86/smbios.c
M src/include/smbios.h
2 files changed, 18 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/88/35888/1
diff --git a/src/arch/x86/smbios.c b/src/arch/x86/smbios.c
index 4eb8726..4e8a794 100644
--- a/src/arch/x86/smbios.c
+++ b/src/arch/x86/smbios.c
@@ -527,6 +527,11 @@
return "";
}
+int __weak fill_mainboard_smbios_type16(unsigned long *current, int *handle)
+{
+ return 0;
+}
+
static int get_socket_type(void)
{
if (CONFIG(CPU_INTEL_SLOT_1))
@@ -938,6 +943,16 @@
return len;
}
+static int smbios_write_type16(unsigned long *current, int *handle)
+{
+ int len = fill_mainboard_smbios_type16(current, handle);
+ if(len){
+ *current += len;
+ (*handle)++;
+ }
+ return len;
+}
+
static int smbios_write_type17(unsigned long *current, int *handle)
{
int len = sizeof(struct smbios_type17);
@@ -1176,6 +1191,8 @@
if (CONFIG(ELOG))
update_max(len, max_struct_size,
elog_smbios_write_type15(¤t,handle++));
+ update_max(len, max_struct_size, smbios_write_type16(¤t,
+ &handle));
update_max(len, max_struct_size, smbios_write_type17(¤t,
&handle));
update_max(len, max_struct_size, smbios_write_type32(¤t,
diff --git a/src/include/smbios.h b/src/include/smbios.h
index 0bba0a7..e808177 100644
--- a/src/include/smbios.h
+++ b/src/include/smbios.h
@@ -52,6 +52,7 @@
const char *smbios_system_version(void);
void smbios_system_set_uuid(u8 *uuid);
const char *smbios_system_sku(void);
+int fill_mainboard_smbios_type16(unsigned long *current, int *handle);
const char *smbios_mainboard_manufacturer(void);
const char *smbios_mainboard_product_name(void);
To view, visit change 35888. To unsubscribe, or for help writing mail filters, visit settings.