System hang by loading FmpDxexxx.efi.

Hi all,

I built FmpDevicePkg in tianocore/edk2. Then, I load FmpDxexxx.eif in 
EmulatorX64 and Minnow Board. It both crashed. I traced the code and found out 
it hang at follows:

1. PcdGetBool (PcdTestKeyUsed);

2. PcdSetBoolS (PcdTestKeyUsed, TRUE);

Detail as follows:

\edk2\FmpDevicePkg\FmpDxe\ DetectTestKey.c

DetectTestKey (

VOID

)

{

….

// If PcdTestKeyUsed is already TRUE, then skip test key detection

//

TestKeyUsed = PcdGetBool (PcdTestKeyUsed);  --> system hang

..

// If test key detected or an error occurred checking for the test key, then

// set PcdTestKeyUsed to TRUE.

//

if (TestKeyUsed) {

DEBUG ((DEBUG_INFO, "FmpDxe(%s): Test key detected in 
PcdFmpDevicePkcs7CertBufferXdr.\n", mImageIdName));

PcdSetBoolS (PcdTestKeyUsed, TRUE); --> system hang

I modified \MdeModulePkg\MdeModulePkg.dec from

[PcdsDynamic, PcdsDynamicEx]

gEfiMdeModulePkgTokenSpaceGuid.PcdTestKeyUsed|FALSE|BOOLEAN|0x00030003

as below:

[PcdsPatchableInModule, PcdsDynamic, PcdsDynamicEx]

gEfiMdeModulePkgTokenSpaceGuid.PcdTestKeyUsed|FALSE|BOOLEAN|0x00030003

It worked fine.

Is it a bug of edk2?


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#90080): https://edk2.groups.io/g/devel/message/90080
Mute This Topic: https://groups.io/mt/91371076/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to