* [edk2-devel] [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message @ 2023-10-05 16:18 Jake Garver via groups.io 2023-10-07 5:05 ` [edk2-devel] 回复: " gaoliming via groups.io 0 siblings, 1 reply; 6+ messages in thread From: Jake Garver via groups.io @ 2023-10-05 16:18 UTC (permalink / raw) To: devel; +Cc: michael.d.kinney, gaoliming, zhiguang.liu, Jake Garver __builtin_return_address returns a pointer, not a string. Fix the STACK FAULT message in BaseStackCheckLib appropriately. Signed-off-by: Jake Garver <jake@nvidia.com> --- MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c index 0d2918668e..ea168841b6 100644 --- a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c +++ b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c @@ -6,6 +6,7 @@ to exiting the function. If the "canary" is overwritten __stack_chk_fail() is called. This is GCC specific code. + Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved. Copyright (c) 2012, Apple Inc. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent @@ -34,7 +35,7 @@ __stack_chk_fail ( { UINT8 DebugPropertyMask; - DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow in function %a.\n", __builtin_return_address (0))); + DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow at 0x%p.\n", RETURN_ADDRESS (0))); // // Generate a Breakpoint, DeadLoop, or NOP based on PCD settings even if -- 2.34.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#109359): https://edk2.groups.io/g/devel/message/109359 Mute This Topic: https://groups.io/mt/101779895/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=- ^ permalink raw reply related [flat|nested] 6+ messages in thread
* [edk2-devel] 回复: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message 2023-10-05 16:18 [edk2-devel] [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message Jake Garver via groups.io @ 2023-10-07 5:05 ` gaoliming via groups.io 2023-10-18 14:45 ` [edk2-devel] " Jake Garver via groups.io 0 siblings, 1 reply; 6+ messages in thread From: gaoliming via groups.io @ 2023-10-07 5:05 UTC (permalink / raw) To: 'Jake Garver', devel; +Cc: michael.d.kinney, zhiguang.liu Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn> > -----邮件原件----- > 发件人: Jake Garver <jake@nvidia.com> > 发送时间: 2023年10月6日 0:19 > 收件人: devel@edk2.groups.io > 抄送: michael.d.kinney@intel.com; gaoliming@byosoft.com.cn; > zhiguang.liu@intel.com; Jake Garver <jake@nvidia.com> > 主题: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message > > __builtin_return_address returns a pointer, not a string. Fix the STACK > FAULT message in BaseStackCheckLib appropriately. > > Signed-off-by: Jake Garver <jake@nvidia.com> > --- > MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > index 0d2918668e..ea168841b6 100644 > --- a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > +++ b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > @@ -6,6 +6,7 @@ > to exiting the function. If the "canary" is overwritten __stack_chk_fail() > is called. This is GCC specific code. > > + Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved. > Copyright (c) 2012, Apple Inc. All rights reserved.<BR> > SPDX-License-Identifier: BSD-2-Clause-Patent > > @@ -34,7 +35,7 @@ __stack_chk_fail ( > { > UINT8 DebugPropertyMask; > > - DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow in > function %a.\n", __builtin_return_address (0))); > + DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow at 0x%p.\n", > RETURN_ADDRESS (0))); > > // > // Generate a Breakpoint, DeadLoop, or NOP based on PCD settings even > if > -- > 2.34.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#109378): https://edk2.groups.io/g/devel/message/109378 Mute This Topic: https://groups.io/mt/101812329/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=- ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [edk2-devel] [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message 2023-10-07 5:05 ` [edk2-devel] 回复: " gaoliming via groups.io @ 2023-10-18 14:45 ` Jake Garver via groups.io 2023-12-06 16:36 ` Jake Garver via groups.io 0 siblings, 1 reply; 6+ messages in thread From: Jake Garver via groups.io @ 2023-10-18 14:45 UTC (permalink / raw) To: gaoliming, devel@edk2.groups.io Cc: michael.d.kinney@intel.com, zhiguang.liu@intel.com [-- Attachment #1: Type: text/plain, Size: 2600 bytes --] Thanks for the review, Liming Gao. Any further comments on this change? Thanks, Jake ________________________________ From: gaoliming <gaoliming@byosoft.com.cn> Sent: Saturday, October 7, 2023 1:05 AM To: Jake Garver <jake@nvidia.com>; devel@edk2.groups.io <devel@edk2.groups.io> Cc: michael.d.kinney@intel.com <michael.d.kinney@intel.com>; zhiguang.liu@intel.com <zhiguang.liu@intel.com> Subject: 回复: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message External email: Use caution opening links or attachments Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn> > -----邮件原件----- > 发件人: Jake Garver <jake@nvidia.com> > 发送时间: 2023年10月6日 0:19 > 收件人: devel@edk2.groups.io > 抄送: michael.d.kinney@intel.com; gaoliming@byosoft.com.cn; > zhiguang.liu@intel.com; Jake Garver <jake@nvidia.com> > 主题: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message > > __builtin_return_address returns a pointer, not a string. Fix the STACK > FAULT message in BaseStackCheckLib appropriately. > > Signed-off-by: Jake Garver <jake@nvidia.com> > --- > MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > index 0d2918668e..ea168841b6 100644 > --- a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > +++ b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > @@ -6,6 +6,7 @@ > to exiting the function. If the "canary" is overwritten __stack_chk_fail() > is called. This is GCC specific code. > > + Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved. > Copyright (c) 2012, Apple Inc. All rights reserved.<BR> > SPDX-License-Identifier: BSD-2-Clause-Patent > > @@ -34,7 +35,7 @@ __stack_chk_fail ( > { > UINT8 DebugPropertyMask; > > - DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow in > function %a.\n", __builtin_return_address (0))); > + DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow at 0x%p.\n", > RETURN_ADDRESS (0))); > > // > // Generate a Breakpoint, DeadLoop, or NOP based on PCD settings even > if > -- > 2.34.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#109756): https://edk2.groups.io/g/devel/message/109756 Mute This Topic: https://groups.io/mt/102040342/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=- [-- Attachment #2: Type: text/html, Size: 5230 bytes --] ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [edk2-devel] [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message 2023-10-18 14:45 ` [edk2-devel] " Jake Garver via groups.io @ 2023-12-06 16:36 ` Jake Garver via groups.io 2023-12-06 16:46 ` Michael D Kinney 0 siblings, 1 reply; 6+ messages in thread From: Jake Garver via groups.io @ 2023-12-06 16:36 UTC (permalink / raw) To: gaoliming, devel@edk2.groups.io Cc: michael.d.kinney@intel.com, zhiguang.liu@intel.com [-- Attachment #1: Type: text/plain, Size: 3067 bytes --] Any further comments on this change? I'd like to get it merged. Thanks, Jake ________________________________ From: Jake Garver <jake@nvidia.com> Sent: Wednesday, October 18, 2023 10:45 AM To: gaoliming <gaoliming@byosoft.com.cn>; devel@edk2.groups.io <devel@edk2.groups.io> Cc: michael.d.kinney@intel.com <michael.d.kinney@intel.com>; zhiguang.liu@intel.com <zhiguang.liu@intel.com> Subject: Re: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message Thanks for the review, Liming Gao. Any further comments on this change? Thanks, Jake ________________________________ From: gaoliming <gaoliming@byosoft.com.cn> Sent: Saturday, October 7, 2023 1:05 AM To: Jake Garver <jake@nvidia.com>; devel@edk2.groups.io <devel@edk2.groups.io> Cc: michael.d.kinney@intel.com <michael.d.kinney@intel.com>; zhiguang.liu@intel.com <zhiguang.liu@intel.com> Subject: 回复: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message External email: Use caution opening links or attachments Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn> > -----邮件原件----- > 发件人: Jake Garver <jake@nvidia.com> > 发送时间: 2023年10月6日 0:19 > 收件人: devel@edk2.groups.io > 抄送: michael.d.kinney@intel.com; gaoliming@byosoft.com.cn; > zhiguang.liu@intel.com; Jake Garver <jake@nvidia.com> > 主题: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message > > __builtin_return_address returns a pointer, not a string. Fix the STACK > FAULT message in BaseStackCheckLib appropriately. > > Signed-off-by: Jake Garver <jake@nvidia.com> > --- > MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > index 0d2918668e..ea168841b6 100644 > --- a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > +++ b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > @@ -6,6 +6,7 @@ > to exiting the function. If the "canary" is overwritten __stack_chk_fail() > is called. This is GCC specific code. > > + Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved. > Copyright (c) 2012, Apple Inc. All rights reserved.<BR> > SPDX-License-Identifier: BSD-2-Clause-Patent > > @@ -34,7 +35,7 @@ __stack_chk_fail ( > { > UINT8 DebugPropertyMask; > > - DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow in > function %a.\n", __builtin_return_address (0))); > + DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow at 0x%p.\n", > RETURN_ADDRESS (0))); > > // > // Generate a Breakpoint, DeadLoop, or NOP based on PCD settings even > if > -- > 2.34.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#112131): https://edk2.groups.io/g/devel/message/112131 Mute This Topic: https://groups.io/mt/102040342/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=- [-- Attachment #2: Type: text/html, Size: 7101 bytes --] ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [edk2-devel] [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message 2023-12-06 16:36 ` Jake Garver via groups.io @ 2023-12-06 16:46 ` Michael D Kinney 2023-12-06 17:11 ` Michael D Kinney 0 siblings, 1 reply; 6+ messages in thread From: Michael D Kinney @ 2023-12-06 16:46 UTC (permalink / raw) To: Jake Garver, Gao, Liming, devel@edk2.groups.io Cc: Liu, Zhiguang, Kinney, Michael D [-- Attachment #1: Type: text/plain, Size: 4253 bytes --] Hi Jake, PR opened with Rb tag added: https://github.com/tianocore/edk2/pull/5113 Mike From: Jake Garver <jake@nvidia.com> Sent: Wednesday, December 6, 2023 8:37 AM To: Gao, Liming <gaoliming@byosoft.com.cn>; devel@edk2.groups.io Cc: Kinney, Michael D <michael.d.kinney@intel.com>; Liu, Zhiguang <zhiguang.liu@intel.com> Subject: Re: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message Any further comments on this change? I'd like to get it merged. Thanks, Jake ________________________________ From: Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>> Sent: Wednesday, October 18, 2023 10:45 AM To: gaoliming <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> Cc: michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com> <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com> <zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com>> Subject: Re: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message Thanks for the review, Liming Gao. Any further comments on this change? Thanks, Jake ________________________________ From: gaoliming <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>> Sent: Saturday, October 7, 2023 1:05 AM To: Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>>; devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> Cc: michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com> <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com> <zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com>> Subject: 回复: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message External email: Use caution opening links or attachments Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>> > -----邮件原件----- > 发件人: Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>> > 发送时间: 2023年10月6日 0:19 > 收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> > 抄送: michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>; gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>; > zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com>; Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>> > 主题: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message > > __builtin_return_address returns a pointer, not a string. Fix the STACK > FAULT message in BaseStackCheckLib appropriately. > > Signed-off-by: Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>> > --- > MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > index 0d2918668e..ea168841b6 100644 > --- a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > +++ b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > @@ -6,6 +6,7 @@ > to exiting the function. If the "canary" is overwritten __stack_chk_fail() > is called. This is GCC specific code. > > + Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved. > Copyright (c) 2012, Apple Inc. All rights reserved.<BR> > SPDX-License-Identifier: BSD-2-Clause-Patent > > @@ -34,7 +35,7 @@ __stack_chk_fail ( > { > UINT8 DebugPropertyMask; > > - DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow in > function %a.\n", __builtin_return_address (0))); > + DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow at 0x%p.\n", > RETURN_ADDRESS (0))); > > // > // Generate a Breakpoint, DeadLoop, or NOP based on PCD settings even > if > -- > 2.34.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#112132): https://edk2.groups.io/g/devel/message/112132 Mute This Topic: https://groups.io/mt/102040342/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/leave/12367111/7686176/1913456212/xyzzy [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=- [-- Attachment #2: Type: text/html, Size: 11801 bytes --] ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [edk2-devel] [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message 2023-12-06 16:46 ` Michael D Kinney @ 2023-12-06 17:11 ` Michael D Kinney 0 siblings, 0 replies; 6+ messages in thread From: Michael D Kinney @ 2023-12-06 17:11 UTC (permalink / raw) To: Jake Garver, Gao, Liming, devel@edk2.groups.io Cc: Liu, Zhiguang, Kinney, Michael D [-- Attachment #1: Type: text/plain, Size: 4777 bytes --] Merged Mike From: Kinney, Michael D <michael.d.kinney@intel.com> Sent: Wednesday, December 6, 2023 8:47 AM To: Jake Garver <jake@nvidia.com>; Gao, Liming <gaoliming@byosoft.com.cn>; devel@edk2.groups.io Cc: Liu, Zhiguang <zhiguang.liu@intel.com>; Kinney, Michael D <michael.d.kinney@intel.com> Subject: RE: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message Hi Jake, PR opened with Rb tag added: https://github.com/tianocore/edk2/pull/5113 Mike From: Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>> Sent: Wednesday, December 6, 2023 8:37 AM To: Gao, Liming <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; devel@edk2.groups.io<mailto:devel@edk2.groups.io> Cc: Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Liu, Zhiguang <zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com>> Subject: Re: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message Any further comments on this change? I'd like to get it merged. Thanks, Jake ________________________________ From: Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>> Sent: Wednesday, October 18, 2023 10:45 AM To: gaoliming <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> Cc: michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com> <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com> <zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com>> Subject: Re: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message Thanks for the review, Liming Gao. Any further comments on this change? Thanks, Jake ________________________________ From: gaoliming <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>> Sent: Saturday, October 7, 2023 1:05 AM To: Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>>; devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> Cc: michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com> <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com> <zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com>> Subject: 回复: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message External email: Use caution opening links or attachments Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>> > -----邮件原件----- > 发件人: Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>> > 发送时间: 2023年10月6日 0:19 > 收件人: devel@edk2.groups.io<mailto:devel@edk2.groups.io> > 抄送: michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>; gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>; > zhiguang.liu@intel.com<mailto:zhiguang.liu@intel.com>; Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>> > 主题: [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message > > __builtin_return_address returns a pointer, not a string. Fix the STACK > FAULT message in BaseStackCheckLib appropriately. > > Signed-off-by: Jake Garver <jake@nvidia.com<mailto:jake@nvidia.com>> > --- > MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > index 0d2918668e..ea168841b6 100644 > --- a/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > +++ b/MdePkg/Library/BaseStackCheckLib/BaseStackCheckGcc.c > @@ -6,6 +6,7 @@ > to exiting the function. If the "canary" is overwritten __stack_chk_fail() > is called. This is GCC specific code. > > + Copyright (c) 2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved. > Copyright (c) 2012, Apple Inc. All rights reserved.<BR> > SPDX-License-Identifier: BSD-2-Clause-Patent > > @@ -34,7 +35,7 @@ __stack_chk_fail ( > { > UINT8 DebugPropertyMask; > > - DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow in > function %a.\n", __builtin_return_address (0))); > + DEBUG ((DEBUG_ERROR, "STACK FAULT: Buffer Overflow at 0x%p.\n", > RETURN_ADDRESS (0))); > > // > // Generate a Breakpoint, DeadLoop, or NOP based on PCD settings even > if > -- > 2.34.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#112134): https://edk2.groups.io/g/devel/message/112134 Mute This Topic: https://groups.io/mt/102040342/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/leave/12367111/7686176/1913456212/xyzzy [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=- [-- Attachment #2: Type: text/html, Size: 13549 bytes --] ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2023-12-06 17:11 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2023-10-05 16:18 [edk2-devel] [PATCH v2] BaseStackCheckLib: Fix STACK FAULT message Jake Garver via groups.io 2023-10-07 5:05 ` [edk2-devel] 回复: " gaoliming via groups.io 2023-10-18 14:45 ` [edk2-devel] " Jake Garver via groups.io 2023-12-06 16:36 ` Jake Garver via groups.io 2023-12-06 16:46 ` Michael D Kinney 2023-12-06 17:11 ` Michael D Kinney
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox