mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-06-15 20:00:00 +10:00
build.py: Move nvda_drv to dedicated entry
This commit is contained in:
+9
-5
@@ -692,10 +692,11 @@ class BuildOpenCore:
|
||||
if device.arch in [device_probe.NVIDIA.Archs.Maxwell, device_probe.NVIDIA.Archs.Pascal]:
|
||||
print("- Adding Web Driver Patches")
|
||||
self.config["DeviceProperties"]["Add"][device.pci_path].update({"disable-metal": 1, "force-compat": 1})
|
||||
if "nvda_drv_vrl=1" not in self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]["boot-args"]:
|
||||
self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]["boot-args"] += " nvda_drv_vrl=1"
|
||||
if self.get_kext_by_bundle_path("WhateverGreen.kext")["Enabled"] is False:
|
||||
self.enable_kext("WhateverGreen.kext", self.constants.whatevergreen_version, self.constants.whatevergreen_path)
|
||||
self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"].update({"nvda_drv": binascii.unhexlify("31")})
|
||||
if "nvda_drv" not in self.config["NVRAM"]["Delete"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]:
|
||||
self.config["NVRAM"]["Delete"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"] += ["nvda_drv"]
|
||||
|
||||
else:
|
||||
print(f"- Failed to find Device path for dGPU {i + 1}")
|
||||
@@ -714,11 +715,14 @@ class BuildOpenCore:
|
||||
self.config["UEFI"]["Quirks"]["ForgeUefiSupport"] = True
|
||||
self.config["UEFI"]["Quirks"]["ReloadOptionRoms"] = True
|
||||
if device.arch in [device_probe.NVIDIA.Archs.Maxwell, device_probe.NVIDIA.Archs.Pascal]:
|
||||
if "ngfxgl=1 ngfxcompat=1 nvda_drv_vrl=1" not in self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]["boot-args"]:
|
||||
print("- Adding Web Driver Patches")
|
||||
self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]["boot-args"] += " ngfxgl=1 ngfxcompat=1 nvda_drv_vrl=1"
|
||||
print("- Adding Web Driver Patches")
|
||||
if "ngfxgl=1 ngfxcompat=1" not in self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]["boot-args"]:
|
||||
self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]["boot-args"] += " ngfxgl=1 ngfxcompat=1"
|
||||
if self.get_kext_by_bundle_path("WhateverGreen.kext")["Enabled"] is False:
|
||||
self.enable_kext("WhateverGreen.kext", self.constants.whatevergreen_version, self.constants.whatevergreen_path)
|
||||
self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"].update({"nvda_drv": binascii.unhexlify("31")})
|
||||
if "nvda_drv" not in self.config["NVRAM"]["Delete"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]:
|
||||
self.config["NVRAM"]["Delete"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"] += ["nvda_drv"]
|
||||
|
||||
if not self.computer.gpus:
|
||||
print("- No socketed dGPU found")
|
||||
|
||||
@@ -47,6 +47,9 @@ class generate_defaults:
|
||||
settings.amfi_status = True
|
||||
settings.allow_fv_root = True # Allow FileVault on broken seal
|
||||
break
|
||||
elif gpu.arch in [device_probe.NVIDIA.Archs.Maxwell, device_probe.NVIDIA.Archs.Pascal]:
|
||||
settings.custom_sip_value = "0xA03"
|
||||
break
|
||||
if (
|
||||
isinstance(settings.computer.wifi, device_probe.Broadcom)
|
||||
and settings.computer.wifi.chipset in [device_probe.Broadcom.Chipsets.AirPortBrcm4331, device_probe.Broadcom.Chipsets.AirPortBrcm43224]
|
||||
|
||||
Reference in New Issue
Block a user