提交 f8aab62e 编写于 作者: M Marvin Häuser 提交者: Marvin Häuser

OcAfterBootCompatLib: Extend AllocRelocationBlock support

The current relocation code is only supported in conjunction with
ProvideCustomSlide. Add support for disabled ProvideCustomSlide and
slide=0 in boot-args.
上级 3d58e26a
......@@ -813,8 +813,7 @@ AppleSlideGetVariable (
FilterMapContext,
(BootCompat->CpuInfo->CpuGeneration == OcCpuGenerationSandyBridge)
|| (BootCompat->CpuInfo->CpuGeneration == OcCpuGenerationIvyBridge)
)
&& !BootCompat->ServiceState.AppleCustomSlide)
))
{
//
// When we cannot allow some KASLR values due to used address we generate
......
......@@ -1079,7 +1079,7 @@ OcGetVariable (
BootCompat = GetBootCompatContext ();
IsApple = BootCompat->ServiceState.AppleBootNestedCount > 0;
if (IsApple && BootCompat->Settings.ProvideCustomSlide) {
if (IsApple && (BootCompat->Settings.ProvideCustomSlide || BootCompat->Settings.AllowRelocationBlock)) {
Status = AppleSlideGetVariable (
BootCompat,
BootCompat->ServicePtrs.GetVariable,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册