mirror of
https://github.com/CloverHackyColor/CloverBootloader.git
synced 2024-11-23 11:35:19 +01:00
delegate fakecpuid to OC
Signed-off-by: SergeySlice <sergey.slice@gmail.com>
This commit is contained in:
parent
82ba60a90a
commit
23f0df20ed
@ -689,6 +689,9 @@ void debugStartImageWithOC()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
//const UINT32 standardMask[4] = {0xFF, 0xFF, 0xFF, 0xFF};
|
||||||
|
|
||||||
void LOADER_ENTRY::DelegateKernelPatches()
|
void LOADER_ENTRY::DelegateKernelPatches()
|
||||||
{
|
{
|
||||||
XObjArray<ABSTRACT_KEXT_OR_KERNEL_PATCH> selectedPathArray;
|
XObjArray<ABSTRACT_KEXT_OR_KERNEL_PATCH> selectedPathArray;
|
||||||
@ -708,6 +711,15 @@ void LOADER_ENTRY::DelegateKernelPatches()
|
|||||||
mOpenCoreConfiguration.Kernel.Patch.Values = (__typeof_am__(*mOpenCoreConfiguration.Kernel.Patch.Values)*)malloc(mOpenCoreConfiguration.Kernel.Patch.AllocCount*sizeof(__typeof_am__(*mOpenCoreConfiguration.Kernel.Patch.Values)));
|
mOpenCoreConfiguration.Kernel.Patch.Values = (__typeof_am__(*mOpenCoreConfiguration.Kernel.Patch.Values)*)malloc(mOpenCoreConfiguration.Kernel.Patch.AllocCount*sizeof(__typeof_am__(*mOpenCoreConfiguration.Kernel.Patch.Values)));
|
||||||
memset(mOpenCoreConfiguration.Kernel.Patch.Values, 0, mOpenCoreConfiguration.Kernel.Patch.AllocCount*sizeof(*mOpenCoreConfiguration.Kernel.Patch.Values));
|
memset(mOpenCoreConfiguration.Kernel.Patch.Values, 0, mOpenCoreConfiguration.Kernel.Patch.AllocCount*sizeof(*mOpenCoreConfiguration.Kernel.Patch.Values));
|
||||||
|
|
||||||
|
UINT32 FakeCPU = gSettings.KernelAndKextPatches.FakeCPUID;
|
||||||
|
// for (size_t Idx = 0; Idx < 4; Idx++) {
|
||||||
|
// mOpenCoreConfiguration.Kernel.Emulate.Cpuid1Data[Idx] = FakeCPU & 0xFF;
|
||||||
|
// mOpenCoreConfiguration.Kernel.Emulate.Cpuid1Mask[Idx] = 0xFF;
|
||||||
|
// FakeCPU >>= 8;
|
||||||
|
// }
|
||||||
|
mOpenCoreConfiguration.Kernel.Emulate.Cpuid1Data[0] = FakeCPU;
|
||||||
|
mOpenCoreConfiguration.Kernel.Emulate.Cpuid1Mask[0] = 0xFFFFFFFF;
|
||||||
|
|
||||||
for (size_t kextPatchIdx = 0 ; kextPatchIdx < selectedPathArray.size() ; kextPatchIdx++ )
|
for (size_t kextPatchIdx = 0 ; kextPatchIdx < selectedPathArray.size() ; kextPatchIdx++ )
|
||||||
{
|
{
|
||||||
const ABSTRACT_KEXT_OR_KERNEL_PATCH& kextPatch = selectedPathArray[kextPatchIdx]; //as well as kernel patches
|
const ABSTRACT_KEXT_OR_KERNEL_PATCH& kextPatch = selectedPathArray[kextPatchIdx]; //as well as kernel patches
|
||||||
|
Loading…
Reference in New Issue
Block a user