summaryrefslogtreecommitdiff
path: root/FmpDevicePkg/FmpDxe/FmpDxe.h
diff options
context:
space:
mode:
authorMichael Kubacki <michael.kubacki@microsoft.com>2020-10-20 07:59:36 +0800
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2020-10-28 06:05:52 +0000
commit5550f4d33b64abc989ec6597ed6a19712b915c63 (patch)
tree5b2e078d32f8a78b037a8b399911d825f9f523b9 /FmpDevicePkg/FmpDxe/FmpDxe.h
parent2c1e9f1dc5efda0787d059cc1d5534a6c4409503 (diff)
downloadedk2-5550f4d33b64abc989ec6597ed6a19712b915c63.zip
edk2-5550f4d33b64abc989ec6597ed6a19712b915c63.tar.gz
edk2-5550f4d33b64abc989ec6597ed6a19712b915c63.tar.bz2
FmpDevicePkg/FmpDxe: Add check image path Last Attempt Status capability
CheckTheImage() is currently used to provide the CheckImage() implementation for the EFI_FIRMWARE_MANAGEMENT_PROTOCOL instance produced by FmpDxe in addition to being called internally in the SetImage() path. Since CheckTheImage() plays a major role in determining the validity of a given firmware image, an internal version of the function is introduced - CheckTheImageInternal() that is capable of returning a Last Attempt Status code to internal callers such as SetTheImage(). The CheckImage() API as defined in the UEFI Specification for EFI_FIRMWARE_MANAGEMENT_PROTOCOL is not impacted by this change. CheckTheImageInternal() contains unique Last Attempt Status codes during error paths in the function so it is easier to identify the issue with a particular image through the Last Attempt Status code value. Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Guomin Jiang <guomin.jiang@intel.com> Cc: Wei6 Xu <wei6.xu@intel.com> Signed-off-by: Michael Kubacki <michael.kubacki@microsoft.com> Acked-by: Liming Gao <gaoliming@byosoft.com.cn> Reviewed-by: Wei6 Xu <wei6.xu@intel.com> Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com>
Diffstat (limited to 'FmpDevicePkg/FmpDxe/FmpDxe.h')
-rw-r--r--FmpDevicePkg/FmpDxe/FmpDxe.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/FmpDevicePkg/FmpDxe/FmpDxe.h b/FmpDevicePkg/FmpDxe/FmpDxe.h
index 30754de..1177b18 100644
--- a/FmpDevicePkg/FmpDxe/FmpDxe.h
+++ b/FmpDevicePkg/FmpDxe/FmpDxe.h
@@ -3,7 +3,7 @@
image stored in a firmware device with platform and firmware device specific
information provided through PCDs and libraries.
- Copyright (c) 2016, Microsoft Corporation. All rights reserved.<BR>
+ Copyright (c) Microsoft Corporation.<BR>
Copyright (c) 2018 - 2019, Intel Corporation. All rights reserved.<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
@@ -36,6 +36,8 @@
#include <Protocol/VariableLock.h>
#include <Guid/SystemResourceTable.h>
#include <Guid/EventGroup.h>
+#include <LastAttemptStatus.h>
+#include <FmpLastAttemptStatus.h>
#define VERSION_STRING_NOT_SUPPORTED L"VERSION STRING NOT SUPPORTED"
#define VERSION_STRING_NOT_AVAILABLE L"VERSION STRING NOT AVAILABLE"