提交 55663190 编写于 作者: P PMheart

ocvalidate: Add error when injecting BrcmFirmwareRepo

closes https://github.com/acidanthera/bugtracker/issues/2119
上级 9de7ab1a
......@@ -85,6 +85,9 @@ KEXT_INFO mKextInfo[] = {
{ "BrcmBluetoothInjectorLegacy.kext", "", "Contents/Info.plist" },
{ "BlueToolFixup.kext", "Contents/MacOS/BlueToolFixup", "Contents/Info.plist" },
{ "BrcmFirmwareData.kext", "Contents/MacOS/BrcmFirmwareData", "Contents/Info.plist" },
//
// NOTE: BrcmFirmwareRepo.kext cannot be injected by the bootloader; when it is present, an error should be prompted.
//
{ "BrcmFirmwareRepo.kext", "Contents/MacOS/BrcmFirmwareRepo", "Contents/Info.plist" },
{ "BrcmNonPatchRAM.kext", "Contents/MacOS/BrcmNonPatchRAM", "Contents/Info.plist" },
{ "BrcmNonPatchRAM2.kext", "Contents/MacOS/BrcmNonPatchRAM2", "Contents/Info.plist" },
......
......@@ -52,6 +52,7 @@ Utility to validate whether a `config.plist` matches requirements and convention
- Entry[N]->BundlePath: Filename should have `.kext` suffix.
- Entry[N]->PlistPath: Filename should have `.plist` suffix.
- Entry[N]: If `Lilu.kext` is used, `DisableLinkeditJettison` should be enabled in `Kernel->Quirks`.
- `BrcmFirmwareRepo.kext` must not be injected by OpenCore.
- For some known kexts, their `BundlePath`, `ExecutablePath`, and `PlistPath` must match against each other. Current list of rules can be found [here](https://github.com/acidanthera/OpenCorePkg/blob/master/Utilities/ocvalidate/KextInfo.c).
- Plugin kext must be placed after parent kext. For example, [plugins of Lilu](https://github.com/acidanthera/Lilu/blob/master/KnownPlugins.md) must be placed after `Lilu.kext`.
#### Delete
......
......@@ -292,6 +292,14 @@ CheckKernelAdd (
++ErrorCount;
}
}
//
// Special check for BrcmFirmwareRepo, which cannot be injected by OC.
//
if (AsciiStrCmp (BundlePath, "BrcmFirmwareRepo.kext") == 0) {
DEBUG ((DEBUG_WARN, "BrcmFirmwareRepo.kext at Kernel->Add[%u] cannot be injected by OpenCore, please remove it!\n", Index));
++ErrorCount;
}
} else {
DEBUG ((
DEBUG_WARN,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册