TianoCore EDK2 master
Loading...
Searching...
No Matches
MiscBiosVendorFunction.c File Reference

Go to the source code of this file.

Data Structures

struct  MONTH_DESCRIPTION
 

Functions

UINT8 Base2ToByteWith64KUnit (IN UINTN Value)
 
VOID GetReleaseTime (OUT EFI_TIME *Time)
 
CHAR16 * GetBiosReleaseDate (VOID)
 
VOID SetBiosVersion (VOID)
 
 SMBIOS_MISC_TABLE_FUNCTION (MiscBiosVendor)
 

Variables

STATIC CONST MONTH_DESCRIPTION mMonthDescription []
 

Detailed Description

Copyright (c) 2022 - 2023, Ampere Computing LLC. All rights reserved.
Copyright (c) 2021, NUVIA Inc. All rights reserved.
Copyright (c) 2009, Intel Corporation. All rights reserved.
Copyright (c) 2015, Hisilicon Limited. All rights reserved.
Copyright (c) 2015, Linaro Limited. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file MiscBiosVendorFunction.c.

Function Documentation

◆ Base2ToByteWith64KUnit()

UINT8 Base2ToByteWith64KUnit ( IN UINTN  Value)

Field Filling Function. Transform an EFI_EXP_BASE2_DATA to a byte, with '64k' as the unit.

Parameters
ValuePointer to Base2_Data
Return values

Definition at line 55 of file MiscBiosVendorFunction.c.

◆ GetBiosReleaseDate()

CHAR16 * GetBiosReleaseDate ( VOID  )

Fetches the firmware ('BIOS') release date from the FirmwareVersionInfo HOB.

Returns
The release date as a UTF-16 string

Definition at line 101 of file MiscBiosVendorFunction.c.

◆ GetReleaseTime()

VOID GetReleaseTime ( OUT EFI_TIME Time)

Returns the date and time this file (and firmware) was built.

Parameters
[out]*TimePointer to the EFI_TIME structure to fill in.

Definition at line 72 of file MiscBiosVendorFunction.c.

◆ SetBiosVersion()

VOID SetBiosVersion ( VOID  )

Fetches the Firmware version string for SMBIOS type 0

This function first acquires the firmware version string from OemMiscLib; if it is invalid, PcdFirmwareVersionString is used as a fallback, and then sets it in SMBIOS type 0.

Definition at line 135 of file MiscBiosVendorFunction.c.

◆ SMBIOS_MISC_TABLE_FUNCTION()

SMBIOS_MISC_TABLE_FUNCTION ( MiscBiosVendor  )

This function makes boot time changes to the contents of the MiscBiosVendor (Type 0) record.

Parameters
RecordDataPointer to SMBIOS table with default values.
SmbiosSMBIOS protocol.
Return values
EFI_SUCCESSThe SMBIOS table was successfully added.
EFI_INVALID_PARAMETERInvalid parameter was found.
EFI_OUT_OF_RESOURCESFailed to allocate required memory.

Definition at line 182 of file MiscBiosVendorFunction.c.

Variable Documentation

◆ mMonthDescription

STATIC CONST MONTH_DESCRIPTION mMonthDescription[]
Initial value:
= {
{ "Jan", 1 },
{ "Feb", 2 },
{ "Mar", 3 },
{ "Apr", 4 },
{ "May", 5 },
{ "Jun", 6 },
{ "Jul", 7 },
{ "Aug", 8 },
{ "Sep", 9 },
{ "Oct", 10 },
{ "Nov", 11 },
{ "Dec", 12 },
{ "???", 1 },
}

Definition at line 29 of file MiscBiosVendorFunction.c.