From: "Sunil V L" <sunilvl@ventanamicro.com>
To: devel@edk2.groups.io, andrei.warkentin@intel.com
Cc: Yang Wang <wangyang@bosc.ac.cn>, Ran Wang <wangran@bosc.ac.cn>,
Bamvor Jian ZHANG <zhangjian@bosc.ac.cn>,
"Gao, Liming" <gaoliming@byosoft.com.cn>,
"Kinney, Michael D" <michael.d.kinney@intel.com>,
"Liu, Zhiguang" <zhiguang.liu@intel.com>
Subject: Re: [edk2-devel] [PATCH v2] MdePkg/BaseLib:Fix boot DxeCore hang on riscv platform
Date: Thu, 11 Jan 2024 20:51:21 +0530 [thread overview]
Message-ID: <ZaAHcW4tT9vHDKLx@sunil-laptop> (raw)
In-Reply-To: <PH8PR11MB68567DB1519313ED419CB2A883662@PH8PR11MB6856.namprd11.prod.outlook.com>
On Fri, Jan 05, 2024 at 03:47:07PM +0000, Andrei Warkentin wrote:
> Looks reasonable to me.
>
> Reviewed-by: Andrei Warkentin <andrei.warkentin@intel.com>
>
> > -----Original Message-----
> > From: Yang Wang <wangyang@bosc.ac.cn>
> > Sent: Wednesday, December 27, 2023 8:57 PM
> > To: Warkentin, Andrei <andrei.warkentin@intel.com>; devel@edk2.groups.io
> > Cc: Yang Wang <wangyang@bosc.ac.cn>; Ran Wang <wangran@bosc.ac.cn>;
> > Bamvor Jian ZHANG <zhangjian@bosc.ac.cn>; Gao, Liming
> > <gaoliming@byosoft.com.cn>; Kinney, Michael D
> > <michael.d.kinney@intel.com>; Sunil V L <sunilvl@ventanamicro.com>; Liu,
> > Zhiguang <zhiguang.liu@intel.com>
> > Subject: [PATCH v2] MdePkg/BaseLib:Fix boot DxeCore hang on riscv platform
> >
> > For scene of
> > HandOffToDxeCore()->SwitchStack(DxeCoreEntryPoint)->
> > InternalSwitchStack()->LongJump(),Variable HobList.Raw
> > will be passed (from *Context1 to register a0) to
> > DxeMain() in parameter *HobStart.
> >
> > However, meanwhile the function LongJump() overrides
> > register a0 with a1 (-1) due to commit (ea628f28e5 "RISCV: Fix
> > InternalLongJump to return correct value"), then cause hang.
> >
> > Replacing calling LongJump() with new InternalSwitchStackAsm() to pass
> > addres data in register s0 to register a0 could fix this issue (just
> > like the solution in MdePkg/Library/BaseLib/AArch64/SwitchStack.S)
> >
> > Signed-off-by: Yang Wang <wangyang@bosc.ac.cn>
> > Reviewed-by: Ran Wang <wangran@bosc.ac.cn>
> > Cc: Bamvor Jian ZHANG <zhangjian@bosc.ac.cn>
> > Cc: Andrei Warkentin <andrei.warkentin@intel.com>
> > Cc: Liming Gao <gaoliming@byosoft.com.cn>
> > Cc: Michael D Kinney <michael.d.kinney@intel.com>
> > Cc: Sunil V L <sunilvl@ventanamicro.com>
> > Cc: Zhiguang Liu <zhiguang.liu@intel.com>
> > ---
Thanks for the patch!. Merged this as #5255 after fixing a minor
formatting issue.
Thanks,
Sunil
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#113624): https://edk2.groups.io/g/devel/message/113624
Mute This Topic: https://groups.io/mt/103395756/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-
next prev parent reply other threads:[~2024-01-11 15:21 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-28 2:56 [edk2-devel] [PATCH v2] MdePkg/BaseLib:Fix boot DxeCore hang on riscv platform 王洋
2024-01-05 15:47 ` Andrei Warkentin
2024-01-11 15:21 ` Sunil V L [this message]
2024-01-15 2:08 ` WangYang
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=ZaAHcW4tT9vHDKLx@sunil-laptop \
--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