diff --git a/Docs/Configuration.md5 b/Docs/Configuration.md5 index d6fa0766..548dc736 100644 --- a/Docs/Configuration.md5 +++ b/Docs/Configuration.md5 @@ -1 +1 @@ -d703ad2d2bc0f97fe7345a763dc75fed +5dd7f2718a1f622cca8c8a90ba866915 diff --git a/Docs/Configuration.pdf b/Docs/Configuration.pdf index 513f4ca9..7d972e4a 100644 Binary files a/Docs/Configuration.pdf and b/Docs/Configuration.pdf differ diff --git a/Docs/Configuration.tex b/Docs/Configuration.tex index 0aa2e372..f2273438 100755 --- a/Docs/Configuration.tex +++ b/Docs/Configuration.tex @@ -2274,7 +2274,7 @@ blocking. \texttt{DummyPowerManagement}\\ \textbf{Type}: \texttt{plist\ boolean}\\ \textbf{Failsafe}: \texttt{false}\\ - \textbf{Requirement}: 10.4\\ + \textbf{Requirement}: 10.4-12\\ \textbf{Description}: Disables \texttt{AppleIntelCpuPowerManagement}. \emph{Note 1}: This option is a preferred alternative to @@ -2486,7 +2486,7 @@ blocking. \texttt{AppleCpuPmCfgLock}\\ \textbf{Type}: \texttt{plist\ boolean}\\ \textbf{Failsafe}: \texttt{false}\\ - \textbf{Requirement}: 10.4\\ + \textbf{Requirement}: 10.4-12\\ \textbf{Description}: Disables \texttt{PKG\_CST\_CONFIG\_CONTROL} (\texttt{0xE2}) MSR modification in AppleIntelCPUPowerManagement.kext, commonly causing early kernel panic, when it is locked from writing. diff --git a/Docs/Differences/Differences.pdf b/Docs/Differences/Differences.pdf index ed293c24..4a257df0 100644 Binary files a/Docs/Differences/Differences.pdf and b/Docs/Differences/Differences.pdf differ diff --git a/Docs/Differences/Differences.tex b/Docs/Differences/Differences.tex index a243e01e..b4509cb6 100644 --- a/Docs/Differences/Differences.tex +++ b/Docs/Differences/Differences.tex @@ -1,7 +1,7 @@ \documentclass[]{article} %DIF LATEXDIFF DIFFERENCE FILE %DIF DEL PreviousConfiguration.tex Tue Jun 7 04:41:41 2022 -%DIF ADD ../Configuration.tex Tue Jun 7 04:41:41 2022 +%DIF ADD ../Configuration.tex Tue Jun 7 04:58:18 2022 \usepackage{lmodern} \usepackage{amssymb,amsmath} @@ -2334,7 +2334,7 @@ blocking. \texttt{DummyPowerManagement}\\ \textbf{Type}: \texttt{plist\ boolean}\\ \textbf{Failsafe}: \texttt{false}\\ - \textbf{Requirement}: 10.4\\ + \textbf{Requirement}: 10.4\DIFaddbegin \DIFadd{-12}\DIFaddend \\ \textbf{Description}: Disables \texttt{AppleIntelCpuPowerManagement}. \emph{Note 1}: This option is a preferred alternative to @@ -2546,7 +2546,7 @@ blocking. \texttt{AppleCpuPmCfgLock}\\ \textbf{Type}: \texttt{plist\ boolean}\\ \textbf{Failsafe}: \texttt{false}\\ - \textbf{Requirement}: 10.4\\ + \textbf{Requirement}: 10.4\DIFaddbegin \DIFadd{-12}\DIFaddend \\ \textbf{Description}: Disables \texttt{PKG\_CST\_CONFIG\_CONTROL} (\texttt{0xE2}) MSR modification in AppleIntelCPUPowerManagement.kext, commonly causing early kernel panic, when it is locked from writing. diff --git a/Docs/Errata/Errata.pdf b/Docs/Errata/Errata.pdf index 6346c8a6..c2ca4429 100644 Binary files a/Docs/Errata/Errata.pdf and b/Docs/Errata/Errata.pdf differ diff --git a/Include/Acidanthera/Library/OcAppleKernelLib.h b/Include/Acidanthera/Library/OcAppleKernelLib.h index 3acbb9cd..f91574ab 100644 --- a/Include/Acidanthera/Library/OcAppleKernelLib.h +++ b/Include/Acidanthera/Library/OcAppleKernelLib.h @@ -123,6 +123,7 @@ typedef enum KERNEL_CACHE_TYPE_ { #define KERNEL_VERSION_CATALINA 19 #define KERNEL_VERSION_BIG_SUR 20 #define KERNEL_VERSION_MONTEREY 21 +#define KERNEL_VERSION_VENTURA 22 // // Minimum kernel versions for each release. @@ -141,6 +142,7 @@ typedef enum KERNEL_CACHE_TYPE_ { #define KERNEL_VERSION_CATALINA_MIN KERNEL_VERSION (KERNEL_VERSION_CATALINA, 0, 0) #define KERNEL_VERSION_BIG_SUR_MIN KERNEL_VERSION (KERNEL_VERSION_BIG_SUR, 0, 0) #define KERNEL_VERSION_MONTEREY_MIN KERNEL_VERSION (KERNEL_VERSION_MONTEREY, 0, 0) +#define KERNEL_VERSION_VENTURA_MIN KERNEL_VERSION (KERNEL_VERSION_VENTURA, 0, 0) // // Maximum kernel versions for each release. @@ -158,6 +160,7 @@ typedef enum KERNEL_CACHE_TYPE_ { #define KERNEL_VERSION_MOJAVE_MAX (KERNEL_VERSION_CATALINA_MIN - 1) #define KERNEL_VERSION_CATALINA_MAX (KERNEL_VERSION_BIG_SUR_MIN - 1) #define KERNEL_VERSION_BIG_SUR_MAX (KERNEL_VERSION_MONTEREY_MIN - 1) +#define KERNEL_VERSION_MONTEREY_MAX (KERNEL_VERSION_VENTURA_MIN - 1) // // Prelinked context used for kernel modification. diff --git a/Library/OcAppleKernelLib/CommonPatches.c b/Library/OcAppleKernelLib/CommonPatches.c index 689dcbde..4ad3aa32 100644 --- a/Library/OcAppleKernelLib/CommonPatches.c +++ b/Library/OcAppleKernelLib/CommonPatches.c @@ -60,6 +60,11 @@ PatchAppleCpuPmCfgLock ( UINT8 *WalkerEnd; UINT8 *WalkerTmp; + if (OcMatchDarwinVersion (KernelVersion, KERNEL_VERSION_VENTURA_MIN, 0)) { + DEBUG ((DEBUG_INFO, "OCAK: Skipping AppleCpuPmCfgLock patch on %u\n", KernelVersion)); + return EFI_SUCCESS; + } + ASSERT (Patcher != NULL); Count = 0; @@ -977,6 +982,11 @@ PatchDummyPowerManagement ( { EFI_STATUS Status; + if (OcMatchDarwinVersion (KernelVersion, KERNEL_VERSION_VENTURA_MIN, 0)) { + DEBUG ((DEBUG_INFO, "OCAK: Skipping dummy AppleIntelCPUPowerManagement patch on %u\n", KernelVersion)); + return EFI_SUCCESS; + } + ASSERT (Patcher != NULL); Status = PatcherApplyGenericPatch (Patcher, &mAppleDummyCpuPmPatch);