Skip to content

Commit af57596

Browse files
committed
sys_patch: Add OHCI/UHCI downgrade
1 parent 51954d3 commit af57596

File tree

6 files changed

+36
-6
lines changed

6 files changed

+36
-6
lines changed

CHANGELOG.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,9 @@
77
- Resolve unresponsive Weather app
88
- Resolve full screen menubar covering the app toolbar
99
- Resolve unfocused password windows
10+
- Resolve USB 1.1 kernel panics on macOS 14.1
1011
- Increment Binaries:
11-
- PatcherSupportPkg 1.3.5 - release
12+
- PatcherSupportPkg 1.3.6 - release
1213
- AirportBrcmFixup 2.1.8 - release
1314
- BlueToolFixup 2.6.8 - release
1415
- RestrictEvents 1.1.3 - release

data/sys_patch_dict.py

+22
Original file line numberDiff line numberDiff line change
@@ -1265,6 +1265,28 @@ def _generate_sys_patch_dict(self):
12651265
},
12661266
},
12671267
},
1268+
# Injection of UHCI/OHCI causes a panic on 14.1+
1269+
"Legacy USB 1.1 Extended": {
1270+
"Display Name": "",
1271+
"OS Support": {
1272+
"Minimum OS Support": {
1273+
"OS Major": os_data.os_data.sonoma,
1274+
"OS Minor": 1 # macOS 14.1 (XNU 23.1)
1275+
},
1276+
"Maximum OS Support": {
1277+
"OS Major": os_data.os_data.max_os,
1278+
"OS Minor": 99
1279+
},
1280+
},
1281+
"Install": {
1282+
"/System/Library/Extensions/IOUSBHostFamily.kext/Contents/PlugIns": {
1283+
"AppleUSBOHCI.kext": "12.6.2-USB",
1284+
"AppleUSBOHCIPCI.kext": "12.6.2-USB",
1285+
"AppleUSBUHCI.kext": "12.6.2-USB",
1286+
"AppleUSBUHCIPCI.kext": "12.6.2-USB",
1287+
},
1288+
},
1289+
},
12681290
"PCIe FaceTime Camera": {
12691291
"Display Name": "Miscellaneous: PCIe FaceTime Camera",
12701292
"OS Support": {

payloads/Config/config.plist

+4-4
Original file line numberDiff line numberDiff line change
@@ -1377,7 +1377,7 @@
13771377
<key>ExecutablePath</key>
13781378
<string>Contents/MacOS/AppleUSBOHCI</string>
13791379
<key>MaxKernel</key>
1380-
<string></string>
1380+
<string>23.0.0</string>
13811381
<key>MinKernel</key>
13821382
<string>22.0.0</string>
13831383
<key>PlistPath</key>
@@ -1395,7 +1395,7 @@
13951395
<key>ExecutablePath</key>
13961396
<string>Contents/MacOS/AppleUSBOHCIPCI</string>
13971397
<key>MaxKernel</key>
1398-
<string></string>
1398+
<string>23.0.0</string>
13991399
<key>MinKernel</key>
14001400
<string>22.0.0</string>
14011401
<key>PlistPath</key>
@@ -1413,7 +1413,7 @@
14131413
<key>ExecutablePath</key>
14141414
<string>Contents/MacOS/AppleUSBUHCI</string>
14151415
<key>MaxKernel</key>
1416-
<string></string>
1416+
<string>23.0.0</string>
14171417
<key>MinKernel</key>
14181418
<string>22.0.0</string>
14191419
<key>PlistPath</key>
@@ -1431,7 +1431,7 @@
14311431
<key>ExecutablePath</key>
14321432
<string>Contents/MacOS/AppleUSBUHCIPCI</string>
14331433
<key>MaxKernel</key>
1434-
<string></string>
1434+
<string>23.0.0</string>
14351435
<key>MinKernel</key>
14361436
<string>22.0.0</string>
14371437
<key>PlistPath</key>

resources/build/misc.py

+6
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,12 @@ def _usb_handling(self) -> None:
280280
# - Ref: https://techcommunity.microsoft.com/t5/microsoft-usb-blog/reasons-to-avoid-companion-controllers/ba-p/270710
281281
#
282282
# To be paired for sys_patch_dict.py's 'Legacy USB 1.1' patchset
283+
#
284+
# Note: With macOS 14.1, injection of these kexts causes a panic.
285+
# To avoid this, a MaxKernel is configured with XNU 23.0.0 (macOS 14.0).
286+
# Additionally sys_patch.py stack will now patches the bins onto disk for 14.1+.
287+
# Reason for keeping the dual logic is due to potential conflicts of in-cache vs injection if we start
288+
# patching pre-14.1 hosts.
283289
if (
284290
smbios_data.smbios_dictionary[self.model]["CPU Generation"] <= cpu_data.CPUGen.penryn.value or \
285291
self.model in ["MacPro4,1", "MacPro5,1", "Xserve3,1"]

resources/constants.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ class Constants:
1414
def __init__(self) -> None:
1515
# Patcher Versioning
1616
self.patcher_version: str = "1.1.0" # OpenCore-Legacy-Patcher
17-
self.patcher_support_pkg_version: str = "1.3.5" # PatcherSupportPkg
17+
self.patcher_support_pkg_version: str = "1.3.6" # PatcherSupportPkg
1818
self.copyright_date: str = "Copyright © 2020-2023 Dortania"
1919
self.patcher_name: str = "OpenCore Legacy Patcher"
2020

resources/sys_patch/sys_patch_generate.py

+1
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,7 @@ def _generate_patchset(self) -> dict:
176176

177177
if self.hardware_details["Miscellaneous: Legacy USB 1.1"] is True:
178178
required_patches.update({"Legacy USB 1.1": all_hardware_patchset["Miscellaneous"]["Legacy USB 1.1"]})
179+
required_patches.update({"Legacy USB 1.1 Extended": all_hardware_patchset["Miscellaneous"]["Legacy USB 1.1 Extended"]})
179180

180181
if self.hardware_details["Miscellaneous: PCIe FaceTime Camera"] is True:
181182
required_patches.update({"PCIe FaceTime Camera": all_hardware_patchset["Miscellaneous"]["PCIe FaceTime Camera"]})

0 commit comments

Comments
 (0)