mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-25 06:34:30 +02:00
OvmfPkg/PlatformPei: NoExec: stop using mPlatformInfoHob
Stop using the mPlatformInfoHob global variable in NoexecDxeInitialization() function. Pass a pointer to the PlatformInfoHob instead. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Tested-by: Tom Lendacky <thomas.lendacky@amd.com> Acked-by: Ard Biesheuvel <ardb@kernel.org>
This commit is contained in:
parent
cc6efda777
commit
7dbb8a24d1
@ -75,16 +75,17 @@ MemMapInitialization (
|
|||||||
ASSERT_RETURN_ERROR (PcdStatus);
|
ASSERT_RETURN_ERROR (PcdStatus);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
STATIC
|
||||||
VOID
|
VOID
|
||||||
NoexecDxeInitialization (
|
NoexecDxeInitialization (
|
||||||
VOID
|
IN OUT EFI_HOB_PLATFORM_INFO *PlatformInfoHob
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
RETURN_STATUS Status;
|
RETURN_STATUS Status;
|
||||||
|
|
||||||
Status = PlatformNoexecDxeInitialization (&mPlatformInfoHob);
|
Status = PlatformNoexecDxeInitialization (PlatformInfoHob);
|
||||||
if (!RETURN_ERROR (Status)) {
|
if (!RETURN_ERROR (Status)) {
|
||||||
Status = PcdSetBoolS (PcdSetNxForStack, mPlatformInfoHob.PcdSetNxForStack);
|
Status = PcdSetBoolS (PcdSetNxForStack, PlatformInfoHob->PcdSetNxForStack);
|
||||||
ASSERT_RETURN_ERROR (Status);
|
ASSERT_RETURN_ERROR (Status);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -375,7 +376,7 @@ InitializePlatform (
|
|||||||
PeiFvInitialization (&mPlatformInfoHob);
|
PeiFvInitialization (&mPlatformInfoHob);
|
||||||
MemTypeInfoInitialization (&mPlatformInfoHob);
|
MemTypeInfoInitialization (&mPlatformInfoHob);
|
||||||
MemMapInitialization (&mPlatformInfoHob);
|
MemMapInitialization (&mPlatformInfoHob);
|
||||||
NoexecDxeInitialization ();
|
NoexecDxeInitialization (&mPlatformInfoHob);
|
||||||
}
|
}
|
||||||
|
|
||||||
InstallClearCacheCallback ();
|
InstallClearCacheCallback ();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user