mirror of https://github.com/acidanthera/audk.git
MdeModulePkg/VarCheckUefiLib: permit use by MM_STANDALONE modules
Permit CheckUefiLib to be used by MM_STANDALONE modules. Since this library has a constructor, change the library's module type into BASE so its constructor prototype is compatible with MM_STANDALONE as well. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Jian J Wang <jian.j.wang@intel.com> Reviewed-by: Star Zeng <star.zeng@intel.com>
This commit is contained in:
parent
c5386c7898
commit
070c5a66cd
|
@ -19,9 +19,9 @@
|
|||
BASE_NAME = VarCheckUefiLib
|
||||
MODULE_UNI_FILE = VarCheckUefiLib.uni
|
||||
FILE_GUID = AC24A4C7-F845-4665-90E5-6431D6E28DC0
|
||||
MODULE_TYPE = DXE_RUNTIME_DRIVER
|
||||
MODULE_TYPE = BASE
|
||||
VERSION_STRING = 1.0
|
||||
LIBRARY_CLASS = NULL|DXE_RUNTIME_DRIVER DXE_SMM_DRIVER
|
||||
LIBRARY_CLASS = NULL|DXE_RUNTIME_DRIVER DXE_SMM_DRIVER MM_STANDALONE
|
||||
CONSTRUCTOR = VarCheckUefiLibNullClassConstructor
|
||||
|
||||
#
|
||||
|
|
|
@ -12,6 +12,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
|||
|
||||
**/
|
||||
|
||||
#include <Uefi/UefiBaseType.h>
|
||||
|
||||
#include <Library/VarCheckLib.h>
|
||||
#include <Library/BaseLib.h>
|
||||
#include <Library/BaseMemoryLib.h>
|
||||
|
@ -921,21 +923,17 @@ VariablePropertySetUefiDefined (
|
|||
Constructor function of VarCheckUefiLib to set property and
|
||||
register SetVariable check handler for UEFI defined variables.
|
||||
|
||||
@param[in] ImageHandle The firmware allocated handle for the EFI image.
|
||||
@param[in] SystemTable A pointer to the EFI System Table.
|
||||
|
||||
@retval EFI_SUCCESS The constructor executed correctly.
|
||||
|
||||
**/
|
||||
EFI_STATUS
|
||||
RETURN_STATUS
|
||||
EFIAPI
|
||||
VarCheckUefiLibNullClassConstructor (
|
||||
IN EFI_HANDLE ImageHandle,
|
||||
IN EFI_SYSTEM_TABLE *SystemTable
|
||||
VOID
|
||||
)
|
||||
{
|
||||
VariablePropertySetUefiDefined ();
|
||||
VarCheckLibRegisterSetVariableCheckHandler (SetVariableCheckHandlerUefiDefined);
|
||||
|
||||
return EFI_SUCCESS;
|
||||
return RETURN_SUCCESS;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue