mirror of
https://github.com/outbackdingo/OpCore-Simplify.git
synced 2026-01-27 10:19:49 +00:00
Update CPU generation and motherboard chipset info
This commit is contained in:
@@ -1571,7 +1571,7 @@ DefinitionBlock ("", "SSDT", 2, "ZPSS", "MCHC", 0)
|
||||
|
||||
def add_system_management_bus_device(self):
|
||||
try:
|
||||
smbus_device_name = self.acpi.get_device_paths_with_hid("0x001F0003" if self.utils.contains_any(cpu_data.IntelCPUGenerations, self.hardware_report.get("CPU").get("CPU Codename"), end=4) else "0x001F0004", self.dsdt)[0][0].split(".")[-1]
|
||||
smbus_device_name = self.acpi.get_device_paths_with_hid("0x001F0003" if self.utils.contains_any(cpu_data.IntelCPUGenerations, self.hardware_report.get("CPU").get("CPU Codename"), start=26) else "0x001F0004", self.dsdt)[0][0].split(".")[-1]
|
||||
except:
|
||||
smbus_device_name = "SBUS"
|
||||
|
||||
@@ -1846,11 +1846,11 @@ DefinitionBlock ("", "SSDT", 2, "ZPSS", "DNVMe", 0x00000000)
|
||||
patches = []
|
||||
|
||||
uid_value = 19
|
||||
if self.utils.contains_any(cpu_data.IntelCPUGenerations, self.hardware_report.get("CPU").get("CPU Codename"), end=2):
|
||||
if self.utils.contains_any(cpu_data.IntelCPUGenerations, self.hardware_report.get("CPU").get("CPU Codename"), start=38):
|
||||
uid_value = 14
|
||||
elif self.utils.contains_any(cpu_data.IntelCPUGenerations, self.hardware_report.get("CPU").get("CPU Codename"), start=2, end=4):
|
||||
elif self.utils.contains_any(cpu_data.IntelCPUGenerations, self.hardware_report.get("CPU").get("CPU Codename"), start=26):
|
||||
uid_value = 15
|
||||
elif self.utils.contains_any(cpu_data.IntelCPUGenerations, self.hardware_report.get("CPU").get("CPU Codename"), start=4, end=7):
|
||||
elif self.utils.contains_any(cpu_data.IntelCPUGenerations, self.hardware_report.get("CPU").get("CPU Codename"), start=16):
|
||||
uid_value = 16
|
||||
|
||||
igpu = ""
|
||||
@@ -2214,8 +2214,7 @@ DefinitionBlock("", "SSDT", 2, "ZPSS", "RMNE", 0x00001000)
|
||||
}
|
||||
|
||||
def is_intel_hedt_cpu(self, cpu_codename):
|
||||
return "-E" in cpu_codename and not self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, end=4) is None or \
|
||||
("-X" in cpu_codename or "-W" in cpu_codename) and not self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, start=4, end=6) is None
|
||||
return not self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, start=21) is None and cpu_codename.endswith(("-X", "-P", "-W", "-E", "-EP", "-EX"))
|
||||
|
||||
def fix_system_clock_hedt(self):
|
||||
if not self.lpc_bus_device:
|
||||
@@ -2843,7 +2842,7 @@ DefinitionBlock ("", "SSDT", 2, "ZPSS", "SURFACE", 0x00001000)
|
||||
if "HP" in hardware_report.get("Motherboard").get("Motherboard Name"):
|
||||
selected_patches.append("CMOS")
|
||||
|
||||
if "Laptop" in hardware_report.get("Motherboard").get("Platform") and self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=4) or \
|
||||
if "Laptop" in hardware_report.get("Motherboard").get("Platform") and self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=26) or \
|
||||
self.is_intel_hedt_cpu(hardware_report.get("CPU").get("CPU Codename")):
|
||||
selected_patches.append("FixHPET")
|
||||
|
||||
@@ -2855,7 +2854,7 @@ DefinitionBlock ("", "SSDT", 2, "ZPSS", "SURFACE", 0x00001000)
|
||||
if "Intel" in hardware_report.get("CPU").get("CPU Manufacturer") or not "MacPro" in smbios_model:
|
||||
selected_patches.append("MCHC")
|
||||
|
||||
if self.utils.contains_any(chipset_data.IntelChipsets, hardware_report.get("Motherboard").get("Motherboard Chipset"), start=85, end=97):
|
||||
if self.utils.contains_any(chipset_data.IntelChipsets, hardware_report.get("Motherboard").get("Motherboard Chipset"), start=89, end=101):
|
||||
selected_patches.append("PMC")
|
||||
|
||||
if "Sandy Bridge" in hardware_report.get("CPU").get("CPU Codename") or "Ivy Bridge" in hardware_report.get("CPU").get("CPU Codename"):
|
||||
@@ -2877,7 +2876,7 @@ DefinitionBlock ("", "SSDT", 2, "ZPSS", "SURFACE", 0x00001000)
|
||||
if hardware_report.get("Motherboard").get("Motherboard Chipset") in ("C610/X99", "Wellsburg", "X299"):
|
||||
selected_patches.append("RTC0")
|
||||
|
||||
if self.utils.contains_any(chipset_data.IntelChipsets, hardware_report.get("Motherboard").get("Motherboard Chipset"), start=85):
|
||||
if self.utils.contains_any(chipset_data.IntelChipsets, hardware_report.get("Motherboard").get("Motherboard Chipset"), start=89):
|
||||
selected_patches.append("RTCAWAC")
|
||||
|
||||
selected_patches.append("PRW")
|
||||
|
||||
@@ -52,7 +52,7 @@ class CompatibilityChecker:
|
||||
elif "Amber Lake" in gpu_codename or "Whiskey Lake" in gpu_codename:
|
||||
self.min_supported_macos_version = max((17, 0, 0), self.min_supported_macos_version if is_supported_discrete_gpu else (-1, -1, -1))
|
||||
self.max_supported_macos_version = self.utils.parse_darwin_version(os_data.get_latest_darwin_version())
|
||||
elif not is_supported_discrete_gpu and "Comet Lake" in gpu_codename and self.utils.contains_any(chipset_data.IntelChipsets, motherboard_chipset, start=110, end=122):
|
||||
elif not is_supported_discrete_gpu and "Comet Lake" in gpu_codename and self.utils.contains_any(chipset_data.IntelChipsets, motherboard_chipset, start=116, end=130):
|
||||
self.max_supported_macos_version = self.min_supported_macos_version = (-1, -1, -1)
|
||||
elif "Ice Lake" in gpu_codename:
|
||||
self.min_supported_macos_version = max((19, 4, 0), self.min_supported_macos_version)
|
||||
|
||||
@@ -62,11 +62,12 @@ class ConfigProdigy:
|
||||
|
||||
def check_mats_support(self, cpu_manufacturer, motherboard_chipset):
|
||||
return "AMD" in cpu_manufacturer or \
|
||||
not self.utils.contains_any(chipset_data.IntelChipsets, motherboard_chipset, start=97) is None or \
|
||||
not self.utils.contains_any(chipset_data.IntelChipsets, motherboard_chipset, start=49, end=60) is None
|
||||
not self.utils.contains_any(chipset_data.IntelChipsets, motherboard_chipset, start=101) is None or \
|
||||
not self.utils.contains_any(chipset_data.IntelChipsets, motherboard_chipset, start=79, end=89) is None
|
||||
|
||||
def check_resizable_bar_support(self, motherboard_chipset, cpu_codename):
|
||||
return not self.utils.contains_any(chipset_data.AMDChipsets, motherboard_chipset) is None or not self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, start=10) is None
|
||||
return not self.utils.contains_any(chipset_data.AMDChipsets, motherboard_chipset, start=11) is None or \
|
||||
not "Ice Lake" in motherboard_chipset and not self.utils.contains_any(chipset_data, motherboard_chipset, start=101) is None
|
||||
|
||||
def is_low_end_intel_cpu(self, processor_name):
|
||||
return any(cpu_branding in processor_name for cpu_branding in ["Celeron", "Pentium"])
|
||||
@@ -112,11 +113,10 @@ class ConfigProdigy:
|
||||
return kernel_block
|
||||
|
||||
def is_low_end_haswell_plus(self, processor_name, cpu_codename):
|
||||
return self.is_low_end_intel_cpu(processor_name) and not self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, start=2) is None
|
||||
return self.is_low_end_intel_cpu(processor_name) and not self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, end=38) is None
|
||||
|
||||
def is_intel_hedt_cpu(self, cpu_codename):
|
||||
return "-E" in cpu_codename and not self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, end=4) is None or \
|
||||
("-X" in cpu_codename or "-W" in cpu_codename) and not self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, start=4, end=6) is None
|
||||
return not self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, start=21) is None and cpu_codename.endswith(("-X", "-P", "-W", "-E", "-EP", "-EX"))
|
||||
|
||||
def spoof_cpuid(self, processor_name, cpu_codename, macos_version):
|
||||
if self.is_low_end_haswell_plus(processor_name, cpu_codename):
|
||||
@@ -125,7 +125,7 @@ class ConfigProdigy:
|
||||
return self.cpuids.get("Haswell")
|
||||
elif "Broadwell" in cpu_codename and self.is_intel_hedt_cpu(cpu_codename):
|
||||
return self.cpuids.get("Broadwell")
|
||||
elif "Ice Lake" not in cpu_codename and self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, start=10):
|
||||
elif "Ice Lake" not in cpu_codename and self.utils.contains_any(cpu_data.IntelCPUGenerations, cpu_codename, end=10):
|
||||
if not "Comet Lake" in cpu_codename:
|
||||
return self.cpuids.get("Comet Lake")
|
||||
if self.utils.parse_darwin_version(macos_version) < self.utils.parse_darwin_version("19.0.0"):
|
||||
@@ -166,10 +166,10 @@ class ConfigProdigy:
|
||||
patch["Replace"] = patch["Replace"].hex()
|
||||
patch["Replace"] = self.utils.hex_to_bytes(patch["Replace"][:2] + self.utils.int_to_hex(int(cpu_cores)) + patch["Replace"][4:])
|
||||
elif "IOPCIIsHotplugPort" in patch["Comment"]:
|
||||
if self.utils.contains_any(chipset_data.AMDChipsets, motherboard_chipset, start=6):
|
||||
if self.utils.contains_any(chipset_data.AMDChipsets, motherboard_chipset, start=17):
|
||||
patch["Enabled"] = True
|
||||
if "_mtrr_update_action" in patch["Comment"]:
|
||||
if chipset_data.AMDChipsets[0].lower() in motherboard_chipset.lower():
|
||||
if "TRX" in motherboard_chipset.upper():
|
||||
patch["Enabled"] = False
|
||||
elif "AMD" in gpu_manufacturer:
|
||||
if "algrey" in patch["Comment"].lower():
|
||||
@@ -195,9 +195,9 @@ class ConfigProdigy:
|
||||
|
||||
if self.utils.parse_darwin_version(macos_version) >= self.utils.parse_darwin_version("23.0.0"):
|
||||
boot_args.append("revpatch=sbvmm{}".format(",cpuname" if not (" Core" in hardware_report.get("CPU").get("Processor Name") and \
|
||||
self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=12)) else ""))
|
||||
self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=3)) else ""))
|
||||
|
||||
if self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=13) and int(hardware_report.get("CPU").get("CPU Cores")) > 6:
|
||||
if self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=2) and int(hardware_report.get("CPU").get("CPU Cores")) > 6:
|
||||
boot_args.append("-ctrsmt")
|
||||
|
||||
if "Intel" in hardware_report.get("CPU").get("CPU Manufacturer"):
|
||||
@@ -208,7 +208,7 @@ class ConfigProdigy:
|
||||
boot_args.extend(["-noDC9", "-igfxcdc", "-igfxdvmt", "-igfxdbeo"])
|
||||
|
||||
if "Laptop" in hardware_report.get("Motherboard").get("Platform"):
|
||||
if self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=6):
|
||||
if self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=21):
|
||||
boot_args.append("-igfxbl{}".format("t" if self.utils.parse_darwin_version(macos_version) >= self.utils.parse_darwin_version("23.0.0") else "r"))
|
||||
|
||||
if "Navi 1" in list(hardware_report.get("GPU").items())[-1][-1].get("GPU Codename"):
|
||||
@@ -276,13 +276,10 @@ class ConfigProdigy:
|
||||
config["Booter"]["Quirks"]["DevirtualiseMmio"] = False
|
||||
config["Booter"]["Quirks"]["EnableWriteUnprotector"] = False if "AMD" in hardware_report.get("CPU").get("CPU Manufacturer") else not config["Booter"]["Quirks"]["DevirtualiseMmio"]
|
||||
config["Booter"]["Quirks"]["ProtectUefiServices"] = "Z390" in hardware_report.get("Motherboard").get("Motherboard Chipset") or \
|
||||
not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=10) is None
|
||||
not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=14) is None
|
||||
config["Booter"]["Quirks"]["RebuildAppleMemoryMap"] = not config["Booter"]["Quirks"]["EnableWriteUnprotector"]
|
||||
config["Booter"]["Quirks"]["ResizeAppleGpuBars"] = 0 if self.check_resizable_bar_support(
|
||||
hardware_report.get("Motherboard").get("Motherboard Chipset"),
|
||||
hardware_report.get("CPU").get("CPU Codename")
|
||||
) else -1
|
||||
config["Booter"]["Quirks"]["SetupVirtualMap"] = not (not self.utils.contains_any(chipset_data.AMDChipsets, hardware_report.get("Motherboard").get("Motherboard Chipset"), end=5) is None or \
|
||||
config["Booter"]["Quirks"]["ResizeAppleGpuBars"] = 0 if self.check_resizable_bar_support(hardware_report.get("Motherboard").get("Motherboard Chipset")) else -1
|
||||
config["Booter"]["Quirks"]["SetupVirtualMap"] = not (not self.utils.contains_any(chipset_data.AMDChipsets, hardware_report.get("Motherboard").get("Motherboard Chipset"), start=11, end=17) is None or \
|
||||
"ASUS" in hardware_report.get("Motherboard").get("Motherboard Name") and self.is_intel_hedt_cpu(hardware_report.get("CPU").get("CPU Codename")) and config["Booter"]["Quirks"]["DevirtualiseMmio"])
|
||||
config["Booter"]["Quirks"]["SyncRuntimePermissions"] = config["Booter"]["Quirks"]["RebuildAppleMemoryMap"]
|
||||
|
||||
@@ -310,16 +307,16 @@ class ConfigProdigy:
|
||||
list(hardware_report.get("GPU").items())[-1][-1].get("Manufacturer"),
|
||||
kexts
|
||||
)
|
||||
config["Kernel"]["Quirks"]["AppleCpuPmCfgLock"] = not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=2) is None
|
||||
config["Kernel"]["Quirks"]["AppleCpuPmCfgLock"] = not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=38) is None
|
||||
config["Kernel"]["Quirks"]["AppleXcpmCfgLock"] = False if "AMD" in hardware_report.get("CPU").get("CPU Manufacturer") else not config["Kernel"]["Quirks"]["AppleCpuPmCfgLock"]
|
||||
config["Kernel"]["Quirks"]["AppleXcpmExtraMsrs"] = self.is_intel_hedt_cpu(hardware_report.get("CPU").get("CPU Codename")) and not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=4) is None
|
||||
config["Kernel"]["Quirks"]["AppleXcpmExtraMsrs"] = "-E" in hardware_report.get("CPU").get("CPU Codename") and not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=26) is None
|
||||
config["Kernel"]["Quirks"]["CustomSMBIOSGuid"] = True
|
||||
config["Kernel"]["Quirks"]["DisableIoMapper"] = not "AMD" in hardware_report.get("CPU").get("CPU Manufacturer")
|
||||
config["Kernel"]["Quirks"]["DisableRtcChecksum"] = "ASUS" in hardware_report.get("Motherboard").get("Motherboard Name") or "HP" in hardware_report.get("Motherboard").get("Motherboard Name")
|
||||
config["Kernel"]["Quirks"]["LapicKernelPanic"] = "HP" in hardware_report.get("Motherboard").get("Motherboard Name")
|
||||
config["Kernel"]["Quirks"]["PanicNoKextDump"] = config["Kernel"]["Quirks"]["PowerTimeoutKernelPanic"] = True
|
||||
config["Kernel"]["Quirks"]["ProvideCurrentCpuInfo"] = "AMD" in hardware_report.get("CPU").get("CPU Manufacturer") or \
|
||||
not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=13) is None
|
||||
not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=2) is None
|
||||
|
||||
config["Misc"]["BlessOverride"] = []
|
||||
config["Misc"]["Boot"]["HideAuxiliary"] = False
|
||||
@@ -348,13 +345,13 @@ class ConfigProdigy:
|
||||
|
||||
config["UEFI"]["APFS"]["MinDate"] = config["UEFI"]["APFS"]["MinVersion"] = -1
|
||||
config["UEFI"]["Drivers"] = self.load_drivers()
|
||||
config["UEFI"]["Quirks"]["IgnoreInvalidFlexRatio"] = not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=4) is None
|
||||
config["UEFI"]["Quirks"]["IgnoreInvalidFlexRatio"] = not self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=26) is None
|
||||
config["UEFI"]["Quirks"]["ReleaseUsbOwnership"] = True
|
||||
config["UEFI"]["Quirks"]["UnblockFsConnect"] = "HP" in hardware_report.get("Motherboard").get("Motherboard Name")
|
||||
config["UEFI"]["ReservedMemory"] = []
|
||||
|
||||
if not (" Core" in hardware_report.get("CPU").get("Processor Name") and \
|
||||
self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=12)):
|
||||
self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=3)):
|
||||
config["NVRAM"]["Add"]["4D1FDA02-38C7-4A6A-9CC6-4BCCA8B30102"]["revcpu"] = 1
|
||||
config["NVRAM"]["Add"]["4D1FDA02-38C7-4A6A-9CC6-4BCCA8B30102"]["revcpuname"] = hardware_report.get("CPU").get("Processor Name")
|
||||
config["NVRAM"]["Delete"]["4D1FDA02-38C7-4A6A-9CC6-4BCCA8B30102"].extend(["revcpu", "revcpuname"])
|
||||
|
||||
252
Scripts/datasets/chipset_data.py
Executable file → Normal file
252
Scripts/datasets/chipset_data.py
Executable file → Normal file
@@ -1,56 +1,83 @@
|
||||
# Resource: https://en.wikipedia.org/wiki/List_of_Intel_chipsets
|
||||
IntelChipsets = [
|
||||
"H61",
|
||||
"B65",
|
||||
"Q65",
|
||||
"P67",
|
||||
"H67",
|
||||
"Q67",
|
||||
"Z68",
|
||||
"HM65",
|
||||
"HM67",
|
||||
"UM67",
|
||||
"QM67",
|
||||
"QS67",
|
||||
"Cougar Point",
|
||||
"B75",
|
||||
"Q75",
|
||||
"Z75",
|
||||
"H77",
|
||||
"Q77",
|
||||
"Z68",
|
||||
"P67",
|
||||
"UM67",
|
||||
"HM65",
|
||||
"H67",
|
||||
"HM67",
|
||||
"Q65",
|
||||
"QS67",
|
||||
"Q67",
|
||||
"QM67",
|
||||
"B65",
|
||||
"C202",
|
||||
"C204",
|
||||
"C206",
|
||||
"H61",
|
||||
"C600/X79",
|
||||
"Panther Point",
|
||||
"Z77",
|
||||
"Z75",
|
||||
"Q77",
|
||||
"Q75",
|
||||
"B75",
|
||||
"H77",
|
||||
"C216",
|
||||
"NM70",
|
||||
"HM70",
|
||||
"HM75",
|
||||
"HM76",
|
||||
"UM77",
|
||||
"HM77",
|
||||
"QM77",
|
||||
"QS77",
|
||||
"X79",
|
||||
"C602",
|
||||
"Panther Point",
|
||||
"Patsburg",
|
||||
"H81",
|
||||
"B85",
|
||||
"HM77",
|
||||
"UM77",
|
||||
"HM76",
|
||||
"HM75",
|
||||
"HM70",
|
||||
"NM70",
|
||||
"Lynx Point",
|
||||
"Z87",
|
||||
"Z85",
|
||||
"HM86",
|
||||
"H87",
|
||||
"HM87",
|
||||
"Q85",
|
||||
"Q87",
|
||||
"H87",
|
||||
"Z87",
|
||||
"HM86",
|
||||
"QM87",
|
||||
"HM87",
|
||||
"Lynx Point",
|
||||
"H97",
|
||||
"Z97",
|
||||
"HM97",
|
||||
"C612",
|
||||
"X99",
|
||||
"Wildcat Point",
|
||||
"B85",
|
||||
"C222",
|
||||
"C224",
|
||||
"C226",
|
||||
"H81",
|
||||
"Wellsburg",
|
||||
"X299",
|
||||
"C422",
|
||||
"HM97",
|
||||
"Z97",
|
||||
"QM97",
|
||||
"H97",
|
||||
"C610/X99",
|
||||
"Wildcat Point-LP",
|
||||
"Sunrise Point-LP",
|
||||
"Sunrise Point",
|
||||
"Sunrise Point-H",
|
||||
"H110",
|
||||
"H170",
|
||||
"Z170",
|
||||
"Q170",
|
||||
"Q150",
|
||||
"B150",
|
||||
"C236",
|
||||
"C232",
|
||||
"QM170",
|
||||
"HM170",
|
||||
"CM236",
|
||||
"QMS180",
|
||||
"HM175",
|
||||
"QM175",
|
||||
"CM238",
|
||||
"QMU185",
|
||||
"H270",
|
||||
"Z270",
|
||||
"Q270",
|
||||
"Q250",
|
||||
"B250",
|
||||
"B365",
|
||||
"C621",
|
||||
"C622",
|
||||
"C624",
|
||||
@@ -58,104 +85,103 @@ IntelChipsets = [
|
||||
"C626",
|
||||
"C627",
|
||||
"C628",
|
||||
"Basin Falls",
|
||||
"X299",
|
||||
"C422",
|
||||
"Lewisburg",
|
||||
"H110",
|
||||
"B150",
|
||||
"Q150",
|
||||
"H170",
|
||||
"Q170",
|
||||
"Z170",
|
||||
"HM170",
|
||||
"QM170",
|
||||
"QMS180",
|
||||
"QMU185",
|
||||
"HM175",
|
||||
"QM175",
|
||||
"B250",
|
||||
"Q250",
|
||||
"H270",
|
||||
"Q270",
|
||||
"Z270",
|
||||
"C232",
|
||||
"C236",
|
||||
"CM236",
|
||||
"CM238",
|
||||
"B365",
|
||||
"Sunrise Point",
|
||||
"Kaby Point",
|
||||
"Union Point",
|
||||
"Z370",
|
||||
"H310",
|
||||
"B360",
|
||||
"H370",
|
||||
"Q370",
|
||||
"Z390",
|
||||
"C242",
|
||||
"Cannon Point-LP",
|
||||
"C246",
|
||||
"HM370",
|
||||
"B360",
|
||||
"C242",
|
||||
"QM370",
|
||||
"HM370",
|
||||
"CM246",
|
||||
"Cannon Point",
|
||||
"H410",
|
||||
"B460",
|
||||
"H470",
|
||||
"Q470",
|
||||
"Z490",
|
||||
"W480",
|
||||
"H420E",
|
||||
"Q470E",
|
||||
"W480E",
|
||||
"H310",
|
||||
"H370",
|
||||
"Z390",
|
||||
"Q370",
|
||||
"Z370",
|
||||
"Comet Lake",
|
||||
"HM470",
|
||||
"H310D",
|
||||
"H470",
|
||||
"Z490",
|
||||
"Q470",
|
||||
"QM480",
|
||||
"WM490",
|
||||
"Comet Point",
|
||||
"H510",
|
||||
"B560",
|
||||
"H570",
|
||||
"Z590",
|
||||
"W580",
|
||||
"HM570E",
|
||||
"QM580E",
|
||||
"RM590E",
|
||||
"HM570",
|
||||
"QM580",
|
||||
"WM590",
|
||||
"Tiger Point",
|
||||
"495",
|
||||
"Ice Point",
|
||||
"W480",
|
||||
"H420E",
|
||||
"Ice Lake-LP",
|
||||
"Ice Lake",
|
||||
"Z690",
|
||||
"W680",
|
||||
"B460",
|
||||
"H410",
|
||||
"QM580E",
|
||||
"Rocket Lake",
|
||||
"Q570",
|
||||
"Z590",
|
||||
"H570",
|
||||
"B560",
|
||||
"H510",
|
||||
"WM590",
|
||||
"QM580",
|
||||
"HM570",
|
||||
"C252",
|
||||
"C256",
|
||||
"W580",
|
||||
"RM590E",
|
||||
"R580E",
|
||||
"Tiger Lake-LP",
|
||||
"Gemini Lake",
|
||||
"Elkhart Lake",
|
||||
"Jasper Lake",
|
||||
"Alder Lake",
|
||||
"Alder Lake-N",
|
||||
"Q670",
|
||||
"Z690",
|
||||
"H670",
|
||||
"B660",
|
||||
"H610",
|
||||
"W680",
|
||||
"HM670",
|
||||
"WM690",
|
||||
"R680E",
|
||||
"Q670E",
|
||||
"H610E",
|
||||
"HM670",
|
||||
"WM690",
|
||||
"Alder Point",
|
||||
"Raptor Lake-P",
|
||||
"Raptor Lake-PX",
|
||||
"Z790",
|
||||
"H770",
|
||||
"B760",
|
||||
"HM770",
|
||||
"WM790",
|
||||
"Raptor Point",
|
||||
"C266",
|
||||
"C262",
|
||||
"W790",
|
||||
"Meteor Lake-P",
|
||||
"Lunar Lake-M"
|
||||
]
|
||||
|
||||
# Resource: https://en.wikipedia.org/wiki/List_of_AMD_chipsets
|
||||
AMDChipsets = [
|
||||
"TRX40",
|
||||
"AMD",
|
||||
"AM1",
|
||||
"A68H",
|
||||
"A75",
|
||||
"A78",
|
||||
"A85X",
|
||||
"A88X",
|
||||
"A320",
|
||||
"B350",
|
||||
"X370",
|
||||
"X399",
|
||||
"B450",
|
||||
"X470",
|
||||
"A520",
|
||||
"B550",
|
||||
"X570",
|
||||
"TRX40",
|
||||
"TRX50",
|
||||
"A620",
|
||||
"B650",
|
||||
"X670",
|
||||
"X870"
|
||||
]
|
||||
|
||||
"X870",
|
||||
"X870E"
|
||||
]
|
||||
69
Scripts/datasets/cpu_data.py
Executable file → Normal file
69
Scripts/datasets/cpu_data.py
Executable file → Normal file
@@ -1,27 +1,35 @@
|
||||
AMDCPUGenerations = [
|
||||
"Summit Ridge",
|
||||
"Whitehaven",
|
||||
"Raven Ridge",
|
||||
"Pinnacle Ridge",
|
||||
"Great Horned Owl",
|
||||
"Dalí",
|
||||
"Banded Kestrel",
|
||||
"River Hawk",
|
||||
"Pinnacle Ridge",
|
||||
"Colfax",
|
||||
"Picasso",
|
||||
"Grey Hawk",
|
||||
"Matisse",
|
||||
"Castle Peak",
|
||||
"Renoir",
|
||||
"Lucienne",
|
||||
"Vermeer",
|
||||
"Cezanne",
|
||||
"Barcelo",
|
||||
"Barceló",
|
||||
"Rembrandt",
|
||||
"Raphael",
|
||||
"Mendocino",
|
||||
"Barceló-R",
|
||||
"Rembrandt-R",
|
||||
"V3000",
|
||||
"Chagall",
|
||||
"Raphael",
|
||||
"Storm Peak",
|
||||
"Phoenix",
|
||||
"Dragon Range",
|
||||
"Hawk Point",
|
||||
"Granite Ridge",
|
||||
"Whitehaven",
|
||||
"Colfax",
|
||||
"Castle Peak",
|
||||
"Chagall",
|
||||
"Storm Peak"
|
||||
"Strix Point"
|
||||
]
|
||||
|
||||
IntelCPUGenerations = [
|
||||
@@ -40,4 +48,49 @@ IntelCPUGenerations = [
|
||||
"Rocket Lake",
|
||||
"Alder Lake",
|
||||
"Raptor Lake"
|
||||
]
|
||||
|
||||
new_IntelCPUGenerations = [
|
||||
"Raptor Lake-S",
|
||||
"Alder Lake-S",
|
||||
"Rocket Lake-S",
|
||||
"Rocket Lake-E",
|
||||
"Ice Lake-U",
|
||||
"Ice Lake-SP",
|
||||
"Comet Lake-S",
|
||||
"Comet Lake-W",
|
||||
"Comet Lake-H",
|
||||
"Comet Lake-U",
|
||||
"Coffee Lake-S",
|
||||
"Coffee Lake-E",
|
||||
"Coffee Lake-H",
|
||||
"Coffee Lake-U",
|
||||
"Cannon Lake-U",
|
||||
"Whiskey Lake-U",
|
||||
"Kaby Lake",
|
||||
"Kaby Lake-H",
|
||||
"Kaby Lake-X",
|
||||
"Kaby Lake-G",
|
||||
"Amber Lake-Y",
|
||||
"Cascade Lake-X",
|
||||
"Cascade Lake-P",
|
||||
"Cascade Lake-W",
|
||||
"Skylake",
|
||||
"Skylake-X",
|
||||
"Broadwell",
|
||||
"Broadwell-H",
|
||||
"Broadwell-U",
|
||||
"Broadwell-Y",
|
||||
"Broadwell-E",
|
||||
"Haswell",
|
||||
"Haswell-ULT",
|
||||
"Haswell-ULX",
|
||||
"Haswell-H",
|
||||
"Haswell-E",
|
||||
"Haswell-EP",
|
||||
"Haswell-EX",
|
||||
"Ivy Bridge",
|
||||
"Ivy Bridge-E",
|
||||
"Sandy Bridge",
|
||||
"Sandy Bridge-E"
|
||||
]
|
||||
@@ -112,7 +112,7 @@ class KextMaestro:
|
||||
selected_kexts.append("SMCLightSensor")
|
||||
|
||||
if not (" Core" in hardware_report.get("CPU").get("Processor Name") and \
|
||||
self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=12)) or \
|
||||
self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=3)) or \
|
||||
self.utils.parse_darwin_version(macos_version) >= self.utils.parse_darwin_version("23.0.0") or "MacPro7,1" in smbios_model:
|
||||
selected_kexts.append("RestrictEvents")
|
||||
|
||||
@@ -126,7 +126,7 @@ class KextMaestro:
|
||||
if self.utils.parse_darwin_version(macos_version) >= self.utils.parse_darwin_version("22.0.0") and not "AVX2" in hardware_report.get("CPU").get("Instruction Set"):
|
||||
selected_kexts.append("CryptexFixup")
|
||||
|
||||
if self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=13) and \
|
||||
if self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=2) and \
|
||||
int(hardware_report.get("CPU").get("CPU Cores")) > 6:
|
||||
selected_kexts.append("CpuTopologyRebuild")
|
||||
|
||||
|
||||
@@ -60,7 +60,7 @@ class SMBIOS:
|
||||
|
||||
def select_smbios_model(self, hardware_report, macos_version):
|
||||
if self.utils.parse_darwin_version(macos_version) < self.utils.parse_darwin_version("20.0.0") or \
|
||||
self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=12):
|
||||
self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), end=4):
|
||||
smbios_model = "iMacPro1,1"
|
||||
else:
|
||||
smbios_model = "MacPro7,1"
|
||||
@@ -121,7 +121,7 @@ class SMBIOS:
|
||||
smbios_model = "iMac17,1"
|
||||
if "Laptop" in hardware_report.get("Motherboard").get("Platform"):
|
||||
smbios_model = "MacBookPro13,1" if int(hardware_report.get("CPU").get("CPU Cores")) < 4 else "MacBookPro13,3"
|
||||
elif self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=8, end=11):
|
||||
elif self.utils.contains_any(cpu_data.IntelCPUGenerations, hardware_report.get("CPU").get("CPU Codename"), start=6, end=16):
|
||||
smbios_model = "Macmini8,1"
|
||||
if "Desktop" in hardware_report.get("Motherboard").get("Platform"):
|
||||
smbios_model = "iMac18,3" if self.utils.parse_darwin_version(macos_version) < self.utils.parse_darwin_version("18.0.0") else "iMac19,1"
|
||||
|
||||
Reference in New Issue
Block a user