mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-04-11 16:27:19 +10:00
GUI: Add option to configure cpus=4 on MacPro3,1/Xserve2,1
If booting Sonoma or older, can toggle off the workaround
This commit is contained in:
@@ -26,8 +26,12 @@
|
||||
- iMac7,1 - 18,x
|
||||
- MacPro3,1 - 6,1
|
||||
- MacPro3,1 can only boot with 4 cores max currently
|
||||
- 8 cores can be re-enabled for older OSes in the GUI:
|
||||
- Settings -> Build -> MacPro3,1/Xserve2,1 Workaround
|
||||
- Xserve2,1 - 3,1
|
||||
- Xserve2,1 can only boot with 4 cores max currently
|
||||
- 8 cores can be re-enabled for older OSes in the GUI:
|
||||
- Settings -> Build -> MacPro3,1/Xserve2,1 Workaround
|
||||
- Excludes the newly dropped MacBookAir8,x series.
|
||||
- No estimate can be given when support will be added.
|
||||
- For non-Metal graphics, Photos app will be broken.
|
||||
|
||||
@@ -234,6 +234,7 @@ class Constants:
|
||||
self.disable_connectdrivers: bool = False # Disable ConnectDrivers (hibernation)
|
||||
self.set_vmm_cpuid: bool = False # Set VMM bit inside CPUID
|
||||
self.disable_mediaanalysisd: bool = False # Set mediaanalysisd to spawn
|
||||
self.force_quad_thread: bool = False # Force quad thread mode (cpus=4)
|
||||
self.set_alc_usage: bool = True # Set AppleALC usage
|
||||
self.allow_3rd_party_drives: bool = True # Allow ThridPartyDrives quirk
|
||||
self.allow_nvme_fixing: bool = True # Allow NVMe Kernel Space Patches
|
||||
|
||||
@@ -199,6 +199,12 @@ class BuildFirmware:
|
||||
logging.info("- Adding IOHIDFamily patch")
|
||||
support.BuildSupport(self.model, self.constants, self.config).get_item_by_kv(self.config["Kernel"]["Patch"], "Identifier", "com.apple.iokit.IOHIDFamily")["Enabled"] = True
|
||||
|
||||
# MacPro3,1/Xserve2,1 cannot boot with more than 4 threads in Sequoia
|
||||
# Note cpus=4 only overrides if more than 4 threads are present. So same on dual-core units
|
||||
if self.constants.force_quad_thread is True:
|
||||
logging.info("- Adding CPU Thread Limit Patch")
|
||||
self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]["boot-args"] += " cpus=4"
|
||||
|
||||
|
||||
def _firmware_driver_handling(self) -> None:
|
||||
"""
|
||||
|
||||
@@ -71,6 +71,11 @@ class GenerateDefaults:
|
||||
global_settings.GlobalEnviromentSettings().write_property("MacBookPro_TeraScale_2_Accel", False)
|
||||
self.constants.allow_ts2_accel = False
|
||||
|
||||
if self.model in ["MacPro3,1", "Xserve2,1"]:
|
||||
self.constants.force_quad_thread = True
|
||||
else:
|
||||
self.constants.force_quad_thread = False
|
||||
|
||||
if self.model in smbios_data.smbios_dictionary:
|
||||
if smbios_data.smbios_dictionary[self.model]["CPU Generation"] >= cpu_data.CPUGen.skylake.value:
|
||||
# On 2016-2017 MacBook Pros, 15" devices used a stock Samsung SSD with IONVMeController
|
||||
@@ -197,7 +202,6 @@ class GenerateDefaults:
|
||||
device_probe.Broadcom.Chipsets.AirportBrcmNIC,
|
||||
]
|
||||
):
|
||||
print("Modern WiFi")
|
||||
is_modern_wifi = True
|
||||
|
||||
if is_legacy_wifi is False and is_modern_wifi is False:
|
||||
|
||||
@@ -48,7 +48,7 @@ class SettingsFrame(wx.Frame):
|
||||
|
||||
self.settings = self._settings()
|
||||
|
||||
self.frame_modal = wx.Dialog(parent, title=title, size=(600, 675))
|
||||
self.frame_modal = wx.Dialog(parent, title=title, size=(600, 685))
|
||||
|
||||
self._generate_elements(self.frame_modal)
|
||||
self.frame_modal.ShowWindowModal()
|
||||
@@ -314,6 +314,16 @@ class SettingsFrame(wx.Frame):
|
||||
"min": 0,
|
||||
"max": 60,
|
||||
},
|
||||
"MacPro3,1/Xserve2,1 Workaround": {
|
||||
"type": "checkbox",
|
||||
"value": self.constants.force_quad_thread,
|
||||
"variable": "force_quad_thread",
|
||||
"description": [
|
||||
"Limits to 4 threads max on these units.",
|
||||
"Required for macOS Sequoia and later.",
|
||||
],
|
||||
"condition": (self.constants.custom_model and self.constants.custom_model in ["MacPro3,1", "Xserve2,1"]) or self.constants.computer.real_model in ["MacPro3,1", "Xserve2,1"]
|
||||
},
|
||||
"Debug": {
|
||||
"type": "title",
|
||||
},
|
||||
@@ -456,7 +466,6 @@ class SettingsFrame(wx.Frame):
|
||||
"Recommended for all users, however faulty",
|
||||
"SSDs may benefit from disabling this.",
|
||||
],
|
||||
|
||||
},
|
||||
},
|
||||
"Advanced": {
|
||||
|
||||
Reference in New Issue
Block a user