Hi, > > Oh. So the ELF header *replaces* the firmware volume header. > > Didn't notice that before. > > > > Hmm. With that the varstore initialization most likely fails. > > There is a fallback path though, with ovmf storing variables > > elsewhere (in normal ram instead of firmware flash I think). > > Persistent variables don't work in that case. > > > > When the persistent varstore doesn't work anyway (and you are > > ok with that) you probably can drop the space reserved for it > > from the firmware image and use just a single page for the pvh > > elf header (and sharing VarStore.fdf doesn't make sense then). > > Sorry it's not entirely clear to me what should be done here. Should I > remove the VARS section since we're not using it anyway? > I'm lacking some knowledge here to understand what this is used for, > and how I actually broke it. I mean with the define and the include, I > ended up modifying exclusively the [FD.CLOUDHV] which is exactly what > was done for Xen. Do you think the Xen VARS section is broken as well?
Probably. Not sure how xen uses the generated firmware images though. OVMF has three images. The OVMF_VARS.fd is the variable store. OVMF_CODE.fd is the firmware code. Both combined is OVMF.fd. The split into VARS and CODE exists to simplify firmware updates: On the host machine you'll have a per-guest VARS file with the persistent uefi variables, and the shared CODE file. Firmware upgrades work by simply updating the shared CODE file. The address space layout is the same in both cases (combined/splitted). The firmware takes 2M or 4M below 4G. The upper part is covered by the CODE, the lower part is covered by VARS. OVMF expects the varstore at a fixes address, but as mentioned can cope with the varstore not being there or not being backed by flash. So, do you use the CODE or VARS file for cloudhv? Does cloudhv emulate flash? take care, Gerd -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#87047): https://edk2.groups.io/g/devel/message/87047 Mute This Topic: https://groups.io/mt/89385947/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-