From: Liming Gao Date: Wed, 3 Feb 2016 14:00:20 +0000 (+0800) Subject: MdeModulePkg: Update DxeCore dispatcher to ignore PEI and SMM depex for FV. X-Git-Tag: edk2-stable201903~7893 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=c74a25f0a29b50f938263c41d990e5a9e099982e MdeModulePkg: Update DxeCore dispatcher to ignore PEI and SMM depex for FV. If FV image without DXE depex, it will be dispatched by DxeCore. If FV image with SMM depex, it is the invalid image. ASSERT will be trig. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Liming Gao Reviewed-by: Andrew Fish Reviewed-by: Michael Kinney --- diff --git a/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c b/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c index 0776cd6d24..69c3b11c6a 100644 --- a/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c +++ b/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c @@ -26,7 +26,7 @@ Depex - Dependency Expresion. SOR - Schedule On Request - Don't schedule if this bit is set. -Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at @@ -1248,29 +1248,6 @@ CoreFwVolEventProtocolNotify ( continue; } - // - // Check if this EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE file has PEI depex section. - // - DepexBuffer = NULL; - SizeOfBuffer = 0; - Status = Fv->ReadSection ( - Fv, - &NameGuid, - EFI_SECTION_PEI_DEPEX, - 0, - &DepexBuffer, - &SizeOfBuffer, - &AuthenticationStatus - ); - if (!EFI_ERROR (Status)) { - // - // If PEI depex section is found, this FV image will be ignored in DXE phase. - // Now, DxeCore doesn't support FV image with more one type DEPEX section. - // - FreePool (DepexBuffer); - continue; - } - // // Check if this EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE file has SMM depex section. // @@ -1287,11 +1264,11 @@ CoreFwVolEventProtocolNotify ( ); if (!EFI_ERROR (Status)) { // - // If SMM depex section is found, this FV image will be ignored in DXE phase. - // Now, DxeCore doesn't support FV image with more one type DEPEX section. + // If SMM depex section is found, this FV image is invalid to be supported. + // ASSERT FALSE to report this FV image. // FreePool (DepexBuffer); - continue; + ASSERT (FALSE); } //