]> git.proxmox.com Git - mirror_edk2.git/blobdiff - OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FwBlockServiceSmm.c
UefiPayloadPkg: Fix build error
[mirror_edk2.git] / OvmfPkg / QemuFlashFvbServicesRuntimeDxe / FwBlockServiceSmm.c
index e77129e03b090dde84463523fbcc587c77bb4807..19bd5aab7c704dc8a21c12762eff10703978f423 100644 (file)
@@ -5,16 +5,11 @@
   Copyright (C) 2015, Red Hat, Inc.\r
   Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>\r
 \r
-  This program and the accompanying materials are licensed and made available\r
-  under the terms and conditions of the BSD License which accompanies this\r
-  distribution.  The full text of the license may be found at\r
-  http://opensource.org/licenses/bsd-license.php\r
-\r
-  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+  SPDX-License-Identifier: BSD-2-Clause-Patent\r
 **/\r
 \r
 #include <Library/DebugLib.h>\r
+#include <Library/PcdLib.h>\r
 #include <Library/SmmServicesTableLib.h>\r
 #include <Protocol/DevicePath.h>\r
 #include <Protocol/SmmFirmwareVolumeBlock.h>\r
 \r
 VOID\r
 InstallProtocolInterfaces (\r
-  IN EFI_FW_VOL_BLOCK_DEVICE *FvbDevice\r
+  IN EFI_FW_VOL_BLOCK_DEVICE  *FvbDevice\r
   )\r
 {\r
-  EFI_HANDLE FvbHandle;\r
-  EFI_STATUS Status;\r
+  EFI_HANDLE  FvbHandle;\r
+  EFI_STATUS  Status;\r
+\r
+  ASSERT (FeaturePcdGet (PcdSmmSmramRequire));\r
 \r
   //\r
   // There is no SMM service that can install multiple protocols in the SMM\r
@@ -37,7 +34,7 @@ InstallProtocolInterfaces (
   // Firmware Volume Block protocol structure.\r
   //\r
   FvbHandle = NULL;\r
-  DEBUG ((EFI_D_INFO, "Installing QEMU flash SMM FVB\n"));\r
+  DEBUG ((DEBUG_INFO, "Installing QEMU flash SMM FVB\n"));\r
   Status = gSmst->SmmInstallProtocolInterface (\r
                     &FvbHandle,\r
                     &gEfiSmmFirmwareVolumeBlockProtocolGuid,\r
@@ -64,3 +61,26 @@ InstallVirtualAddressChangeHandler (
   // Nothing.\r
   //\r
 }\r
+\r
+EFI_STATUS\r
+MarkIoMemoryRangeForRuntimeAccess (\r
+  IN EFI_PHYSICAL_ADDRESS  BaseAddress,\r
+  IN UINTN                 Length\r
+  )\r
+{\r
+  //\r
+  // Nothing\r
+  //\r
+\r
+  return EFI_SUCCESS;\r
+}\r
+\r
+VOID\r
+SetPcdFlashNvStorageBaseAddresses (\r
+  VOID\r
+  )\r
+{\r
+  //\r
+  // Do nothing.\r
+  //\r
+}\r