From c26e291375d1808a0ec5af9002dd0ebca5959020 Mon Sep 17 00:00:00 2001 From: Siyuan Fu Date: Wed, 28 Oct 2020 10:57:01 +0800 Subject: MdeModulePkg/Core: Support standalone MM in FV2 protocol GetNextFile(). REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3028 The FirmwareVolume2Protocol->GetNextFile() produced by DXE Core can be used to search for a file based on the value of *FileType input. However, this service will always return EFI_NOT_FOUND if the input FileType is set to EFI_FV_FILETYPE_MM_STANDALONE or EFI_FV_FILETYPE_MM_CORE_STANDALONE, Which means user can't use this service to search any standalone MM image in that FV. This patch update the FirmwareVolume2Protocol->GetNextFile() service to support searching standalone MM module. Signed-off-by: Siyuan Fu Cc: Dandan Bi Cc: Liming Gao Reviewed-by: Liming Gao --- MdeModulePkg/Core/Dxe/FwVol/FwVolRead.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'MdeModulePkg') diff --git a/MdeModulePkg/Core/Dxe/FwVol/FwVolRead.c b/MdeModulePkg/Core/Dxe/FwVol/FwVolRead.c index 2861cbf676..8dcbbeb5ee 100644 --- a/MdeModulePkg/Core/Dxe/FwVol/FwVolRead.c +++ b/MdeModulePkg/Core/Dxe/FwVol/FwVolRead.c @@ -1,7 +1,7 @@ /** @file Implements functions to read firmware file -Copyright (c) 2006 - 2017, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2020, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent **/ @@ -143,9 +143,9 @@ FvGetNextFile ( return EFI_ACCESS_DENIED; } - if (*FileType > EFI_FV_FILETYPE_SMM_CORE) { + if (*FileType > EFI_FV_FILETYPE_MM_CORE_STANDALONE) { // - // File type needs to be in 0 - 0x0D + // File type needs to be in 0 - 0x0F // return EFI_NOT_FOUND; } -- cgit v1.2.3