diff options
author | Christian Gmeiner <christian.gmeiner@gmail.com> | 2013-02-04 16:22:46 +0100 |
---|---|---|
committer | Marc Jones <marcj303@gmail.com> | 2013-02-04 18:23:32 +0100 |
commit | 5e272a4c4a8d9b00239d61da089e65fc4d6cfa8d (patch) | |
tree | 3da3812c5943037b3b8baf48bc7dd551c5437407 | |
parent | 7407f43c2b3273320ad8eadc5454d8f5375f2064 (diff) | |
download | coreboot-5e272a4c4a8d9b00239d61da089e65fc4d6cfa8d.tar.xz |
smbios: show CONFIG_LOCALVERSION in DMI bios_version
If somebody makes use of CONFIG_LOCALVERSION show this
user provided config string for DMI bios_version.
As requested I have attached example output.
CONFIG_LOCALVERSION=""
CONFIG_CBFS_PREFIX="fallback"
CONFIG_COMPILER_GCC=y
...
root@OT:~# cat /sys/class/dmi/id/bios_version
4.0-3360-g5be6673-dirty
CONFIG_LOCALVERSION="V1.01.02 Beta"
CONFIG_CBFS_PREFIX="fallback"
CONFIG_COMPILER_GCC=y
...
root@OT:~# cat /sys/class/dmi/id/bios_version
V1.01.02 Beta
Change-Id: I5640b72b56887ddf85113efa9ff23df9d4c7eb86
Signed-off-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Reviewed-on: http://review.coreboot.org/2279
Tested-by: build bot (Jenkins)
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: Marc Jones <marcj303@gmail.com>
-rw-r--r-- | src/arch/x86/boot/smbios.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/arch/x86/boot/smbios.c b/src/arch/x86/boot/smbios.c index f65ced2746..308336a5e8 100644 --- a/src/arch/x86/boot/smbios.c +++ b/src/arch/x86/boot/smbios.c @@ -131,7 +131,11 @@ static int smbios_write_type0(unsigned long *current, int handle) t->vendor = smbios_add_string(t->eos, "coreboot"); #if !CONFIG_CHROMEOS t->bios_release_date = smbios_add_string(t->eos, COREBOOT_DMI_DATE); - t->bios_version = smbios_add_string(t->eos, COREBOOT_VERSION); + + if (strlen(CONFIG_LOCALVERSION)) + t->bios_version = smbios_add_string(t->eos, CONFIG_LOCALVERSION); + else + t->bios_version = smbios_add_string(t->eos, COREBOOT_VERSION); #else #define SPACES \ " " |