diff options
author | Bret Barkelew <brbarkel@microsoft.com> | 2018-11-06 18:34:49 +0000 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2024-07-27 23:28:50 +0000 |
commit | b7f963d570ec5e27bc04d546372c6fc47e4f3b17 (patch) | |
tree | 94ade69bb9790dac2f7c4f8f7d3855828ba45ac9 /FmpDevicePkg | |
parent | 52eb643d0785a19c7f1c107d390c7bb52a79789e (diff) | |
download | edk2-b7f963d570ec5e27bc04d546372c6fc47e4f3b17.tar.gz edk2-b7f963d570ec5e27bc04d546372c6fc47e4f3b17.tar.bz2 edk2-b7f963d570ec5e27bc04d546372c6fc47e4f3b17.zip |
FmpDevicePkg: Assert on PcdFmpDeviceImageTypeIdGuid Size Mismatch
This patch adds an assert to FmpDxe.c to catch a platform
misconfiguration of PcdFmpDeviceImageTypeIdGuid.
Signed-off-by: Oliver Smith-Denny <osde@linux.microsoft.com>
Diffstat (limited to 'FmpDevicePkg')
-rw-r--r-- | FmpDevicePkg/FmpDxe/FmpDxe.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/FmpDevicePkg/FmpDxe/FmpDxe.c b/FmpDevicePkg/FmpDxe/FmpDxe.c index 1e7ec4a09e..b04998ba04 100644 --- a/FmpDevicePkg/FmpDxe/FmpDxe.c +++ b/FmpDevicePkg/FmpDxe/FmpDxe.c @@ -181,7 +181,12 @@ GetImageTypeIdGuid ( if (ImageTypeIdGuidSize == sizeof (EFI_GUID)) {
FmpDeviceLibGuid = (EFI_GUID *)PcdGetPtr (PcdFmpDeviceImageTypeIdGuid);
} else {
- DEBUG ((DEBUG_WARN, "FmpDxe(%s): Fall back to ImageTypeIdGuid of gEfiCallerIdGuid\n", mImageIdName));
+ DEBUG ((
+ DEBUG_ERROR,
+ "FmpDxe(%s): Fall back to ImageTypeIdGuid of gEfiCallerIdGuid. FmpDxe error: misconfiguration\n",
+ mImageIdName
+ ));
+ ASSERT (FALSE);
FmpDeviceLibGuid = &gEfiCallerIdGuid;
}
}
|