On Fri, Jan 25, 2013 at 2:20 AM, Laszlo Ersek <[email protected]> wrote: > On 01/25/13 05:46, Jordan Justen wrote: >> On Wed, Jan 16, 2013 at 5:47 PM, Laszlo Ersek <[email protected]> wrote: > >>> This has been increased in svn rev 13519 most recently, but why do we >>> need MEMFD at all? >> >> MEMFD is a firmware volume with most OVMF code/data uncompressed. It >> is compressed in a single pass, and put into another FV as a single >> compressed firmware volume file. > > Where does that happen? I can find no reference to MEMFD. (And MEMFD > looks like a flash device image, not a firmware volume.) > > I can see the following structure in OvmfPkg/OvmfPkgX64.fdf: > > FD.OVMF > FV.FVMAIN_COMPACT > FV.MAINFV > FV.DXEFV > FV.SECFV > > FD.MEMFD > FV.MAINFV > FV.DXEFV > > Nothing seems to reference either top-level definition. For FD.OVMF > that's OK because the file is built (as OVMF.fd) and we run it in qemu. > > MEMFD.fd is also built but never run directly. How is it used? > > (2.3 "[FD] Sections" in the FDF spec seems to support that FD.OVMF and > FD.MEMFD are independent. I'm not contradicting you, I just can't find > the proof in the spec :))
Sorry, I was a bit off in my previous explanation. You are right, MEMFD is not used, but all it contains is MAINFV. MEMFD is built so MAINFV's contents will be relocated during the build to address 0x800000. This allows SEC to decompress it to 0x800000, and jump directly to PeiCore without relocating the PE/COFF image. Today there might be another way to get MAINFV's images to be relocated at build time, but I don't think that was the case originally. -Jordan ------------------------------------------------------------------------------ Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS, MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft MVPs and experts. ON SALE this month only -- learn more at: http://p.sf.net/sfu/learnnow-d2d _______________________________________________ edk2-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/edk2-devel
