projects
/
coreboot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
libpayload: Put coreboot version into lib_sysinfo
[coreboot.git]
/
payloads
/
libpayload
/
arch
/
i386
/
coreboot.c
diff --git
a/payloads/libpayload/arch/i386/coreboot.c
b/payloads/libpayload/arch/i386/coreboot.c
index bdef4e85d3de9866651233e99d26e05cb5893d7b..365445ed651b3b9701adf2b6d5eb5f5423d8c9cc 100644
(file)
--- a/
payloads/libpayload/arch/i386/coreboot.c
+++ b/
payloads/libpayload/arch/i386/coreboot.c
@@
-82,6
+82,12
@@
static void cb_parse_serial(unsigned char *ptr, struct sysinfo_t *info)
info->ser_ioport = ser->baseaddr;
}
info->ser_ioport = ser->baseaddr;
}
+static void cb_parse_version(unsigned char *ptr, struct sysinfo_t *info)
+{
+ struct cb_string *ver = (struct cb_string *)ptr;
+ info->cb_version = (char *)ver->string;
+}
+
#ifdef CONFIG_NVRAM
static void cb_parse_optiontable(unsigned char *ptr, struct sysinfo_t *info)
{
#ifdef CONFIG_NVRAM
static void cb_parse_optiontable(unsigned char *ptr, struct sysinfo_t *info)
{
@@
-148,6
+154,9
@@
static int cb_parse_header(void *addr, int len, struct sysinfo_t *info)
case CB_TAG_SERIAL:
cb_parse_serial(ptr, info);
break;
case CB_TAG_SERIAL:
cb_parse_serial(ptr, info);
break;
+ case CB_TAG_VERSION:
+ cb_parse_version(ptr, info);
+ break;
#ifdef CONFIG_NVRAM
case CB_TAG_CMOS_OPTION_TABLE:
cb_parse_optiontable(ptr, info);
#ifdef CONFIG_NVRAM
case CB_TAG_CMOS_OPTION_TABLE:
cb_parse_optiontable(ptr, info);