MdeModulePkg: StatusCodeHandler: StatusCodeHandler driver in StandaloneMm

This change added support of StandaloneMm for StatusCodeHandler. It
adds a new instance of StatusCodeHandler of MM_STANDALONE type, and
abstracts the driver entrypoint into separate files, replaced gSmst with
gMmst, and switched to MM version of RscHandlerProtocol.

Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Hao A Wu <hao.a.wu@intel.com>
Cc: Dandan Bi <dandan.bi@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Jiewen Yao <jiewen.yao@intel.com>

Signed-off-by: Kun Qin <kun.q@outlook.com>
Reviewed-by: Hao A Wu <hao.a.wu@intel.com>
This commit is contained in:
Kun Qin
2020-12-31 01:56:51 -08:00
parent 5625c1fdf7
commit 8a09cdd7be
9 changed files with 180 additions and 45 deletions

View File

@@ -1,5 +1,5 @@
## @file
# Status Code Handler Driver which produces general handlers and hook them onto the SMM status code router.
# Status Code Handler Driver which produces general handlers and hook them onto the MM status code router.
#
# Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>
# (C) Copyright 2016 Hewlett Packard Enterprise Development LP<BR>
@@ -17,7 +17,7 @@
MODULE_TYPE = DXE_SMM_DRIVER
PI_SPECIFICATION_VERSION = 0x0001000A
VERSION_STRING = 1.0
ENTRY_POINT = StatusCodeHandlerSmmEntry
ENTRY_POINT = StatusCodeHandlerTraditionalMmEntry
#
# The following information is for reference only and not required by the build tools.
@@ -26,8 +26,9 @@
#
[Sources]
StatusCodeHandlerSmm.c
StatusCodeHandlerSmm.h
StatusCodeHandlerMm.c
StatusCodeHandlerMm.h
StatusCodeHandlerTraditional.c
SerialStatusCodeWorker.c
MemoryStatusCodeWorker.c
@@ -37,7 +38,7 @@
[LibraryClasses]
SerialPortLib
SmmServicesTableLib
MmServicesTableLib
UefiDriverEntryPoint
PcdLib
PrintLib
@@ -51,7 +52,7 @@
gMemoryStatusCodeRecordGuid ## SOMETIMES_PRODUCES ## UNDEFINED # SmmSystemTable
[Protocols]
gEfiSmmRscHandlerProtocolGuid ## CONSUMES
gEfiMmRscHandlerProtocolGuid ## CONSUMES
[Pcd]
gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeUseSerial ## CONSUMES
@@ -59,7 +60,7 @@
gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeMemorySize |128| gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeUseMemory ## SOMETIMES_CONSUMES
[Depex]
gEfiSmmRscHandlerProtocolGuid
gEfiMmRscHandlerProtocolGuid
[UserExtensions.TianoCore."ExtraFiles"]
StatusCodeHandlerSmmExtra.uni