[edk2-devel] [PATCH v1 06/16] ArmPlatformPkg: Fix Ecc error 5007 in PL061GpioDxe

PierreGondois pierre.gondois at arm.com
Thu Dec 3 18:19:35 UTC 2020


From: Pierre Gondois <Pierre.Gondois at arm.com>

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 <Pierre.Gondois at arm.com>
---
 The changes can be seen at: https://github.com/PierreARM/edk2-platforms/tree/1537_Ecc_ArmPlatformPkg_v1

 ArmPlatformPkg/Drivers/PL061GpioDxe/PL061Gpio.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061Gpio.c b/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061Gpio.c
index 020d8c9fd92a38783305680980cc9159345e380e..be0e1c096360d08d9da6888d77dd0e4556fd4b02 100644
--- a/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061Gpio.c
+++ b/ArmPlatformPkg/Drivers/PL061GpioDxe/PL061Gpio.c
@@ -171,7 +171,7 @@ Get (
   OUT UINTN             *Value
   )
 {
-  EFI_STATUS    Status = EFI_SUCCESS;
+  EFI_STATUS    Status;
   UINTN         Index, Offset, RegisterBase;

   Status = PL061Locate (Gpio, &Index, &Offset, &RegisterBase);
@@ -216,7 +216,7 @@ Set (
   IN  EMBEDDED_GPIO_MODE  Mode
   )
 {
-  EFI_STATUS    Status = EFI_SUCCESS;
+  EFI_STATUS    Status;
   UINTN         Index, Offset, RegisterBase;

   Status = PL061Locate (Gpio, &Index, &Offset, &RegisterBase);
@@ -278,7 +278,7 @@ GetMode (
   OUT EMBEDDED_GPIO_MODE  *Mode
   )
 {
-  EFI_STATUS    Status = EFI_SUCCESS;
+  EFI_STATUS    Status;
   UINTN         Index, Offset, RegisterBase;

   Status = PL061Locate (Gpio, &Index, &Offset, &RegisterBase);
--
2.17.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#68269): https://edk2.groups.io/g/devel/message/68269
Mute This Topic: https://groups.io/mt/78690952/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-





More information about the edk2-devel-archive mailing list