summaryrefslogtreecommitdiffstats
path: root/OvmfPkg/EmuVariableFvbRuntimeDxe/Fvb.h
Commit message (Collapse)AuthorAgeFilesLines
* OvmfPkg: Apply uncrustify changesMichael Kubacki2021-12-071-21/+18
| | | | | | | | | | | | REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3737 Apply uncrustify changes to .c/.h files in the OvmfPkg package Cc: Andrew Fish <afish@apple.com> Cc: Leif Lindholm <leif@nuviainc.com> Cc: Michael D Kinney <michael.d.kinney@intel.com> Signed-off-by: Michael Kubacki <michael.kubacki@microsoft.com> Reviewed-by: Andrew Fish <afish@apple.com>
* OvmfPkg: Replace BSD License with BSD+Patent LicenseMichael D Kinney2019-04-091-7/+1
| | | | | | | | | | | | | | | | | | | | https://bugzilla.tianocore.org/show_bug.cgi?id=1373 Replace BSD 2-Clause License with BSD+Patent License. This change is based on the following emails: https://lists.01.org/pipermail/edk2-devel/2019-February/036260.html https://lists.01.org/pipermail/edk2-devel/2018-October/030385.html RFCs with detailed process for the license change: V3: https://lists.01.org/pipermail/edk2-devel/2019-March/038116.html V2: https://lists.01.org/pipermail/edk2-devel/2019-March/037669.html V1: https://lists.01.org/pipermail/edk2-devel/2019-March/037500.html Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/EmuVariableFvbRuntimeDxe: change block size to 4KBLaszlo Ersek2017-05-181-2/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | EmuVariableFvbRuntimeDxe currently produces a Firmware Volume Block protocol that is based on a block map of two blocks, each block having PcdFlashNvStorageFtwSpareSize for size. (The total size is 2 * PcdFlashNvStorageFtwSpareSize.) FaultTolerantWriteDxe in turn expects the block size to be a power of two. In the 4MB build of OVMF, PcdFlashNvStorageFtwSpareSize is 264KB, which is not a power of two. In order to equip EmuVariableFvbRuntimeDxe for this build, shrink the block size to 4KB (EFI_PAGE_SIZE), and grow the block count from 2 to EFI_SIZE_TO_PAGES(2 * PcdFlashNvStorageFtwSpareSize). The total size remains 2 * PcdFlashNvStorageFtwSpareSize --------------------------------- * EFI_PAGE_SIZE EFI_PAGE_SIZE Right now EmuVariableFvbRuntimeDxe open-codes the block count of 2 in various limit checks, so introduce a few new macros: - EMU_FVB_NUM_TOTAL_BLOCKS, for the LHS of the above product, - EMU_FVB_NUM_SPARE_BLOCKS for the half of that. Also rework the FVB protocol members to support an arbitrary count of blocks. Keep the invariant intact that the first half of the firmware volume hosts the variable store and the FTW working block, and that the second half maps the FTW spare area. Cc: Jordan Justen <jordan.l.justen@intel.com> Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=527 Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Regression-tested-by: Gary Lin <glin@suse.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
* OvmfPkg/EmuVariableFvbRuntimeDxe: strip trailing whitespaceLaszlo Ersek2017-05-181-8/+8
| | | | | | | | Cc: Jordan Justen <jordan.l.justen@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Regression-tested-by: Gary Lin <glin@suse.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
* Update the copyright notice formathhtian2010-04-281-2/+2
| | | | git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10439 6f19259b-4bc3-4df7-8a09-765794883524
* Add EmuVariableFvbRuntimeDxe driver.jljusten2009-09-261-0/+140
This driver implements a firmware volume block protocol instance which is stored in system memory. The MdeModulePkg/Universal/Variable/RuntimeDxe and MdeModulePkg/Universal/FaultTolerantWriteDxe drivers make use of this FVB instance to provide variable services. This driver links to a PlatformFvb library to allow for platform specific processing to take place when data is written to the FVB. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9315 6f19259b-4bc3-4df7-8a09-765794883524