{\rtf1\ansi\ansicpg1252\deff0\deflang1033\deflangfe2052\deftab360{\fonttbl{\f0\fswiss\fprq2\fcharset0 Verdana;}{\f1\froman\fprq2\fcharset0 Times New Roman;}}
\pard\nowidctlpar\sb200\cf2\b0\fs18 GenFv is used to \cf0 generate a PI firmware volume image or a UEFI capsule image from the PI firmware files or the binary files, which conforms to the firmware volume image format defined in PI specification or uefi capsule image format defined in UEFI specification.\cf2\f1\par
\f0 This utility is responsible for aggregating Firmware File System (FFS2) files into a single FV image with FFS2 file system guid. The input files must be compliant with the PI 1.0 specification. The utility will create a FV header, append all of the FFS input files, and optionally add the FFS pad file for those FFS files that require the specific file alignment. When adding PEI files or dxe drivers, it will relocate them to the fixed flash address or the prefered loaded memory address if necessary. Also, one symbol map file that contains the symbol information (Function and Variable) for each driver in the FV will be produced. This utility is also responsible for aggregating the binary files into a single UEFI capsule image with the UEFI capsule header. \par
GenFv takes as input the path/filename of the Fv.inf or Cap.inf file, the output file name, the starting physical address of the FV, the boot driver base address and the runtime driver base address of the address.inf file to create the final Fv or Capsule image. This utility is usually called by GenFds tool, which parses platform.fdf file to create the interanl Fv.inf or Cap.inf. Generally, user doesn't need to care about these internal file format.\par
\pard\nowidctlpar\li360\sb200\f0 File is the input FV.inf or Cap.inf to specify how to construct FvImage or CapImage. Fv.inf and Cap.inf will be introduced in the following examples. File may be one capsule image when its header is dumped. This option is required.\par
\tab\f0 Specify the size of the required space that the input file is placed in FV image. It should be specified together with the input file.\par
\b -r Address, --baseaddr Address\b0\f1\par
\tab\f0 Address is the rebase start address for drivers that run in Flash. It supports DEC or HEX digital format.\par
\b -a AddressFile, --addrfile AddressFile\par
\tab\b0 AddressFile is one file used to log boot driver base address and runtime driver base address. And this tool will update these two addresses after it \tab relocates all boot drivers and runtime drivers in this fv image to the preferred loaded memory address.\par
\b -m logfile, --map logfile\b0\f1\par
\tab\f0 Logfile is the output Fv map file. If this option is not given, the FvName.map will be the default fv map file name.\b\f1\par
\f0 -g Guid, --guid Guid\b0\f1\par
\f0 Guid is one specific capsule guid value or fv file system guid value.\par
Its format is xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.\par
\b --FvNameGuid Guid\f1\par
\b0\f0 Guid is used to specify Fv Name. \f1\par
\f0 Its format is xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\f1\par
\b\f0 --capflag CapFlag\b0\f1\par
\tab\f0 Specify capsule reset flag (PersistAcrossReset, PopulateSystemTable or InitiateReset or none).\par
\b --capheadsize HeadSize\b0\f1\par
\tab\f0 Specify head size for capsule image in the format of HEX or DEC.\par
\b -c, --capsule\b0\f1\par
\tab\f0 Create Uefi capsule image.\par
\b -p, --dump\b0\f1\par
\tab\f0 Dump a capsule image header.\par
\b -v, --verbose\par
\b0\f1\tab\f0 Turn on verbose output with informational messages.\par
\b -q, --quiet \f1\par
\f0 \b0 Disable all messages except key message and fatal error.\b\f1\par
\f0 -d, --debug level\par
\b0\f1\tab\f0 Enable debug message with specified level.\par
\b --version\par
\pard\nowidctlpar\fi360\sb200\b0 Show program's version number and exit\par
\pard\nowidctlpar\sb200\b -h, --help\par
\pard\nowidctlpar\fi360\sb200\b0 Show this help message and exit\par
\pard\nowidctlpar\sb200\cf2\b0\fs18 1. Generate BFV that contains PEI drivers in Flash with the input FV.inf, base address, and the output file name.\par
\b0\f0 2. Generate FvMain that contains Dxe drivers loaded in the preferred loaded memory address with the input FV.inf, address file, the output file name, its firmware file system guid (FFS2) and its guid name.\f1\par
\b\f0 GenFv -i FvMain.inf -o FvMain.fv -a Addr.inf \endash g 8c8ce578-8a3d-4f1c-9935-896185c32dd3 \endash FvNameGuid 6D99E806-3D38-42c2-A095-5F4300BFD7DC\f1\par