aboutsummaryrefslogtreecommitdiffstats
path: root/src/fw/smbios.c
Commit message (Collapse)AuthorAgeFilesLines
* smbios: Use integer signature instead of string signatureKevin O'Connor2015-04-101-1/+1
| | | | | | | | | | | | | Change the smbios structure to use a 4 byte u32 signature field instead of a 4 byte character string field. In practice, this allows the compiler to place the signature in the initialize code segment and thus makes it less likely the signature would be found in the f-segment. (If the smbios signature is found in the f-segment it can confuse some table scans.) Reviewed-by: Bruce Rogers <brogers@suse.com> Tested-by: Bruce Rogers <brogers@suse.com> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* SMBIOS: Check for aggregate tables & entry point in fw_cfgGabriel L. Somlo2014-05-061-1/+1
| | | | | | | | | | | | | | Check fw_cfg for the presence of an aggregate set of smbios tables (etc/smbios/smbios-tables) and an entry point structure (etc/smbios/smbios-anchor), and, if found, use them instead of generating entries locally. We ensure the presence of a type 0 (bios information) structure by generating it locally if necessary, which is expected to be the common case. Signed-off-by: Gabriel L. Somlo <somlo@cmu.edu> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* Document no new changes to pirtable.c, mptable.c, acpi.c, and smbios.c.Kevin O'Connor2014-04-071-0/+1
| | | | | | | | | Add a note to the code that generates the pir, mptable, smbios, and smbios tables that no new changes are expected. Going forward, it is expected that if any changes are needed to these bios tables that SeaBIOS will get the tables passed in from upstream. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* Use biostables.c for copying bios tables even when generating them.Kevin O'Connor2014-04-071-21/+16
| | | | | | | | | Use the biostables.c copy_pir(), copy_smbios(), copy_acpi_rsdp(), and copy_mptable() code even when using the legacy bios table generation code. This unifies the final bios table deployment code between qemu, coreboot, and csm. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* smbios: Move smbios parsing logic from smbios.c to biostables.c.Kevin O'Connor2014-04-071-70/+0
| | | | | | | | After this change, src/fw/smbios.c only contains the legacy code for generating SMBIOS tables. This change only contains code movement - no logic is changed. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* smbios: Default all values to zero.Kevin O'Connor2014-03-201-0/+1
| | | | | | | | | Make sure to initialize the entire smbios area to zero so that any field not explicitly initialized does not have random values. (It was found that the memory_error_information_handle field in smbios_type_17 was not being set.) Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* smbios: catch zero-length stringsGerd Hoffmann2014-01-221-3/+7
| | | | | | | | | | | | | | | | | | | qemu may pass us zero-length strings for smbios fields, when starting qemu this way ... qemu -smbios type=1,version=,serial=test ... for example. Today we don't specifically handle them and simply append them to the string list. Therefore we get two string-terminating zeros in a row. Result is that we by accident create a end-of-entry marker in the middle of the entry. Fix this by handling zero-length strings like non-present strings. Cc: armbru@redhat.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* Move fw/smbios.h to std/smbios.h.Kevin O'Connor2013-09-181-1/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* Move function definitions for output.c from util.h to new file output.h.Kevin O'Connor2013-09-181-3/+4
| | | | | | Also, sort the order of include files in the c files. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* Move malloc code from pmm.c to new files malloc.c and malloc.h.Kevin O'Connor2013-09-181-0/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* Move romfile definitions from util.h to new file romfile.h.Kevin O'Connor2013-09-181-0/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* Rename util.c to string.c and introduce string.h.Kevin O'Connor2013-09-181-0/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* Split x86 specific functions out of util.c/h to new files x86.c/h.Kevin O'Connor2013-09-181-0/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* Move code cenetered around firmware initialization to src/fw/Kevin O'Connor2013-09-021-0/+649
Move many C files from the src/ directory to the new src/fw/ directory. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>