From: Jeff Fan <jeff.fan@intel.com>
To: edk2-devel@lists.01.org
Cc: Laszlo Ersek <lersek@redhat.com>, Andrew Fish <afish@apple.com>,
Feng Tian <feng.tian@intel.com>,
Michael D Kinney <michael.d.kinney@intel.com>
Subject: [PATCH v2] UefiCpuPkg/SecCore: Correct print format for stack information
Date: Wed, 16 Nov 2016 15:55:06 +0800 [thread overview]
Message-ID: <20161116075506.9008-1-jeff.fan@intel.com> (raw)
v2:
Per Laszlo and Andrew's comments at
https://lists.01.org/pipermail/edk2-devel/2016-November/004759.html
SecCoreData->StackBase is VOID * type. We should use %p to dump VOID * type.
SecCoreData->StackSize is UINTN type, but %x only could print unsinged-int
type. We will cast it to UINT32 firstly and then use %x to print it.
Cc: Laszlo Ersek <lersek@redhat.com>
Cc: Andrew Fish <afish@apple.com>
Cc: Feng Tian <feng.tian@intel.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>
---
UefiCpuPkg/SecCore/SecMain.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/UefiCpuPkg/SecCore/SecMain.c b/UefiCpuPkg/SecCore/SecMain.c
index 2ebbc22..077d0db 100644
--- a/UefiCpuPkg/SecCore/SecMain.c
+++ b/UefiCpuPkg/SecCore/SecMain.c
@@ -239,10 +239,10 @@ SecStartupPhase2(
DEBUG ((
DEBUG_INFO,
- "%a() Stack Base: 0x%lx, Stack Size: 0x%lx\n",
+ "%a() Stack Base: 0x%p, Stack Size: 0x%x\n",
__FUNCTION__,
SecCoreData->StackBase,
- SecCoreData->StackSize
+ (UINT32) SecCoreData->StackSize
));
//
--
2.9.3.windows.2
next reply other threads:[~2016-11-16 7:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-16 7:55 Jeff Fan [this message]
2016-11-16 16:23 ` [PATCH v2] UefiCpuPkg/SecCore: Correct print format for stack information Laszlo Ersek
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=20161116075506.9008-1-jeff.fan@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