Skip to content

Commit 88ada4d

Browse files
Utilities: Assigned default values to PcdUefiImageFormatSupportNonFv
and PcdImageProtectionPolicy, adjusted Policy in tools.
1 parent 0a62573 commit 88ada4d

File tree

3 files changed

+13
-2
lines changed

3 files changed

+13
-2
lines changed

User/Library/UserPcd.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,6 @@ UINT32 _gPcd_FixedAtBuild_PcdImageLoaderAlignmentPolicy = 0xFFFFFFF
4848
UINT32 _gPcd_FixedAtBuild_PcdImageLoaderRelocTypePolicy = 0x00;
4949
BOOLEAN _gPcd_FeatureFlag_PcdFatReadOnlyMode = _PCD_VALUE_PcdFatReadOnlyMode;
5050
UINT32 _gPcd_BinaryPatch_PcdSerialRegisterStride = 0;
51-
UINT8 _gPcd_FixedAtBuild_PcdUefiImageFormatSupportNonFv = 0x00;
51+
UINT8 _gPcd_FixedAtBuild_PcdUefiImageFormatSupportNonFv = 0x02;
5252
UINT8 _gPcd_FixedAtBuild_PcdUefiImageFormatSupportFv = 0x03;
53-
UINT32 _gPcd_FixedAtBuild_PcdImageProtectionPolicy = 0x00;
53+
UINT32 _gPcd_FixedAtBuild_PcdImageProtectionPolicy = 0x07;

Utilities/AppleEfiSignTool/AppleEfiSignTool.c

+6
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,12 @@ ENTRY_POINT (
189189
PcdGet32 (PcdFixedDebugPrintErrorLevel) |= DEBUG_INFO;
190190
PcdGet32 (PcdDebugPrintErrorLevel) |= DEBUG_INFO;
191191

192+
//
193+
// Match PcdImageProtectionPolicy defined in OpenCore.dsc.
194+
// Apple images (supplied by user) may be not 4KBi aligned.
195+
//
196+
PcdGet32 (PcdImageProtectionPolicy) = 0x03;
197+
192198
//
193199
// Process args or print usage.
194200
//

Utilities/TestPeCoff/PeCoff.c

+5
Original file line numberDiff line numberDiff line change
@@ -291,6 +291,11 @@ ENTRY_POINT (
291291
PcdGet32 (PcdFixedDebugPrintErrorLevel) |= DEBUG_INFO;
292292
PcdGet32 (PcdDebugPrintErrorLevel) |= DEBUG_INFO;
293293

294+
//
295+
// Images may be not 4KBi aligned.
296+
//
297+
PcdGet32 (PcdImageProtectionPolicy) = 0x00;
298+
294299
// PcdGet32 (PcdFixedDebugPrintErrorLevel) |= DEBUG_POOL | DEBUG_PAGE;
295300
// PcdGet32 (PcdDebugPrintErrorLevel) |= DEBUG_POOL | DEBUG_PAGE;
296301

0 commit comments

Comments
 (0)