summaryrefslogtreecommitdiff
path: root/MdeModulePkg/Library
diff options
context:
space:
mode:
authorlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2009-02-24 07:53:20 +0000
committerlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2009-02-24 07:53:20 +0000
commit76f1dde2c43e02a78af3d09aea48fa316d283a62 (patch)
treed153c6009a908ed5e626e5cd919ba7215cdf8545 /MdeModulePkg/Library
parent0a6f71704a8a3376ead7dc18b00a86a248181f4e (diff)
downloadedk2-platforms-76f1dde2c43e02a78af3d09aea48fa316d283a62.tar.xz
Move Crc32GuidedSectionExtraction from Protocol to Guid directory
Move DiskInfo protocol from MdeModulePkg to IntelFrameworkModulePkg Retire unused FvbExtension protocol. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7638 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg/Library')
-rw-r--r--MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.c8
-rw-r--r--MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.inf4
-rw-r--r--MdeModulePkg/Library/EdkFvbServiceLib/EdkFvbServiceLib.inf1
-rw-r--r--MdeModulePkg/Library/EdkFvbServiceLib/Fvb.c71
-rw-r--r--MdeModulePkg/Library/EdkFvbServiceLib/Fvb.h2
5 files changed, 7 insertions, 79 deletions
diff --git a/MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.c b/MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.c
index b87af37a91..398adfcac1 100644
--- a/MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.c
+++ b/MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.c
@@ -16,7 +16,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
#include <PiDxe.h>
-#include <Protocol/Crc32GuidedSectionExtraction.h>
+#include <Guid/Crc32GuidedSectionExtraction.h>
#include <Protocol/SecurityPolicy.h>
#include <Library/ExtractGuidedSectionLib.h>
#include <Library/DebugLib.h>
@@ -62,7 +62,7 @@ Crc32GuidedSectionGetInfo (
// Check whether the input guid section is recognized.
//
if (!CompareGuid (
- &gEfiCrc32GuidedSectionExtractionProtocolGuid,
+ &gEfiCrc32GuidedSectionExtractionGuid,
&(((EFI_GUID_DEFINED_SECTION *) InputSection)->SectionDefinitionGuid))) {
return EFI_INVALID_PARAMETER;
}
@@ -113,7 +113,7 @@ Crc32GuidedSectionHandler (
// Check whether the input guid section is recognized.
//
if (!CompareGuid (
- &gEfiCrc32GuidedSectionExtractionProtocolGuid,
+ &gEfiCrc32GuidedSectionExtractionGuid,
&(((EFI_GUID_DEFINED_SECTION *) InputSection)->SectionDefinitionGuid))) {
return EFI_INVALID_PARAMETER;
}
@@ -185,7 +185,7 @@ DxeCrc32GuidedSectionExtractLibConstructor (
)
{
return ExtractGuidedSectionRegisterHandlers (
- &gEfiCrc32GuidedSectionExtractionProtocolGuid,
+ &gEfiCrc32GuidedSectionExtractionGuid,
Crc32GuidedSectionGetInfo,
Crc32GuidedSectionHandler
);
diff --git a/MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.inf b/MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.inf
index 8a977003dc..094378fb82 100644
--- a/MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.inf
+++ b/MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.inf
@@ -44,7 +44,9 @@
DebugLib
BaseMemoryLib
+[Guids]
+ gEfiCrc32GuidedSectionExtractionGuid ## CONSUMES ## GUID
+
[Protocols]
- gEfiCrc32GuidedSectionExtractionProtocolGuid ## PRODUCED
gEfiSecurityPolicyProtocolGuid ## SOMETIMES_CONSUMED (Set platform override AUTH status if exist)
\ No newline at end of file
diff --git a/MdeModulePkg/Library/EdkFvbServiceLib/EdkFvbServiceLib.inf b/MdeModulePkg/Library/EdkFvbServiceLib/EdkFvbServiceLib.inf
index b28d2afb24..eb77a43fe3 100644
--- a/MdeModulePkg/Library/EdkFvbServiceLib/EdkFvbServiceLib.inf
+++ b/MdeModulePkg/Library/EdkFvbServiceLib/EdkFvbServiceLib.inf
@@ -51,7 +51,6 @@
[Protocols]
gEfiFirmwareVolumeBlockProtocolGuid ## NOTIFY
- gEfiFvbExtensionProtocolGuid ## CONSUMES
[Guids]
gEfiEventVirtualAddressChangeGuid ## PRODUCES
diff --git a/MdeModulePkg/Library/EdkFvbServiceLib/Fvb.c b/MdeModulePkg/Library/EdkFvbServiceLib/Fvb.c
index 44de6eeaa0..85f5e5a6d2 100644
--- a/MdeModulePkg/Library/EdkFvbServiceLib/Fvb.c
+++ b/MdeModulePkg/Library/EdkFvbServiceLib/Fvb.c
@@ -197,15 +197,6 @@ FvbNotificationEvent (
);
ASSERT_EFI_ERROR (Status);
- Status = gBS->HandleProtocol (
- Handle,
- &gEfiFvbExtensionProtocolGuid,
- (VOID **) &mFvbEntry[UpdateIndex].FvbExtension
- );
- if (Status != EFI_SUCCESS) {
- mFvbEntry[UpdateIndex].FvbExtension = NULL;
- }
-
//
// Check the FVB can be accessed in RUNTIME, The FVBs in FVB handle list come from two ways:
// 1) Dxe Core. (FVB information is transferred from FV HOB). 2) FVB driver. The FVB produced
@@ -251,11 +242,6 @@ FvbVirtualAddressChangeNotifyEvent (
EfiConvertPointer (0x0, (VOID **) &mFvbEntry[Index].Fvb->EraseBlocks);
EfiConvertPointer (0x0, (VOID **) &mFvbEntry[Index].Fvb);
}
-
- if (mFvbEntry[Index].FvbExtension != NULL) {
- EfiConvertPointer (0x0, (VOID **) &mFvbEntry[Index].FvbExtension->EraseFvbCustomBlock);
- EfiConvertPointer (0x0, (VOID **) &mFvbEntry[Index].FvbExtension);
- }
}
EfiConvertPointer (0x0, (VOID **) &mFvbEntry);
@@ -668,60 +654,3 @@ EfiFvbGetBlockSize (
return mFvbEntry[Instance].Fvb->GetBlockSize (mFvbEntry[Instance].Fvb, Lba, BlockSize, NumOfBlocks);
}
-
-
-/**
- Erases and initializes a specified range of a firmware volume.
-
- The EfiFvbEraseCustomBlockRange() function erases the specified range in the firmware
- volume index by Instance. If Instance is larger than the max FVB number, StartLba or
- LastLba index is larger than the last block of the firmware volume, StartLba > LastLba
- or StartLba equal to LastLba but OffsetStartLba > OffsetLastLba, this function return
- the status code EFI_INVALID_PARAMETER.
-
- @param[in] Instance The FV instance to be operated.
- @param[in] StartLba The starting logical block index to be erased.
- @param[in] OffsetStartLba Offset into the starting block at which to
- begin erasing.
- @param[in] LastLba The last logical block index to be erased.
- @param[in] OffsetLastLba Offset into the last block at which to end erasing.
-
- @retval EFI_EFI_SUCCESS Successfully erase custom block range
- @retval EFI_INVALID_PARAMETER Invalid parameter. Instance is larger than the max FVB number.
- @retval EFI_UNSUPPORTED Firmware volume block device has no this capability.
-
-**/
-EFI_STATUS
-EFIAPI
-EfiFvbEraseCustomBlockRange (
- IN UINTN Instance,
- IN EFI_LBA StartLba,
- IN UINTN OffsetStartLba,
- IN EFI_LBA LastLba,
- IN UINTN OffsetLastLba
- )
-{
- if (Instance >= mFvbCount) {
- return EFI_INVALID_PARAMETER;
- }
-
- if (EfiAtRuntime() && !mFvbEntry[Instance].IsRuntimeAccess) {
- return EFI_INVALID_PARAMETER;
- }
-
- if (mFvbEntry[Instance].FvbExtension == NULL) {
- return EFI_UNSUPPORTED;
- }
-
- if (mFvbEntry[Instance].FvbExtension->EraseFvbCustomBlock == NULL) {
- return EFI_UNSUPPORTED;
- }
-
- return mFvbEntry[Instance].FvbExtension->EraseFvbCustomBlock (
- mFvbEntry[Instance].FvbExtension,
- StartLba,
- OffsetStartLba,
- LastLba,
- OffsetLastLba
- );
-}
diff --git a/MdeModulePkg/Library/EdkFvbServiceLib/Fvb.h b/MdeModulePkg/Library/EdkFvbServiceLib/Fvb.h
index 1981e9682d..b12894b3c1 100644
--- a/MdeModulePkg/Library/EdkFvbServiceLib/Fvb.h
+++ b/MdeModulePkg/Library/EdkFvbServiceLib/Fvb.h
@@ -22,7 +22,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include <PiDxe.h>
#include <Protocol/FirmwareVolumeBlock.h>
-#include <Protocol/FvbExtension.h>
#include <Library/FvbServiceLib.h>
#include <Library/UefiLib.h>
@@ -40,7 +39,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
typedef struct {
EFI_HANDLE Handle;
EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL *Fvb;
- EFI_FVB_EXTENSION_PROTOCOL *FvbExtension;
BOOLEAN IsRuntimeAccess;
} FVB_ENTRY;