mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-06-21 22:50:51 +10:00
Add Brightness Control patches
This commit is contained in:
@@ -27,11 +27,8 @@ If applicable, add the generated OpenCore Build to help explain your problem.
|
|||||||
- OS Patching (ie. macOS 11.2.3, Big Sur)
|
- OS Patching (ie. macOS 11.2.3, Big Sur)
|
||||||
- Model Patching (ie. MacPro5,1)
|
- Model Patching (ie. MacPro5,1)
|
||||||
|
|
||||||
For in-depth hardware logs, we highly encourage users to send the following files:
|
For in-depth hardware logs, we highly encourage users to run [IORegistryExplorer](https://github.com/khronokernel/IORegistryClone/blob/master/ioreg-210.zip?raw=true) and send the output
|
||||||
```bash
|
* ie. `File -> SaveAs`
|
||||||
ioreg -lw0 > ~/Desktop/IOReg.txt
|
|
||||||
ioreg -lw0 -a > ~/Desktop/IOReg.plist
|
|
||||||
```
|
|
||||||
|
|
||||||
**Additional context**
|
**Additional context**
|
||||||
Add any other context about the problem here.
|
Add any other context about the problem here.
|
||||||
|
|||||||
@@ -8,6 +8,7 @@
|
|||||||
- AppleALC 1a3e5cb (1.6.0 rolling - 04-10-2021)
|
- AppleALC 1a3e5cb (1.6.0 rolling - 04-10-2021)
|
||||||
- Enhance Wifi model detection
|
- Enhance Wifi model detection
|
||||||
- Hide OpenShell.efi by default
|
- Hide OpenShell.efi by default
|
||||||
|
- Add Brightness Control patches for legacy Nvidia and Intel GPUs
|
||||||
|
|
||||||
## 0.0.22
|
## 0.0.22
|
||||||
- Add ExFat support for models missing driver
|
- Add ExFat support for models missing driver
|
||||||
|
|||||||
@@ -110,7 +110,7 @@ system_profiler SPHardwareDataType | grep 'Model Identifier'
|
|||||||
utilities.header(["Patching System Volume"])
|
utilities.header(["Patching System Volume"])
|
||||||
print("""Patches Root volume to fix misc issues such as:
|
print("""Patches Root volume to fix misc issues such as:
|
||||||
|
|
||||||
- No patches currently avalible for any model
|
- Brightness control for non-Metal Nvidia and Intel GPUs
|
||||||
|
|
||||||
WARNING: Root Volume Patching is still in active development, please
|
WARNING: Root Volume Patching is still in active development, please
|
||||||
have all important user data backed up. Note when the system volume
|
have all important user data backed up. Note when the system volume
|
||||||
|
|||||||
@@ -928,6 +928,15 @@ AddNvidiaAccel11 = [
|
|||||||
"IOSurface.kext",
|
"IOSurface.kext",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
AddNvidiaBrightness11 = [
|
||||||
|
"GeForceGA.bundle",
|
||||||
|
"GeForceTesla.kext",
|
||||||
|
"GeForceTeslaGLDriver.bundle",
|
||||||
|
"GeForceTeslaVADriver.bundle",
|
||||||
|
"NVDANV50HalTesla.kext",
|
||||||
|
"NVDAResmanTesla.kext",
|
||||||
|
]
|
||||||
|
|
||||||
AddAMDAccel11 = [
|
AddAMDAccel11 = [
|
||||||
"AMD2400Controller.kext",
|
"AMD2400Controller.kext",
|
||||||
"AMD2600Controller.kext",
|
"AMD2600Controller.kext",
|
||||||
@@ -963,6 +972,16 @@ AddIntelGen1Accel = [
|
|||||||
"IOSurface.kext",
|
"IOSurface.kext",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
AddIntelGen1Brightness = [
|
||||||
|
"AppleIntelFramebufferAzul.kext",
|
||||||
|
"AppleIntelFramebufferCapri.kext",
|
||||||
|
"AppleIntelHDGraphics.kext",
|
||||||
|
"AppleIntelHDGraphicsFB.kext",
|
||||||
|
"AppleIntelHDGraphicsGA.plugin",
|
||||||
|
"AppleIntelHDGraphicsGLDriver.bundle",
|
||||||
|
"AppleIntelHDGraphicsVADriver.bundle",
|
||||||
|
]
|
||||||
|
|
||||||
AddIntelGen2Accel = [
|
AddIntelGen2Accel = [
|
||||||
"AppleIntelHD3000Graphics.kext",
|
"AppleIntelHD3000Graphics.kext",
|
||||||
"AppleIntelHD3000GraphicsGA.plugin",
|
"AppleIntelHD3000GraphicsGA.plugin",
|
||||||
@@ -973,6 +992,15 @@ AddIntelGen2Accel = [
|
|||||||
"IOSurface.kext",
|
"IOSurface.kext",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
AddIntelGen2Brightness = [
|
||||||
|
"AppleIntelHD3000Graphics.kext",
|
||||||
|
"AppleIntelHD3000GraphicsGA.plugin",
|
||||||
|
"AppleIntelHD3000GraphicsGLDriver.bundle",
|
||||||
|
"AppleIntelHD3000GraphicsVADriver.bundle",
|
||||||
|
"AppleIntelSNBGraphicsFB.kext",
|
||||||
|
"AppleIntelSNBVA.bundle",
|
||||||
|
]
|
||||||
|
|
||||||
DeleteBrightness = [
|
DeleteBrightness = [
|
||||||
"AppleGraphicsControl.kext/Contents/PlugIns/AGDCBacklightControl.kext"
|
"AppleGraphicsControl.kext/Contents/PlugIns/AGDCBacklightControl.kext"
|
||||||
]
|
]
|
||||||
|
|||||||
+16
-3
@@ -163,6 +163,7 @@ class PatchSysVolume:
|
|||||||
|
|
||||||
def patch_root_vol(self):
|
def patch_root_vol(self):
|
||||||
print(f"- Detecting patches for {self.model}")
|
print(f"- Detecting patches for {self.model}")
|
||||||
|
rebuild_required = False
|
||||||
# TODO: Create Backup of S*/L*/Extensions, Frameworks and PrivateFramework to easily revert changes
|
# TODO: Create Backup of S*/L*/Extensions, Frameworks and PrivateFramework to easily revert changes
|
||||||
# APFS snapshotting seems to ignore System Volume changes inconcistently, would like a backup to avoid total brick
|
# APFS snapshotting seems to ignore System Volume changes inconcistently, would like a backup to avoid total brick
|
||||||
# Perhaps a basic py2 script to run in recovery to restore
|
# Perhaps a basic py2 script to run in recovery to restore
|
||||||
@@ -176,15 +177,27 @@ class PatchSysVolume:
|
|||||||
self.constants.current_gpuv = [line.strip().split(": ", 1)[1] for line in current_gpu.split("\n") if line.strip().startswith(("Vendor"))][0]
|
self.constants.current_gpuv = [line.strip().split(": ", 1)[1] for line in current_gpu.split("\n") if line.strip().startswith(("Vendor"))][0]
|
||||||
self.constants.current_gpud = [line.strip().split(": ", 1)[1] for line in current_gpu.split("\n") if line.strip().startswith(("Device ID"))][0]
|
self.constants.current_gpud = [line.strip().split(": ", 1)[1] for line in current_gpu.split("\n") if line.strip().startswith(("Device ID"))][0]
|
||||||
|
|
||||||
if (self.model in ModelArray.LegacyGPU) and (Path(self.constants.hiddhack_path).exists()):
|
if self.model in ModelArray.LegacyGPU:
|
||||||
print(f"- Detected GPU: {self.constants.current_gpuv} {self.constants.current_gpud}")
|
print(f"- Detected GPU: {self.constants.current_gpuv} {self.constants.current_gpud}")
|
||||||
if (self.constants.current_gpuv == "AMD (0x1002)") & (self.constants.current_gpud in ModelArray.AMDMXMGPUs):
|
if (self.constants.current_gpuv == "AMD (0x1002)") & (self.constants.current_gpud in ModelArray.AMDMXMGPUs):
|
||||||
print("- Detected Metal-based AMD GPU, skipping legacy patches")
|
print("- Detected Metal-based AMD GPU, skipping legacy patches")
|
||||||
elif (self.constants.current_gpuv == "NVIDIA (0x10de)") & (self.constants.current_gpud in ModelArray.NVIDIAMXMGPUs):
|
elif (self.constants.current_gpuv == "NVIDIA (0x10de)") & (self.constants.current_gpud in ModelArray.NVIDIAMXMGPUs):
|
||||||
print("- Detected Metal-based Nvidia GPU, skipping legacy patches")
|
print("- Detected Metal-based Nvidia GPU, skipping legacy patches")
|
||||||
else:
|
else:
|
||||||
print("- Detected legacy GPU, attempting legacy acceleration patches")
|
if Path(self.constants.hiddhack_path).exists():
|
||||||
self.gpu_accel_patches_11()
|
print("- Detected legacy GPU, attempting legacy acceleration patches")
|
||||||
|
self.gpu_accel_patches_11()
|
||||||
|
else:
|
||||||
|
print("- Adding Brightness Control patches")
|
||||||
|
if self.model in ModelArray.LegacyGPUNvidia:
|
||||||
|
self.add_new_binaries(ModelArray.AddNvidiaBrightness11, self.constants.legacy_nvidia_path)
|
||||||
|
#elif self.model in ModelArray.LegacyGPUNvidia:
|
||||||
|
# self.add_new_binaries(ModelArray.AddAMDBrightness11, self.constants.legacy_amd_path)
|
||||||
|
|
||||||
|
if self.model in ModelArray.LegacyGPUIntelGen1:
|
||||||
|
self.add_new_binaries(ModelArray.AddIntelGen1Brightness, self.constants.legacy_intel_gen1_path)
|
||||||
|
elif self.model in ModelArray.LegacyGPUIntelGen2:
|
||||||
|
self.add_new_binaries(ModelArray.AddIntelGen2Brightness, self.constants.legacy_intel_gen2_path)
|
||||||
rebuild_required = True
|
rebuild_required = True
|
||||||
|
|
||||||
if rebuild_required is True:
|
if rebuild_required is True:
|
||||||
|
|||||||
+1
-1
@@ -12,7 +12,7 @@ With OpenCore Legacy Patcher we recommend users go through the below table to un
|
|||||||
| Supported OSes | <span style="color:#30BCD5">10.7-11</span> | <span style="color:red">10.15-11</span> |
|
| Supported OSes | <span style="color:#30BCD5">10.7-11</span> | <span style="color:red">10.15-11</span> |
|
||||||
| Firmware Patching | <span style="color:#30BCD5">None required</span> | <span style="color:red">Required for models without native APFS support</span> |
|
| Firmware Patching | <span style="color:#30BCD5">None required</span> | <span style="color:red">Required for models without native APFS support</span> |
|
||||||
| BootCamp Switching | <span style="color:red">Requires EFI Conversion for Start Disk support, otherwise still supported</span> | <span style="color:#30BCD5">Native</span> |
|
| BootCamp Switching | <span style="color:red">Requires EFI Conversion for Start Disk support, otherwise still supported</span> | <span style="color:#30BCD5">Native</span> |
|
||||||
| Brightness Control on Legacy GPUs | <span style="color:red">Not supported</span> | <span style="color:#30BCD5">Supported</span> |
|
| Brightness Control on Legacy GPUs | <span style="color:#30BCD5">Supported</span> | <span style="color:#30BCD5">Supported</span> |
|
||||||
| WPA Wifi Support | <span style="color:#30BCD5">Native, stable</span> | <span style="color:red">Unstable</span> |
|
| WPA Wifi Support | <span style="color:#30BCD5">Native, stable</span> | <span style="color:red">Unstable</span> |
|
||||||
| Legacy GPU Acceleration | <span style="color:red">Coming soon</span> | <span style="color:red">Coming soon</span> |
|
| Legacy GPU Acceleration | <span style="color:red">Coming soon</span> | <span style="color:red">Coming soon</span> |
|
||||||
| Brightness Control on Legacy GPUs | <span style="color:red">Coming soon</span> | <span style="color:#30BCD5">Supported</span> |
|
| Brightness Control on Legacy GPUs | <span style="color:red">Coming soon</span> | <span style="color:#30BCD5">Supported</span> |
|
||||||
|
|||||||
+2
-1
@@ -16,7 +16,8 @@ The below table will list all supported and unsupported functions of the patcher
|
|||||||
* [Mac Pro](#mac-pro)
|
* [Mac Pro](#mac-pro)
|
||||||
* [Xserve](#xserve)
|
* [Xserve](#xserve)
|
||||||
|
|
||||||
Note: In this patcher, Brightness Control is tied to GPU acceleration
|
Note: Brightness Control is currently unsupported on AMD GPUs as well as on iMac7,1, iMac8,1, iMac9,1 and MacBook5,2
|
||||||
|
|
||||||
|
|
||||||
Note 2: For setups that require AppleHDA patching, we highly advise users instead opt of a USB Audio adapter to avoid root patching. This ensures that [DELTA](./TERMS.md) updates, FileVault, SIP and other security features can stay in-tact.
|
Note 2: For setups that require AppleHDA patching, we highly advise users instead opt of a USB Audio adapter to avoid root patching. This ensures that [DELTA](./TERMS.md) updates, FileVault, SIP and other security features can stay in-tact.
|
||||||
|
|
||||||
|
|||||||
@@ -225,6 +225,10 @@ Note, GPU Acceleration Patches are not public yet, the below section is simply d
|
|||||||
* Nvidia Binaries
|
* Nvidia Binaries
|
||||||
* GeForceGA.bundle
|
* GeForceGA.bundle
|
||||||
* GeForceTesla.kext
|
* GeForceTesla.kext
|
||||||
|
* Skip IOFree Panic - Mojave+
|
||||||
|
* At Offset `0x5CF9A` replace following bytes with `0xEB`
|
||||||
|
* Avoids `addMemoryRegion/removeMemoryRegion` calls
|
||||||
|
* At Offset `0x5527` and `0x77993`, replace following bytes with `0x909090909090`
|
||||||
* GeForceTeslaGLDriver.bundle
|
* GeForceTeslaGLDriver.bundle
|
||||||
* GeForceTeslaVADriver.bundle
|
* GeForceTeslaVADriver.bundle
|
||||||
* NVDANV50HalTesla.kext
|
* NVDANV50HalTesla.kext
|
||||||
|
|||||||
Reference in New Issue
Block a user