1{\rtf1\ansi\ansicpg1252\deff0\deflang1033\deflangfe2052\deftab360{\fonttbl{\f0\fswiss\fprq2\fcharset0 Verdana;}{\f1\froman\fprq2\fcharset0 Times New Roman;}{\f2\fswiss\fprq2\fcharset0 Arial;}} 2{\colortbl ;\red8\green96\blue168;\red0\green0\blue0;} 3{\stylesheet{ Normal;}{\s1 heading 1;}{\s2 heading 2;}} 4{\*\generator Msftedit 5.41.15.1515;}\viewkind4\uc1\pard\keep\keepn\nowidctlpar\s2\li-1440\sb400\sa60\sl-340\slmult0\cf1\b\f0\fs28 Name\par 5\pard\nowidctlpar\sb200\cf2\b0\fs18 PatchPcdValue.exe or PatchPcdValue.py \endash Patch the specific value into the binary image.\f1\par 6\pard\keep\keepn\nowidctlpar\s2\li-1440\sb400\sa60\sl-340\slmult0\tx1440\cf1\b\f0\fs28 Synopsis\par 7\pard\nowidctlpar\sb200\cf2\fs18 PatchPcdValue.exe -f Offset -u Value -t Type [-s MaxSize] <input_file>\f1\par 8\pard\keep\keepn\nowidctlpar\s2\li-1440\sb400\sa60\sl-340\slmult0\cf1\f0\fs28 Description\par 9\pard\nowidctlpar\sb200\cf2\b0\fs18 PatchPcdValue tool sets the specific value into the binary image according to the input PCD offset and type. When PCD type is VOID*, MaxSize must be specified to say how much value need to be updated. This tool checks whether the input PCD information is valid for the input binary image, but doesn\rquote t check the format of the binary image. \f1\par 10\f0 PatchPcdValue tool usually works together with GenPatchPcdTable tool to set the specific value of a patchable PCD into the binary EFI image. \f1\par 11\pard\keep\keepn\nowidctlpar\s2\li-1440\sb400\sa60\sl-340\slmult0\cf1\b\f0\fs28 Options\par 12\pard\nowidctlpar\sb200\cf2\fs18 -f PCDOFFSET, --offset=PCDOFFSET\f1\par 13\pard\nowidctlpar\li360\sb200\b0\f0 Start offset to the image is used to store PCD value.\f1\par 14\pard\nowidctlpar\sb200\b\f0 -u PCDVALUE, --value=PCDVALUE\f1\par 15\pard\nowidctlpar\li360\sb200\b0\f0 PCD value will be updated into the image. For VOID* type PCD value, if the start string is \ldblquote L \ldblquote , the input string will be unicode string, if the start string is \ldblquote\{\ldblquote and the end string is \ldblquote\}\rdblquote , the input string will be byte array, or the input string will be ASCII string.\f1\par 16\pard\nowidctlpar\sb200\b\f0 -t PCDTYPENAME, --type=PCDTYPENAME\f1\par 17\pard\nowidctlpar\li360\sb200\b0\f0 The name of PCD data type may be one of VOID*,BOOLEAN, UINT8, UINT16, UINT32, UINT64.\f1\par 18\pard\nowidctlpar\sb200\b\f0 -s PCDMAXSIZE, --maxsize=PCDMAXSIZE\f1\par 19\pard\nowidctlpar\li360\sb200\b0\f0 Max size of data buffer is taken by PCD value. It must be set when PCD type is VOID*.\f1\par 20\pard\nowidctlpar\sb200\b\f0 -v, --verbose\par 21\pard\nowidctlpar\fi360\sb200\b0 Run verbosely.\par 22\pard\nowidctlpar\sb200\b -d LOGLEVEL, --debug=LOGLEVEL [0-9]\f1\par 23\pard\nowidctlpar\fi360\sb200\b0\f0 Enable debug messages at specified level.\par 24\pard\nowidctlpar\sb200\b -q, --quiet\f1\par 25\pard\nowidctlpar\fi360\sb200\b0\f0 Run with little information in quiet mode.\f1\par 26\pard\nowidctlpar\sb200\b\f0 --verbose\f1\par 27\pard\nowidctlpar\fi360\sb200\b0\f0 Show program's version number and exit\par 28\pard\nowidctlpar\sb200\b -h, --help\par 29\pard\nowidctlpar\li360\sb200\b0 Show this help message and exit\f1\par 30\pard\keep\keepn\nowidctlpar\s2\li-1440\sb400\sa60\sl-340\slmult0\cf1\b\f0\fs28 Example\par 31\pard\nowidctlpar\sb200\cf2\b0\fs18 1. Patch 0x80000000 to the patchable PcdDebugPrintErrorLevel in the binary PeiCore image. This PCD type is UINT32. Its offset in PeiCore image is 0x6F80 got by GenPatchPcdTable tool.\f1\par 32\b\f0 PatchPcdValue.exe -f 0x6F80 \endash u 0x80000000 \endash t UINT32 PeiCore.efi\f1\par 33\b0\f0 2. Patch the unicode string \ldblquote Test\rdblquote to the patchable PcdHelloWorldPrintString in the binary HelloWorld image. This PCD type is VOID*. Its max byte array size is 0x40, and its offset in HelloWorld image is 0x3050.\f1\par 34\b\f0 PatchPcdValue.exe -f 0x3050 -t VOID* -s 0x40 -u "L Test" HelloWorld.efi\par 35\pard\keep\keepn\nowidctlpar\s2\li-1440\sb400\sa60\sl-340\slmult0\cf1\fs28 Bugs\par 36\pard\nowidctlpar\sb200\cf2\b0\fs18 No known bugs.\par 37Report bugs to edk2-buildtools-devel@lists.sourceforge.net\f1\par 38\pard\keep\keepn\nowidctlpar\s2\li-1440\sb400\sa60\sl-340\slmult0\cf1\b\f0\fs28 Files\par 39\pard\nowidctlpar\sb200\cf2\b0\fs18 None\par 40\pard\keep\keepn\nowidctlpar\s2\li-1440\sb400\sa60\sl-340\slmult0\cf1\b\fs28 See also\par 41\pard\nowidctlpar\sb200\cf2\b0\fs18 None\par 42\pard\keep\keepn\nowidctlpar\s2\li-1440\sb400\sa60\sl-340\slmult0\cf1\b\fs28 License\par 43\pard\nowidctlpar\cf2\b0\fs18 Copyright (c) 2010, Intel Corporation. All rights reserved.\par 44This program and the accompanying materials are licensed and made available \par 45under the terms and conditions of the BSD License which accompanies this \par 46distribution. The full text of the license may be found at\par 47http://opensource.org/licenses/bsd-license.php\par 48\par 49THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\par 50\pard\nowidctlpar\sb200 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\par 51\cf0\f1\par 52\pard\nowidctlpar\f2\fs20\par 53} 54