summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuoMinJ <newexplorerj@gmail.com>2020-02-13 16:33:46 +0800
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2020-02-14 07:27:28 +0000
commit466b877f43b66d783f84efa691a602fc6c905356 (patch)
treec556ba029cbf1d4e34921f7c7aee4ad958f12a6f
parent5b45b44e6f303dd421110a109ff5cfc2ae8f7555 (diff)
downloadedk2-466b877f43b66d783f84efa691a602fc6c905356.tar.gz
edk2-466b877f43b66d783f84efa691a602fc6c905356.tar.bz2
edk2-466b877f43b66d783f84efa691a602fc6c905356.zip
FmpDevicePkg/FmpDxe: Issues reported by ECC in EDK2.
https://bugzilla.tianocore.org/show_bug.cgi?id=2515 Change the FmpDevicePkg to match the ECC check rule Signed-off-by: GuoMinJ <newexplorerj@gmail.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
-rw-r--r--FmpDevicePkg/FmpDxe/Dependency.c4
-rw-r--r--FmpDevicePkg/FmpDxe/Dependency.h2
-rw-r--r--FmpDevicePkg/FmpDxe/FmpDxe.c2
3 files changed, 4 insertions, 4 deletions
diff --git a/FmpDevicePkg/FmpDxe/Dependency.c b/FmpDevicePkg/FmpDxe/Dependency.c
index b63a36b989..8f97c42916 100644
--- a/FmpDevicePkg/FmpDxe/Dependency.c
+++ b/FmpDevicePkg/FmpDxe/Dependency.c
@@ -163,8 +163,8 @@ Push (
/**
Pop an element from the stack.
- @param[in] Value Element to pop.
- @param[in] Type Type of element.
+ @param[out] Element Element to pop.
+ @param[in] Type Type of element.
@retval EFI_SUCCESS The value was popped onto the stack.
@retval EFI_ACCESS_DENIED The pop operation underflowed the stack.
diff --git a/FmpDevicePkg/FmpDxe/Dependency.h b/FmpDevicePkg/FmpDxe/Dependency.h
index a2aaaceeae..badd2542d6 100644
--- a/FmpDevicePkg/FmpDxe/Dependency.h
+++ b/FmpDevicePkg/FmpDxe/Dependency.h
@@ -56,7 +56,7 @@ EvaluateImageDependencies (
IN CONST EFI_GUID ImageTypeId,
IN CONST UINT32 Version,
IN CONST EFI_FIRMWARE_IMAGE_DEP *Dependencies,
- IN CONST UINT32 DependenciesSize,
+ IN CONST UINT32 DepexSize,
OUT BOOLEAN *IsSatisfied
);
diff --git a/FmpDevicePkg/FmpDxe/FmpDxe.c b/FmpDevicePkg/FmpDxe/FmpDxe.c
index aa92331966..5b523291e4 100644
--- a/FmpDevicePkg/FmpDxe/FmpDxe.c
+++ b/FmpDevicePkg/FmpDxe/FmpDxe.c
@@ -413,7 +413,7 @@ PopulateDescriptor (
}
if (!EFI_ERROR (Status) && Image != NULL) {
IsDepexValid = ValidateImageDepex ((EFI_FIRMWARE_IMAGE_DEP *) Image, ImageSize, &DepexSize);
- if (IsDepexValid == TRUE) {
+ if (IsDepexValid) {
Private->Descriptor.Dependencies = AllocatePool (DepexSize);
if (Private->Descriptor.Dependencies != NULL) {
CopyMem (Private->Descriptor.Dependencies->Dependencies, Image, DepexSize);