ArmPkg: only attempt buildin MmCommunicationDxe for AArch64
[mirror_edk2.git] / StandaloneMmPkg / Library / VariableMmDependency / VariableMmDependency.c
CommitLineData
326598e9
JU
1/** @file\r
2 Runtime DXE part corresponding to StanaloneMM variable module.\r
3\r
4This module installs variable arch protocol and variable write arch protocol\r
5to StandaloneMM runtime variable service.\r
6\r
7Copyright (c) 2019, ARM Ltd. All rights reserved.\r
8\r
86094561 9SPDX-License-Identifier: BSD-2-Clause-Patent\r
326598e9
JU
10\r
11**/\r
12\r
13#include <Library/DebugLib.h>\r
14#include <Library/UefiBootServicesTableLib.h>\r
15\r
16/**\r
17 The constructor function installs variable arch protocol and variable\r
18 write arch protocol to StandaloneMM runtime variable service\r
19\r
20 @param ImageHandle The firmware allocated handle for the EFI image.\r
21 @param SystemTable A pointer to the Management mode System Table.\r
22\r
23 @retval EFI_SUCCESS The constructor always returns EFI_SUCCESS.\r
24\r
25**/\r
26EFI_STATUS\r
27EFIAPI\r
28VariableMmDependencyLibConstructor (\r
29 IN EFI_HANDLE ImageHandle,\r
30 IN EFI_SYSTEM_TABLE *SystemTable\r
31 )\r
32{\r
33 EFI_STATUS Status;\r
34 EFI_HANDLE Handle;\r
35\r
36 Handle = NULL;\r
37 Status = gBS->InstallMultipleProtocolInterfaces (\r
38 &Handle,\r
39 &gEfiSmmVariableProtocolGuid,\r
40 NULL,\r
41 &gSmmVariableWriteGuid,\r
42 NULL,\r
43 NULL\r
44 );\r
45 ASSERT_EFI_ERROR (Status);\r
46 return EFI_SUCCESS;\r
47}\r