From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by mx.groups.io with SMTP id smtpd.web10.35626.1629783282704645527 for ; Mon, 23 Aug 2021 22:34:43 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: arm.com, ip: 217.140.110.172, mailfrom: omkar.kulkarni@arm.com) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 754281042; Mon, 23 Aug 2021 22:34:41 -0700 (PDT) Received: from usa.arm.com (a077433.blr.arm.com [10.162.46.10]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 3DB2F3F766; Mon, 23 Aug 2021 22:34:40 -0700 (PDT) From: "Omkar Anand Kulkarni" To: devel@edk2.groups.io Cc: Ard Biesheuvel , Sami Mujawar Subject: [edk2-platforms][PATCH v3 0/5] Add support to generate HEST ACPI table Date: Tue, 24 Aug 2021 11:03:58 +0530 Message-Id: <20210824053403.24103-1-omkar.kulkarni@arm.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Changes since v2: - Addressed the comments given by Sami. - Added Readme file with all cover letter information. - Rebased to the latest upstream code. Hardware Error Source Table (HEST)[1] and Software Delegated Exception In= terface (SDEI)[2] ACPI tables are used to acomplish firmware first error handling= .This patch series introduces a framework to build and install the HEST ACPI ta= ble dynamically. The following figure illustrates the possible usage of the dyanamic generation of HEST ACPI table. NS | S +--------------------------------------+---------------------------------= -----+ | | = | |+-------------------------------------+---------------------+ = | || +---------------------+--------------------+| = | || | | || = | || +-----------+ |+------------------+ | +-----------------+|| +---------= ----+| || |HestTable | || HestErrorSource | | | HestErrorSource ||| | DMC-620 = || || | DXE | || DXE | | | StandaloneMM ||| |Standalon= e MM|| || +-----------+ |+------------------+ | +-----------------+|| +---------= ----+| || |GHESv2 | || = | || +---------------------+--------------------+| = | || +--------------------+ | | = | || |PlatformErrorHandler| | | = | || | DXE | | | = | || +--------------------+ | | = | ||FF FWK | | = | |+-------------------------------------+---------------------+ = | | | = | +--------------------------------------+---------------------------------= -----+ | Figure: Firmware First Error Handling approach. All the hardware error sources are added to HEST table as GHESv2[3] error= source descriptors. The framework comprises of following DXE and MM drivers: - HestTableDxe: Builds HEST table header and allows appending error source descriptors = to the HEST table. Also provides protocol interface to install the built HEST = table. - HestErrorSourceDxe & HestErrorSourceStandaloneMM: These two drivers together retrieve all possible error source descripto= rs of type GHESv2 from the MM drivers implementing HEST Error Source Descript= or protocol. Once all the descriptors are collected HestErrorSourceDxe app= ends it to HEST table using HestTableDxe driver. Link to github branch with the patches in this series - https://github.com/omkkul01/edk2/tree/ras_firware_first_edk2-platforms_v3 Omkar Anand Kulkarni (5): MdeModulePkg: Allow dynamic generation of HEST ACPI table ArmPlatformPkg: add definition for MM_HEST_ERROR_SOURCE_DESC_PROTOCOL ArmPlatformPkg: retreive error source descriptors from MM EmbeddedPkg: Add helpers for HEST table generation ArmPlatformPkg: Add Readme file ArmPlatformPkg/ArmPlatformPkg.dec | 10 + MdeModulePkg/MdeModulePkg.dec | 3 + .../HestMmErrorSources/HestErrorSourceDxe.inf | 45 +++ .../HestErrorSourceStandaloneMm.inf | 51 +++ .../Universal/Apei/HestDxe/HestDxe.inf | 49 +++ .../HestMmErrorSourceCommon.h | 37 ++ .../Include/Protocol/HestErrorSourceInfo.h | 64 ++++ EmbeddedPkg/Include/Library/AcpiLib.h | 20 ++ MdeModulePkg/Include/Protocol/HestTable.h | 71 ++++ MdePkg/Include/Protocol/MmCommunication.h | 2 + .../HestMmErrorSources/HestErrorSourceDxe.c | 309 +++++++++++++++++ .../HestErrorSourceStandaloneMm.c | 312 +++++++++++++++++ MdeModulePkg/Universal/Apei/HestDxe/HestDxe.c | 318 ++++++++++++++++++ .../Drivers/HestMmErrorSources/Readme.md | 66 ++++ 14 files changed, 1357 insertions(+) create mode 100644 ArmPlatformPkg/Drivers/HestMmErrorSources/HestErrorSo= urceDxe.inf create mode 100644 ArmPlatformPkg/Drivers/HestMmErrorSources/HestErrorSo= urceStandaloneMm.inf create mode 100644 MdeModulePkg/Universal/Apei/HestDxe/HestDxe.inf create mode 100644 ArmPlatformPkg/Drivers/HestMmErrorSources/HestMmError= SourceCommon.h create mode 100644 ArmPlatformPkg/Include/Protocol/HestErrorSourceInfo.h create mode 100644 MdeModulePkg/Include/Protocol/HestTable.h create mode 100644 ArmPlatformPkg/Drivers/HestMmErrorSources/HestErrorSo= urceDxe.c create mode 100644 ArmPlatformPkg/Drivers/HestMmErrorSources/HestErrorSo= urceStandaloneMm.c create mode 100644 MdeModulePkg/Universal/Apei/HestDxe/HestDxe.c create mode 100644 ArmPlatformPkg/Drivers/HestMmErrorSources/Readme.md --=20 2.17.1