public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Oliver Smith-Denny" <osde@linux.microsoft.com>
To: devel@edk2.groups.io, nhi@os.amperecomputing.com, nhiphambka@gmail.com
Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>,
	Ray Ni <ray.ni@intel.com>, Sami Mujawar <sami.mujawar@arm.com>,
	Kun Qin <kuqin12@gmail.com>
Subject: Re: [edk2-devel] [PATCH v1 1/1] StandaloneMmPkg/StandaloneMmHobLib: Remove HOB creation
Date: Fri, 3 May 2024 06:56:24 -0700	[thread overview]
Message-ID: <a78bb446-7170-4b6c-bd6e-91e641fb7342@linux.microsoft.com> (raw)
In-Reply-To: <db86060a-ac16-41e8-8f02-8aefc5305856@os.amperecomputing.com>

On 5/2/2024 7:28 PM, Nhi Pham via groups.io wrote:
> On 5/2/2024 4:31 AM, Oliver Smith-Denny via groups.io wrote:
>> Hi folks, returning to this thread because I noticed that HOB
>> creation still exists in StandaloneMmCore for ARM:
>>
>> https://github.com/tianocore/edk2/blob/5d4c5253e8bbc0baa8837fcd868925212df85201/StandaloneMmPkg/Library/StandaloneMmCoreEntryPoint/Arm/CreateHobList.c
>>
>> As far as I can tell, there is only this one file that creates 6
>> HOBs from StandaloneMmCore. Per our earlier discussion that led to
>> disabling HOB creation in StandaloneMm, I think that this falls into
>> the case where StandaloneMm is a HOB consumer phase, not a producer
>> phase and so it should not be creating these HOBs. On the x64 side,
>> all of the StandaloneMm HOB creation functions ASSERT with the
>> comment that StandaloneMm is a HOB consumer phase and should not
>> be creating HOBs.
> 
> The HOB creation in StandaloneMmCoreEntryPoint is exclusively consumed 
> by the MM_CORE_STANDALONE module 
> (StandaloneMmPkg/Core/StandaloneMmCore.inf), not a MM_STANDALONE module. 
> Per my understanding earlier, the MM_CORE_STANDALONE is a producer and 
> other MM_STANDALONE modules are consumers. So we removed the HOB 
> creation in the StandaloneMmHobLib which is consumed by MM_STANDALONE 
> modules.
> 
> Also, we still retain the HOB creation in the 
> StandaloneMmPkg/Library/StandaloneMmCoreHobLib library instance.
> 

The PI spec is light on details on HOBs in Standalone MM, but it is
clear that there are HOB producer phases and HOB consumer phases.
Pre-Standalone MM, the HOB producer phase was PEI and the HOB
consumer phase was DXE/SMM. In the Standalone MM world, it still
follows that a boot phase is either a HOB consumer or a HOB
producer. Currently, Standalone MM is both, regardless that it is
the core that is producing the HOBs.

I think that Levi's work to remove HOB creation in Standalone MM
and move it to TF-A is the right move here.

Thanks,
Oliver


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#118556): https://edk2.groups.io/g/devel/message/118556
Mute This Topic: https://groups.io/mt/103018869/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-



      reply	other threads:[~2024-05-03 13:56 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-05 13:47 [edk2-devel] [PATCH v1 1/1] StandaloneMmPkg/StandaloneMmHobLib: Remove HOB creation Nhi Pham
2023-12-09  1:27 ` Ni, Ray
2023-12-11  5:49   ` Ni, Ray
2024-05-01 21:31 ` Oliver Smith-Denny
2024-05-02 14:52   ` Sami Mujawar
2024-05-02 17:02     ` Oliver Smith-Denny
2024-05-03  2:28   ` Nhi Pham via groups.io
2024-05-03 13:56     ` Oliver Smith-Denny [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=a78bb446-7170-4b6c-bd6e-91e641fb7342@linux.microsoft.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