[edk2-devel] [PATCH V2 14/14] MdeModulePkg: Pool and page functions accept memory when OOM occurs

Ni, Ray ray.ni at intel.com
Tue Aug 30 07:12:16 UTC 2022


I saw the justification of this is to support different size of Linux kernel images.
But that's after TD DXE driver.
For code running before TD DXE driver, the memory needs is predicable, right?

> -----Original Message-----
> From: Xu, Min M <min.m.xu at intel.com>
> Sent: Tuesday, August 30, 2022 2:35 PM
> To: Ni, Ray <ray.ni at intel.com>; devel at edk2.groups.io;
> thomas.lendacky at amd.com
> Cc: Gao, Jiaqi <jiaqi.gao at intel.com>; Wang, Jian J <jian.j.wang at intel.com>;
> Gao, Liming <gaoliming at byosoft.com.cn>; Bi, Dandan
> <dandan.bi at intel.com>; Aktas, Erdem <erdemaktas at google.com>; James
> Bottomley <jejb at linux.ibm.com>; Yao, Jiewen <jiewen.yao at intel.com>;
> Gerd Hoffmann <kraxel at redhat.com>
> Subject: RE: [edk2-devel] [PATCH V2 14/14] MdeModulePkg: Pool and page
> functions accept memory when OOM occurs
> 
> On August 30, 2022 2:15 PM, Ni Ray wrote:
> > Min,
> > My understanding is there is a TDX driver in DXE phase that accepts
> memory
> > using MP protocol.
> EdkiiMemoryAcceptProtocol is a protocol which accept memories. It is
> implemented/installed by the platform drivers, such as TdxDxe driver, or SEV
> driver.
> It is up to the platform driver (Tdx or SEV driver) if MP protocol is used.
> > We only need to make sure there is sufficient memory for code running
> > before that point.
> > Is my understanding correct?
> That's right. But we'd better accept sufficient memory for the whole DXE
> phase. If OOM is triggered it's better accept more memory than the size
> needed. In current implementation we accept the memory in units of 32MB.
> 
> Thanks
> Min


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#92962): https://edk2.groups.io/g/devel/message/92962
Mute This Topic: https://groups.io/mt/93285612/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