2 Functions related to the Firmware Volume Block service whose
3 implementation is specific to the SMM driver build.
5 Copyright (C) 2015, Red Hat, Inc.
6 Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
8 This program and the accompanying materials are licensed and made available
9 under the terms and conditions of the BSD License which accompanies this
10 distribution. The full text of the license may be found at
11 http://opensource.org/licenses/bsd-license.php
13 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
14 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
17 #include <Library/DebugLib.h>
18 #include <Library/SmmServicesTableLib.h>
19 #include <Protocol/DevicePath.h>
20 #include <Protocol/SmmFirmwareVolumeBlock.h>
22 #include "FwBlockService.h"
25 InstallProtocolInterfaces (
26 IN EFI_FW_VOL_BLOCK_DEVICE
*FvbDevice
33 // There is no SMM service that can install multiple protocols in the SMM
34 // protocol database in one go.
36 // The SMM Firmware Volume Block protocol structure is the same as the
37 // Firmware Volume Block protocol structure.
40 DEBUG ((EFI_D_INFO
, "Installing QEMU flash SMM FVB\n"));
41 Status
= gSmst
->SmmInstallProtocolInterface (
43 &gEfiSmmFirmwareVolumeBlockProtocolGuid
,
45 &FvbDevice
->FwVolBlockInstance
47 ASSERT_EFI_ERROR (Status
);
49 Status
= gSmst
->SmmInstallProtocolInterface (
51 &gEfiDevicePathProtocolGuid
,
55 ASSERT_EFI_ERROR (Status
);
59 InstallVirtualAddressChangeHandler (