mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-04-13 20:28:21 +10:00
build: Implement NVGOP_GK.efi
Thanks @jazzzny
This commit is contained in:
@@ -33,6 +33,8 @@
|
||||
- Fixed full screen animation
|
||||
- Fixed split screen
|
||||
- Improved menubar blur
|
||||
- Add Nvidia Kepler GOP Driver injection
|
||||
- Primarily for GPUs lacking GOPs and can't have a newer VBIOS flashed
|
||||
- Increment Binaries:
|
||||
- OpenCorePkg 0.8.8 - release
|
||||
- PatcherSupportPkg 0.8.0 - release
|
||||
|
||||
@@ -2539,6 +2539,18 @@
|
||||
<key>LoadEarly</key>
|
||||
<false/>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>Comment</key>
|
||||
<string></string>
|
||||
<key>Path</key>
|
||||
<string>NVGOP_GK.efi</string>
|
||||
<key>Enabled</key>
|
||||
<false/>
|
||||
<key>Arguments</key>
|
||||
<string></string>
|
||||
<key>LoadEarly</key>
|
||||
<false/>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>Comment</key>
|
||||
<string></string>
|
||||
|
||||
BIN
payloads/Drivers/NVGOP_GK.efi
Normal file
BIN
payloads/Drivers/NVGOP_GK.efi
Normal file
Binary file not shown.
@@ -282,11 +282,18 @@ class build_graphics_audio:
|
||||
self.config["UEFI"]["Quirks"]["ReloadOptionRoms"] = True
|
||||
|
||||
# AMD GOP VBIOS injection for AMD GCN 1-4 GPUs
|
||||
if self.constants.gop_injection is True:
|
||||
if self.constants.amd_gop_injection is True:
|
||||
print("- Adding AMDGOP.efi")
|
||||
shutil.copy(self.constants.amd_gop_driver_path, self.constants.drivers_path)
|
||||
support.build_support(self.model, self.constants, self.config).get_efi_binary_by_path("AMDGOP.efi", "UEFI", "Drivers")["Enabled"] = True
|
||||
|
||||
# Nvidia Kepler GOP VBIOS injection
|
||||
if self.constants.nvidia_kepler_gop_injection is True:
|
||||
print("- Adding NVGOP_GK.efi")
|
||||
shutil.copy(self.constants.nvidia_kepler_gop_driver_path, self.constants.drivers_path)
|
||||
support.build_support(self.model, self.constants, self.config).get_efi_binary_by_path("NVGOP_GK.efi", "UEFI", "Drivers")["Enabled"] = True
|
||||
|
||||
|
||||
def spoof_handling(self):
|
||||
if self.constants.serial_settings == "None":
|
||||
return
|
||||
|
||||
@@ -181,7 +181,8 @@ class Constants:
|
||||
self.allow_ts2_accel = True # Set TeraScale 2 Acceleration support
|
||||
self.force_nv_web = False # Force Nvidia Web Drivers on Tesla and Kepler
|
||||
self.force_output_support = False # Force Output support for Mac Pros with PC VBIOS
|
||||
self.gop_injection = False # Set GOP Injection support
|
||||
self.amd_gop_injection = False # Set GOP Injection support
|
||||
self.nvidia_kepler_gop_injection = False # Set Kepler GOP Injection support
|
||||
|
||||
## Miscellaneous
|
||||
self.disallow_cpufriend = False # Disable CPUFriend
|
||||
@@ -258,6 +259,10 @@ class Constants:
|
||||
def amd_gop_driver_path(self):
|
||||
return self.payload_path / Path("Drivers/AMDGOP.efi")
|
||||
|
||||
@property
|
||||
def nvidia_kepler_gop_driver_path(self):
|
||||
return self.payload_path / Path("Drivers/NVGOP_GK.efi")
|
||||
|
||||
@property
|
||||
def xhci_driver_path(self):
|
||||
return self.payload_path / Path("Drivers/XhciDxe.efi")
|
||||
|
||||
@@ -2581,23 +2581,33 @@ class wx_python_gui:
|
||||
self.timeout_spinner.Centre(wx.HORIZONTAL)
|
||||
|
||||
# AMD GOP Injection
|
||||
self.set_gop_injection = wx.CheckBox(self.frame_modal, label="AMD GOP Injection")
|
||||
self.set_gop_injection.SetPosition(wx.Point(
|
||||
self.set_amd_gop_injection = wx.CheckBox(self.frame_modal, label="AMD GOP Injection")
|
||||
self.set_amd_gop_injection.SetPosition(wx.Point(
|
||||
30,
|
||||
self.timeout_spinner.GetPosition().y + self.timeout_spinner.GetSize().height + 5))
|
||||
self.set_gop_injection.SetValue(self.constants.gop_injection)
|
||||
self.set_gop_injection.Bind(wx.EVT_CHECKBOX, self.gop_injection_checkbox_click)
|
||||
self.set_amd_gop_injection.SetValue(self.constants.amd_gop_injection)
|
||||
self.set_amd_gop_injection.Bind(wx.EVT_CHECKBOX, self.amd_gop_injection_checkbox_click)
|
||||
models = ["iMac10,1", "iMac11,1", "iMac11,2", "iMac11,3", "iMac12,1", "iMac12,2", "MacPro3,1", "MacPro4,1", "MacPro5,1", "Xserve2,1", "Xserve3,1"]
|
||||
if (not self.constants.custom_model and self.computer.real_model not in models) or (self.constants.custom_model and self.constants.custom_model not in models):
|
||||
self.set_gop_injection.Disable()
|
||||
self.set_amd_gop_injection.Disable()
|
||||
|
||||
# Nvidia Kepler GOP injection
|
||||
self.set_nvidia_kepler_gop_injection = wx.CheckBox(self.frame_modal, label="Nvidia Kepler GOP Injection")
|
||||
self.set_nvidia_kepler_gop_injection.SetPosition(wx.Point(
|
||||
self.set_amd_gop_injection.GetPosition().x,
|
||||
self.set_amd_gop_injection.GetPosition().y + self.set_amd_gop_injection.GetSize().height))
|
||||
self.set_nvidia_kepler_gop_injection.SetValue(self.constants.nvidia_kepler_gop_injection)
|
||||
self.set_nvidia_kepler_gop_injection.Bind(wx.EVT_CHECKBOX, self.nvidia_kepler_gop_injection_checkbox_click)
|
||||
if (not self.constants.custom_model and self.computer.real_model not in models) or (self.constants.custom_model and self.constants.custom_model not in models):
|
||||
self.set_nvidia_kepler_gop_injection.Disable()
|
||||
|
||||
# Disable Thunderbolt
|
||||
self.disable_thunderbolt_checkbox = wx.CheckBox(self.frame_modal, label="Disable Thunderbolt")
|
||||
self.disable_thunderbolt_checkbox.SetValue(self.constants.disable_tb)
|
||||
self.disable_thunderbolt_checkbox.Bind(wx.EVT_CHECKBOX, self.disable_tb_click)
|
||||
self.disable_thunderbolt_checkbox.SetPosition(wx.Point(
|
||||
self.set_gop_injection.GetPosition().x,
|
||||
self.set_gop_injection.GetPosition().y + self.set_gop_injection.GetSize().height))
|
||||
self.set_nvidia_kepler_gop_injection.GetPosition().x,
|
||||
self.set_nvidia_kepler_gop_injection.GetPosition().y + self.set_nvidia_kepler_gop_injection.GetSize().height))
|
||||
self.disable_thunderbolt_checkbox.SetToolTip(wx.ToolTip("Disables Thunderbolt support on MacBookPro11,x\nMainly applicable for systems that cannot boot with Thunderbolt enabled"))
|
||||
if not self.constants.custom_model and not self.computer.real_model.startswith("MacBookPro11"):
|
||||
self.disable_thunderbolt_checkbox.Disable()
|
||||
@@ -2846,13 +2856,21 @@ class wx_python_gui:
|
||||
print("Content Caching Disabled")
|
||||
self.constants.set_content_caching = False
|
||||
|
||||
def gop_injection_checkbox_click(self, event=None):
|
||||
if self.set_gop_injection.GetValue():
|
||||
print("GOP Injection Enabled")
|
||||
self.constants.gop_injection = True
|
||||
def amd_gop_injection_checkbox_click(self, event=None):
|
||||
if self.set_amd_gop_injection.GetValue():
|
||||
print("AMD GOP Injection Enabled")
|
||||
self.constants.amd_gop_injection = True
|
||||
else:
|
||||
print("GOP Injection Disabled")
|
||||
self.constants.gop_injection = False
|
||||
print("AMD GOP Injection Disabled")
|
||||
self.constants.amd_gop_injection = False
|
||||
|
||||
def nvidia_kepler_gop_injection_checkbox_click(self, event=None):
|
||||
if self.set_nvidia_kepler_gop_injection.GetValue():
|
||||
print("Nvidia Kepler GOP Injection Enabled")
|
||||
self.constants.nvidia_kepler_gop_injection = True
|
||||
else:
|
||||
print("Nvidia Kepler GOP Injection Disabled")
|
||||
self.constants.nvidia_kepler_gop_injection = False
|
||||
|
||||
def disable_tb_click(self, event=None):
|
||||
if self.disable_thunderbolt_checkbox.GetValue():
|
||||
|
||||
Reference in New Issue
Block a user