From 146af6a45b4eb5c0a0dcd1239a7b28599a79db5c Mon Sep 17 00:00:00 2001 From: Pierre Gondois Date: Thu, 10 Dec 2020 13:12:36 +0000 Subject: ArmPkg: Fix Ecc error 5007 in ArmMmuLib This patch fixes the following Ecc reported error: There should be no initialization of a variable as part of its declaration Signed-off-by: Pierre Gondois Reviewed-by: Ard Biesheuvel --- ArmPkg/Library/ArmMmuLib/Arm/ArmMmuLibUpdate.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'ArmPkg/Library/ArmMmuLib/Arm/ArmMmuLibUpdate.c') diff --git a/ArmPkg/Library/ArmMmuLib/Arm/ArmMmuLibUpdate.c b/ArmPkg/Library/ArmMmuLib/Arm/ArmMmuLibUpdate.c index 34ba691d9d..940e4bc797 100644 --- a/ArmPkg/Library/ArmMmuLib/Arm/ArmMmuLibUpdate.c +++ b/ArmPkg/Library/ArmMmuLib/Arm/ArmMmuLibUpdate.c @@ -220,7 +220,7 @@ UpdateSectionEntries ( IN UINT64 Attributes ) { - EFI_STATUS Status = EFI_SUCCESS; + EFI_STATUS Status; UINT32 EntryMask; UINT32 EntryValue; UINT32 FirstLevelIdx; @@ -231,6 +231,8 @@ UpdateSectionEntries ( VOID *Mva; volatile ARM_FIRST_LEVEL_DESCRIPTOR *FirstLevelTable; + Status = EFI_SUCCESS; + // EntryMask: bitmask of values to change (1 = change this value, 0 = leave alone) // EntryValue: values at bit positions specified by EntryMask -- cgit v1.2.3