public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: Dandan Bi <dandan.bi@intel.com>
To: edk2-devel@lists.01.org
Cc: Alexei Fedorov <Alexei.Fedorov@arm.com>,
	Ruiyu Ni <ruiyu.ni@intel.com>,
	Jaben Carsey <jaben.carsey@intel.com>
Subject: [patch 4/4] ShellPkg/UefiShellAcpiViewCommandLib: Fix GCC build failure
Date: Mon, 30 Jul 2018 10:27:03 +0800	[thread overview]
Message-ID: <20180730022703.101708-5-dandan.bi@intel.com> (raw)
In-Reply-To: <20180730022703.101708-1-dandan.bi@intel.com>

Fix following GCC build issues:
1.
xxx/SratParser.c:127:47: error:
initialization from incompatible pointer type
[-Werror=incompatible-pointer-types]
{L"Proximity Domain [31:8]", 3, 9, L"0x%x", DumpSratApicProximity,
                                            ^
xxx/SratParser.c:127:47: note:
(near initialization for 'SratApciSapicAffinityParser[6].PrintFormatter')

2.
xxx\UefiShellAcpiViewCommandLib.c:66:14:
error: 'Status' may be used uninitialized in this fu
nction [-Werror=maybe-uninitialized]
   EFI_STATUS Status;
              ^

cc: Alexei Fedorov <Alexei.Fedorov@arm.com>
cc: Ruiyu Ni <ruiyu.ni@intel.com>
cc: Jaben Carsey <jaben.carsey@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Dandan Bi <dandan.bi@intel.com>
---
 ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Srat/SratParser.c  | 2 ++
 .../Library/UefiShellAcpiViewCommandLib/UefiShellAcpiViewCommandLib.c   | 1 +
 2 files changed, 3 insertions(+)

diff --git a/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Srat/SratParser.c b/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Srat/SratParser.c
index 043277aabf..e3f5567bec 100644
--- a/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Srat/SratParser.c
+++ b/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Srat/SratParser.c
@@ -46,10 +46,11 @@ ValidateSratReserved (
   @param [in] Format  Format string for tracing the data.
   @param [in] Ptr     Pointer to the start of the buffer.
 **/
 STATIC
 VOID
+EFIAPI
 DumpSratApicProximity (
   IN  CONST CHAR16*  Format,
   IN  UINT8*         Ptr
   );
 
@@ -170,10 +171,11 @@ ValidateSratReserved (
   @param [in] Format  Format string for tracing the data.
   @param [in] Ptr     Pointer to the start of the buffer.
 **/
 STATIC
 VOID
+EFIAPI
 DumpSratApicProximity (
  IN CONST CHAR16* Format,
  IN UINT8*        Ptr
  )
 {
diff --git a/ShellPkg/Library/UefiShellAcpiViewCommandLib/UefiShellAcpiViewCommandLib.c b/ShellPkg/Library/UefiShellAcpiViewCommandLib/UefiShellAcpiViewCommandLib.c
index c2f40009ee..245700a253 100644
--- a/ShellPkg/Library/UefiShellAcpiViewCommandLib/UefiShellAcpiViewCommandLib.c
+++ b/ShellPkg/Library/UefiShellAcpiViewCommandLib/UefiShellAcpiViewCommandLib.c
@@ -64,10 +64,11 @@ RegisterAllParsers (
   )
 {
   EFI_STATUS Status;
   UINTN Count;
 
+  Status = EFI_SUCCESS;
   Count = sizeof (ParserList) / sizeof (ParserList[0]);
 
   while (Count-- != 0) {
     Status = RegisterParser (
                ParserList[Count].Signature,
-- 
2.14.3.windows.1



      parent reply	other threads:[~2018-07-30  2:27 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-30  2:26 [patch 0/4] ShellPkg/UefiShellAcpiViewCommandLib: Fix build issues Dandan Bi
2018-07-30  2:27 ` [patch 1/4] ShellPkg/UefiShellAcpiViewCommandLib: Fix VS2012 build failure Dandan Bi
2018-07-30 17:46   ` Carsey, Jaben
2018-07-30  2:27 ` [patch 2/4] " Dandan Bi
2018-07-30 17:46   ` Carsey, Jaben
2018-07-30  2:27 ` [patch 3/4] ShellPkg/UefiShellAcpiViewCommandLib: Fix VS " Dandan Bi
2018-07-30  8:27   ` Alexei Fedorov
2018-07-30  8:49     ` Bi, Dandan
2018-07-30  2:27 ` Dandan Bi [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180730022703.101708-5-dandan.bi@intel.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox