[edk2-devel] [PATCH v2 05/10] MdePkg: add MmRegisterShutdownInterface()

Laszlo Ersek lersek at redhat.com
Thu Jan 7 21:50:01 UTC 2021


On 01/07/21 22:19, Ankur Arora wrote:
> On 2021-01-07 12:48 p.m., Laszlo Ersek wrote:

>> We should limit ourselves to modifying only the contents of
>> SmmCpuFeaturesRendezvousExit() in OvmfPkg/Library/SmmCpuFeaturesLib.
> 
> That was my initial approach. The problem that ran into was that which
> CPUs to eject depends on state held in OvmfPkg/CpuHotPlugSmm (see patch 8)
> which, I could not figure out a way to make that available given that the
> libraries are linked statically.

[...]

> Could you take a look at patch 8? That's really the crux of the series

Indeed.

The proposal I just sent elsewhere in this patch#5 sub-thread addresses
exactly that.

It's a frequent cross-driver communication pattern in edk2, utilizing
dynamic PCDs (platform configuration database entries).

The tricky part with this pattern is always proper serialization (make
sure the publishing driver always performs the PcdSet before the
consuming driver performs the PcdGet). This is often achieved with a
DEPEX. Luckily, in this case, such a depex (and indeed an earlier
instance of this exact same pattern) is already in place between
PiSmmCpuDxeSmm and CpuHotplugSmm, so you can imitate it. In the other
email, I laid out the suggested steps.

Thanks!
Laszlo



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#69986): https://edk2.groups.io/g/devel/message/69986
Mute This Topic: https://groups.io/mt/79507550/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-





More information about the edk2-devel-archive mailing list