[smbios] Expose board serial number as ${board-serial}

With blade servers, the chassis serial number (exposed via ${serial})
may not be unique.  Expose ${board-serial} as a named setting to
provide easy access to a more meaningful serial number.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Dale Hamel
2014-03-10 18:48:37 -04:00
committed by Michael Brown
parent bb5a4a111b
commit 7fe0735170
2 changed files with 29 additions and 0 deletions

View File

@@ -241,3 +241,15 @@ const struct setting asset_setting __setting ( SETTING_HOST_EXTRA, asset ) = {
.type = &setting_type_string,
.scope = &smbios_settings_scope,
};
/** Board serial number setting (may differ from chassis serial number) */
const struct setting board_serial_setting __setting ( SETTING_HOST_EXTRA,
board_serial ) = {
.name = "board-serial",
.description = "Base board serial",
.tag = SMBIOS_STRING_TAG ( SMBIOS_TYPE_BASE_BOARD_INFORMATION,
struct smbios_base_board_information,
serial ),
.type = &setting_type_string,
.scope = &smbios_settings_scope,
};