Skip to content

Commit d7e539a

Browse files
committed
add intel patch(Not work, **do not use it!!!!!!**)
1 parent c46c111 commit d7e539a

File tree

7 files changed

+102
-4
lines changed

7 files changed

+102
-4
lines changed

OCLP-R-GUI.command

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,4 @@ PyInstaller Entry Point
66
from oclp_r import main
77

88
if __name__ == '__main__':
9-
main()
10-
9+
main()

oclp_r/constants.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,8 @@ def __init__(self) -> None:
263263
###https://github.moeyy.xyz
264264
###https://gitapi.simplehac.top
265265
self.github_mirror: str = ""
266+
# Open Intel Wireless
267+
self.intel_wireless_tahoe: bool = False
266268

267269
@property
268270
def special_build(self):

oclp_r/sys_patch/patchsets/detect.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@
3535
from .hardware.networking import (
3636
legacy_wireless,
3737
modern_wireless,
38+
intel_wireless_tahoe,
3839
)
3940
from .hardware.misc import (
4041
display_backlight,
@@ -132,7 +133,9 @@ def __init__(self, constants: constants.Constants,
132133

133134
legacy_wireless.LegacyWireless,
134135
modern_wireless.ModernWireless,
136+
intel_wireless_tahoe.IntelWireless,
135137
legacy_audio.LegacyAudio,
138+
intel_wireless_tahoe.IntelWireless,
136139
modern_audio.ModernAudio,
137140
apfs_aligned.APFSP,
138141
Launch.LaunchPad,

oclp_r/sys_patch/patchsets/hardware/misc/modern_audio.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def present(self) -> bool:
3737
"""
3838
if utilities.check_kext_loaded("org.voodoo.driver.VoodooHDA") !="" and self._constants.audio_type!="AppleHDA":
3939
self._constants.audio_type="AppleHDA"
40-
return self._constants.audio_type=="AppleHDA" and utilities.check_kext_loaded("as.vit9696.AppleALC") !="" and utilities.check_kext_loaded("org.voodoo.driver.VoodooHDA") ==""
40+
return self._constants.audio_type=="AppleHDA" and utilities.check_kext_loaded("as.vit9696.AppleALC") !=""
4141
def requires_kernel_debug_kit(self) -> bool:
4242
"""
4343
Apple no longer provides standalone kexts in the base OS

oclp_r/sys_patch/patchsets/hardware/misc/voodoo_audio.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def present(self) -> bool:
3131

3232

3333
def native_os(self) -> bool:
34-
if self._xnu_major < os_data.monterey.value:
34+
if self._xnu_major < os_data.big_sur.value:
3535
return True
3636
return False
3737

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
"""
2+
modern_wireless.py: Modern Wireless detection
3+
"""
4+
5+
from ..base import BaseHardware, HardwareVariant
6+
7+
from ...base import PatchType
8+
9+
from .....constants import Constants
10+
from .....detections import device_probe
11+
12+
from .....datasets.os_data import os_data
13+
14+
15+
class IntelWireless(BaseHardware):
16+
17+
def __init__(self, xnu_major, xnu_minor, os_build, global_constants: Constants) -> None:
18+
super().__init__(xnu_major, xnu_minor, os_build, global_constants)
19+
20+
def name(self) -> str:
21+
"""
22+
Display name for end users
23+
"""
24+
return f"{self.hardware_variant()}: Intel Wireless"
25+
26+
27+
def present(self) -> bool:
28+
"""
29+
Targeting Intel Wireless
30+
"""
31+
if self._xnu_major<os_data.tahoe.value:
32+
return False
33+
if not self._constants.intel_wireless_tahoe:
34+
return False
35+
return isinstance(self._computer.wifi, device_probe.IntelWirelessCard)and(
36+
self._computer.wifi.chipset in [
37+
device_probe.IntelWirelessCard.Chipsets.IntelWirelessIDs,
38+
]
39+
)
40+
41+
42+
def native_os(self) -> bool:
43+
"""
44+
Dropped support with macOS 26, Tahoe
45+
"""
46+
return self._xnu_major < os_data.tahoe.value
47+
48+
49+
def hardware_variant(self) -> HardwareVariant:
50+
"""
51+
Type of hardware variant
52+
"""
53+
return HardwareVariant.NETWORKING
54+
55+
56+
def patches(self) -> dict:
57+
"""
58+
Patches for Modern Wireless
59+
"""
60+
if self.native_os() is True:
61+
return {}
62+
return {
63+
"Intel Wireless": {
64+
PatchType.OVERWRITE_SYSTEM_VOLUME: {
65+
"/usr/libexec": {
66+
"airportd": "14.7.7",
67+
"wifip2pd": "14.7.7",
68+
},
69+
"/System/Library/CoreServices": {
70+
"WiFiAgent.app": "14.7.7" ,
71+
},
72+
},
73+
PatchType.MERGE_SYSTEM_VOLUME: {
74+
"/System/Library/Frameworks": {
75+
"CoreWLAN.framework": "14.7.7",
76+
},
77+
"/System/Library/PrivateFrameworks": {
78+
"CoreWiFi.framework": "14.7.7",
79+
"IO80211.framework": "14.7.7",
80+
"WiFiPeerToPeer.framework": "14.7.7",
81+
},
82+
}
83+
},
84+
}

oclp_r/wx_gui/gui_settings.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -810,6 +810,16 @@ def _settings(self) -> dict:
810810
"on Tahoe.",
811811
],
812812
},
813+
"Allow Intel Wireless Patch (exp.)":{
814+
"type": "checkbox",
815+
"value": self.constants.intel_wireless_tahoe,
816+
"variable": "intel_wireless_tahoe",
817+
"constants_variable": "intel_wireless_tahoe",
818+
"description": [
819+
"When enabled, this will patch the Intel Wireless",
820+
"on Tahoe.",
821+
],
822+
},
813823
"AppleHDA.kext Version": {
814824
"type": "choice",
815825
"choices": [

0 commit comments

Comments
 (0)