From b1d58511313f1cc3c0a8b888e70a3029d3af0963 Mon Sep 17 00:00:00 2001
From: Mykola Grymalyuk <48863253+khronokernel@users.noreply.github.com>
Date: Tue, 10 Aug 2021 20:20:49 -0600
Subject: [PATCH 1/4] Inject device ID via Info.plist
---
Resources/Build.py | 46 +++++++++++++++++++++++-----------------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/Resources/Build.py b/Resources/Build.py
index 96d1f62fd..8e2700c88 100644
--- a/Resources/Build.py
+++ b/Resources/Build.py
@@ -223,29 +223,29 @@ class BuildOpenCore:
def wifi_fake_id(self):
self.enable_kext("AirportBrcmFixup.kext", self.constants.airportbcrmfixup_version, self.constants.airportbcrmfixup_path)
- # self.get_kext_by_bundle_path("AirportBrcmFixup.kext/Contents/PlugIns/AirPortBrcmNIC_Injector.kext")["Enabled"] = True
- if not self.constants.custom_model and self.computer.wifi and self.computer.wifi.pci_path:
- arpt_path = self.computer.wifi.pci_path
- print(f"- Found ARPT device at {arpt_path}")
- else:
- if self.model in ModelArray.nvidiaHDEF:
- # Nvidia chipsets all have the same path to ARPT
- arpt_path = "PciRoot(0x0)/Pci(0x15,0x0)/Pci(0x0,0x0)"
- elif self.model in ("iMac7,1", "iMac8,1", "MacPro3,1", "MacBookPro4,1"):
- arpt_path = "PciRoot(0x0)/Pci(0x1C,0x4)/Pci(0x0,0x0)"
- elif self.model in ("iMac13,1", "iMac13,2"):
- arpt_path = "PciRoot(0x0)/Pci(0x1C,0x3)/Pci(0x0,0x0)"
- elif self.model in ("MacPro4,1", "MacPro5,1"):
- arpt_path = "PciRoot(0x0)/Pci(0x1C,0x5)/Pci(0x0,0x0)"
- else:
- # Assumes we have a laptop with Intel chipset
- # iMac11,x-12,x also apply
- arpt_path = "PciRoot(0x0)/Pci(0x1C,0x1)/Pci(0x0,0x0)"
- print(f"- Using known DevicePath {arpt_path}")
- self.config["DeviceProperties"]["Add"][arpt_path] = {"device-id": binascii.unhexlify("ba430000"), "compatible": "pci14e4,43ba"}
- if not self.constants.custom_model and self.computer.wifi and self.constants.validate is False and self.computer.wifi.country_code:
- print(f"- Applying fake ID for WiFi, setting Country Code: {self.computer.wifi.country_code}")
- self.config["DeviceProperties"]["Add"][arpt_path].update({"brcmfx-country": self.computer.wifi.country_code})
+ self.get_kext_by_bundle_path("AirportBrcmFixup.kext/Contents/PlugIns/AirPortBrcmNIC_Injector.kext")["Enabled"] = True
+ # if not self.constants.custom_model and self.computer.wifi and self.computer.wifi.pci_path:
+ # arpt_path = self.computer.wifi.pci_path
+ # print(f"- Found ARPT device at {arpt_path}")
+ # else:
+ # if self.model in ModelArray.nvidiaHDEF:
+ # # Nvidia chipsets all have the same path to ARPT
+ # arpt_path = "PciRoot(0x0)/Pci(0x15,0x0)/Pci(0x0,0x0)"
+ # elif self.model in ("iMac7,1", "iMac8,1", "MacPro3,1", "MacBookPro4,1"):
+ # arpt_path = "PciRoot(0x0)/Pci(0x1C,0x4)/Pci(0x0,0x0)"
+ # elif self.model in ("iMac13,1", "iMac13,2"):
+ # arpt_path = "PciRoot(0x0)/Pci(0x1C,0x3)/Pci(0x0,0x0)"
+ # elif self.model in ("MacPro4,1", "MacPro5,1"):
+ # arpt_path = "PciRoot(0x0)/Pci(0x1C,0x5)/Pci(0x0,0x0)"
+ # else:
+ # # Assumes we have a laptop with Intel chipset
+ # # iMac11,x-12,x also apply
+ # arpt_path = "PciRoot(0x0)/Pci(0x1C,0x1)/Pci(0x0,0x0)"
+ # print(f"- Using known DevicePath {arpt_path}")
+ # self.config["DeviceProperties"]["Add"][arpt_path] = {"device-id": binascii.unhexlify("ba430000"), "compatible": "pci14e4,43ba"}
+ # if not self.constants.custom_model and self.computer.wifi and self.constants.validate is False and self.computer.wifi.country_code:
+ # print(f"- Applying fake ID for WiFi, setting Country Code: {self.computer.wifi.country_code}")
+ # self.config["DeviceProperties"]["Add"][arpt_path].update({"brcmfx-country": self.computer.wifi.country_code})
if self.constants.enable_wake_on_wlan is True:
print("- Enabling Wake on WLAN support")
self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]["boot-args"] += f" -brcmfxwowl"
From 515bd5950f6268e2b7ad29c5b13853d896c7d2ff Mon Sep 17 00:00:00 2001
From: Mykola Grymalyuk <48863253+khronokernel@users.noreply.github.com>
Date: Wed, 11 Aug 2021 13:48:17 -0600
Subject: [PATCH 2/4] Fix thing
---
Resources/SysPatchArray.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Resources/SysPatchArray.py b/Resources/SysPatchArray.py
index a9c302a6f..6c49c1b67 100644
--- a/Resources/SysPatchArray.py
+++ b/Resources/SysPatchArray.py
@@ -193,7 +193,7 @@ DeleteVolumeControl = [
]
AddNvidiaAccelLegacy = [
- "GeForceGA.bundle",
+ #"GeForceGA.bundle",
"GeForceTesla.kext",
"GeForceTeslaGLDriver.bundle",
"GeForceTeslaVADriver.bundle",
From ff5a7f3a35b74d701ae4780a6276f3dd9d68f246 Mon Sep 17 00:00:00 2001
From: Mykola Grymalyuk <48863253+khronokernel@users.noreply.github.com>
Date: Wed, 11 Aug 2021 20:09:20 -0600
Subject: [PATCH 3/4] Adjust AirportBrcmFixup injection
---
CHANGELOG.md | 2 ++
payloads/Config/config.plist | 2 +-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 1d2a24f0b..7af9bd660 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -11,6 +11,8 @@
- Currently limited to MacBookPro11,x
- Set iMacPro1,1 SMBIOS for Mac Pro and Xserve models
- Allows for wider array of OS support (High Sierra+)
+- Use plist override for BCM943224 and BCM94331 support in Big Sur+
+ - Allows for older OS support through OpenCore
## 0.2.4
diff --git a/payloads/Config/config.plist b/payloads/Config/config.plist
index 43143528d..5f2556615 100644
--- a/payloads/Config/config.plist
+++ b/payloads/Config/config.plist
@@ -350,7 +350,7 @@
MaxKernel
MinKernel
- 20.0.0
+ 12.0.0
BundlePath
AirportBrcmFixup.kext
ExecutablePath
From 3f6d8c2283239c04cd6ecb954b62c243ce723967 Mon Sep 17 00:00:00 2001
From: Mykola Grymalyuk <48863253+khronokernel@users.noreply.github.com>
Date: Wed, 11 Aug 2021 20:13:43 -0600
Subject: [PATCH 4/4] Fix country code support
---
Resources/Build.py | 42 +++++++++++++++++++++---------------------
1 file changed, 21 insertions(+), 21 deletions(-)
diff --git a/Resources/Build.py b/Resources/Build.py
index 8e2700c88..adef71ccf 100644
--- a/Resources/Build.py
+++ b/Resources/Build.py
@@ -224,28 +224,28 @@ class BuildOpenCore:
def wifi_fake_id(self):
self.enable_kext("AirportBrcmFixup.kext", self.constants.airportbcrmfixup_version, self.constants.airportbcrmfixup_path)
self.get_kext_by_bundle_path("AirportBrcmFixup.kext/Contents/PlugIns/AirPortBrcmNIC_Injector.kext")["Enabled"] = True
- # if not self.constants.custom_model and self.computer.wifi and self.computer.wifi.pci_path:
- # arpt_path = self.computer.wifi.pci_path
- # print(f"- Found ARPT device at {arpt_path}")
- # else:
- # if self.model in ModelArray.nvidiaHDEF:
- # # Nvidia chipsets all have the same path to ARPT
- # arpt_path = "PciRoot(0x0)/Pci(0x15,0x0)/Pci(0x0,0x0)"
- # elif self.model in ("iMac7,1", "iMac8,1", "MacPro3,1", "MacBookPro4,1"):
- # arpt_path = "PciRoot(0x0)/Pci(0x1C,0x4)/Pci(0x0,0x0)"
- # elif self.model in ("iMac13,1", "iMac13,2"):
- # arpt_path = "PciRoot(0x0)/Pci(0x1C,0x3)/Pci(0x0,0x0)"
- # elif self.model in ("MacPro4,1", "MacPro5,1"):
- # arpt_path = "PciRoot(0x0)/Pci(0x1C,0x5)/Pci(0x0,0x0)"
- # else:
- # # Assumes we have a laptop with Intel chipset
- # # iMac11,x-12,x also apply
- # arpt_path = "PciRoot(0x0)/Pci(0x1C,0x1)/Pci(0x0,0x0)"
- # print(f"- Using known DevicePath {arpt_path}")
+ if not self.constants.custom_model and self.computer.wifi and self.computer.wifi.pci_path:
+ arpt_path = self.computer.wifi.pci_path
+ print(f"- Found ARPT device at {arpt_path}")
+ else:
+ if self.model in ModelArray.nvidiaHDEF:
+ # Nvidia chipsets all have the same path to ARPT
+ arpt_path = "PciRoot(0x0)/Pci(0x15,0x0)/Pci(0x0,0x0)"
+ elif self.model in ("iMac7,1", "iMac8,1", "MacPro3,1", "MacBookPro4,1"):
+ arpt_path = "PciRoot(0x0)/Pci(0x1C,0x4)/Pci(0x0,0x0)"
+ elif self.model in ("iMac13,1", "iMac13,2"):
+ arpt_path = "PciRoot(0x0)/Pci(0x1C,0x3)/Pci(0x0,0x0)"
+ elif self.model in ("MacPro4,1", "MacPro5,1"):
+ arpt_path = "PciRoot(0x0)/Pci(0x1C,0x5)/Pci(0x0,0x0)"
+ else:
+ # Assumes we have a laptop with Intel chipset
+ # iMac11,x-12,x also apply
+ arpt_path = "PciRoot(0x0)/Pci(0x1C,0x1)/Pci(0x0,0x0)"
+ print(f"- Using known DevicePath {arpt_path}")
# self.config["DeviceProperties"]["Add"][arpt_path] = {"device-id": binascii.unhexlify("ba430000"), "compatible": "pci14e4,43ba"}
- # if not self.constants.custom_model and self.computer.wifi and self.constants.validate is False and self.computer.wifi.country_code:
- # print(f"- Applying fake ID for WiFi, setting Country Code: {self.computer.wifi.country_code}")
- # self.config["DeviceProperties"]["Add"][arpt_path].update({"brcmfx-country": self.computer.wifi.country_code})
+ if not self.constants.custom_model and self.computer.wifi and self.constants.validate is False and self.computer.wifi.country_code:
+ print(f"- Applying fake ID for WiFi, setting Country Code: {self.computer.wifi.country_code}")
+ self.config["DeviceProperties"]["Add"][arpt_path].update({"brcmfx-country": self.computer.wifi.country_code})
if self.constants.enable_wake_on_wlan is True:
print("- Enabling Wake on WLAN support")
self.config["NVRAM"]["Add"]["7C436110-AB2A-4BBB-A880-FE41995C9F82"]["boot-args"] += f" -brcmfxwowl"