- Joined
- Nov 10, 2022
- Messages
- 56
WOW!
Great work! I'll ask people on MSI motherboards to test it as well, and I'll test it on my own Zen 2 desktop as well. If it doesn't break anything, then maybe @Shaneee could merge it to the patches repo? Also, if you don't mind, what exactly did you change in the source code?** Kernel Patch for macOS Monterey **Purpose:
Patch Details:
- This kernel patch allows PCI devices to function properly on the new AM5 platform with Ryzen 7000 processors
- This patch applies to Monterey only; it does not work with Ventura
- Will work on a Ventura patch tomorrow
View attachment 8204
- Arch: x86_64
- Identifier: com.apple.iokit.IOPCIFamily
- Comment: CaseySJ - fix probeBusGated
- Find: F605F9DA 0200080F 85A90000 00
- Replace: F605F9DA 0200080F 84A90000 00
- Min Kernel: 21.0.0
- Max Kernel: 21.99.99
- Count: 1
- Enabled: True
Outstanding work!
Find: F605F9DA 0200080F 85A90000 00- Replace: F605F9DA 0200080F 84A90000 00
Don't think there was ever one uploaded here.
Casey, can you dump the latest IOPCIFamily from both Monterey and Ventura?
Can you send the kext folder zipped?Can't even find it in macOS lol The kext has no binary.
Should be in /S/L/E, try getting them from an installer.I believe it's within the Kernelcache. I'm unable to extract it but with a debug OC I can see if it's patching it.
{"bug_type":"210","timestamp":"2022-11-13 12:19:29.00 +0100","os_version":"macOS 13.1 (22C5044e)","roots_installed":0,"incident_id":"09753E06-5BFF-4A4A-B599-E7A4786912B0"}
{"macOSProcessedStackshotData":"bm8gb24gZGlzayBwYW5pYyBzdGFja3Nob3QgZm91bmQgaW4gY29yZWZpbGU=","macOSPanicString":"panic(cpu 48 caller 0xffffff80121ae3da): Invalid queue element linkage for 0xffffff95ef877de0: next 0xffffff95f05445d0 next->prev 0xffffff95ef877de0 prev 0xffffff95ead26030 prev->next 0 @queue.h:255\nPanicked task 0xffffff912a4966a0: 1 threads: pid 414: com.apple.ColorS\nBacktrace (CPU 48), panicked thread: 0xffffff9ab99e1540, Frame : Return Address\n0xffffffd15ac13690 : 0xffffff801207de9d \n0xffffffd15ac136e0 : 0xffffff80121e0556 \n0xffffffd15ac13720 : 0xffffff80121cf8c3 \n0xffffffd15ac13770 : 0xffffff801201da70 \n0xffffffd15ac13790 : 0xffffff801207e26d \n0xffffffd15ac138b0 : 0xffffff801207da26 \n0xffffffd15ac13910 : 0xffffff80129145e3 \n0xffffffd15ac13a00 : 0xffffff80121ae3da \n0xffffffd15ac13ae0 : 0xffffff80121ae7e1 \n0xffffffd15ac13b30 : 0xffffff80121378fb \n0xffffffd15ac13b80 : 0xffffff80121366cf \n0xffffffd15ac13cb0 : 0xffffff80121359a9 \n0xffffffd15ac13d10 : 0xffffff801213e647 \n0xffffffd15ac13d60 : 0xffffff80120b83b1 \n0xffffffd15ac13da0 : 0xffffff8012647094 \n0xffffffd15ac13e10 : 0xffffff80126661ac \n0xffffffd15ac13e80 : 0xffffff80126665a7 \n0xffffffd15ac13ec0 : 0xffffff8012073f7d \n0xffffffd15ac13ef0 : 0xffffff801201da3c \n\nProcess name corresponding to current thread (0xffffff9ab99e1540): com.apple.ColorSyncXPCAgent\nBoot args: chunklist-security-epoch=0 -chunklist-no-rev2-dev chunklist-security-epoch=0 -chunklist-no-rev2-dev\n\nMac OS version:\n21G217\n\nKernel version:\nDarwin Kernel Version 21.6.0: Thu Sep 29 20:12:57 PDT 2022; root:xnu-8020.240.7~1\/RELEASE_X86_64\nKernel UUID: 54B44BAE-1625-30CC-80B0-29E4966EFFDC\nKernelCache slide: 0x0000000011e00000\nKernelCache base: 0xffffff8012000000\nKernel slide: 0x0000000011e10000\nKernel text base: 0xffffff8012010000\n__HIB text base: 0xffffff8011f00000\nSystem model name: MacPro7,1 (Mac-27AD2F918AE68F61)\nSystem shutdown begun: NO\nPanic diags file available: YES (0x0)\nHibernation exit count: 0\n\nSystem uptime in nanoseconds: 22623281484\nLast Sleep: absolute base_tsc base_nano\n Uptime : 0x000000054473e3cc\n Sleep : 0x0000000000000000 0x0000000000000000 0x0000000000000000\n Wake : 0x0000000000000000 0x000000215972611f 0x0000000000000000\nCompressor Info: 0% of compressed pages limit (OK) and 0% of segments limit (OK) with 0 swapfiles and OK swap space\nZone info:\n Zone map: 0xffffff811a42f000 - 0xffffffa11a42f000\n . PGZ : 0xffffff811a42f000 - 0xffffff813a42c000\n . VM : 0xffffff813a42c000 - 0xffffff860242c000\n . RO : 0xffffff860242c000 - 0xffffff879a42c000\n . GEN0 : 0xffffff879a42c000 - 0xffffff8c6242c000\n . GEN1 : 0xffffff8c6242c000 - 0xffffff912a42c000\n . GEN2 : 0xffffff912a42c000 - 0xffffff95f242c000\n . GEN3 : 0xffffff95f242c000 - 0xffffff9aba42d000\n . DATA : 0xffffff9aba42d000 - 0xffffffa11a42f000\n Metadata: 0xffffffffbb89e000 - 0xffffffffdb89e000\n Bitmaps : 0xffffffffdb89e000 - 0xfffffffffb89e000\n\nlast started kext at 20075181031: >driverkit.serial\t6.0.0 (addr 0xffffff7fab2b5000, size 28672)\nloaded kexts:\nas.vit9696.VirtualSMC\t1.3.1\nwtf.spinach.AMDRyzenCPUPowerManagement\t0.7.1\nas.vit9696.Lilu\t1.6.3\n@filesystems.exfat\t1.4\n>AudioAUUC\t1.70\n>!AUpstreamUserClient\t3.6.9\n>!AMCCSControl\t1.16\n@kext.AMDRadeonX6000\t4.0.8\n>eficheck\t1\n@kext.AMDRadeonServiceManager\t4.0.8\n>!APlatformEnabler\t2.7.0d0\n>!ALPC\t3.1\n>AGPM\t129\n>X86PlatformShim\t1.0.0\n>!AGFXHDA\t140.3\n@filesystems.autofs\t3.0\n>!AGraphicsDevicePolicy\t6.5.7\n@AGDCPluginDisplayMetrics\t6.5.7\n>ACPI_SMC_PlatformPlugin\t1.0.0\n>pmtelemetry\t1\n|IOUserEthernet\t1.0.1\n>usb.!UUserHCI\t1\n>!AHV\t1\n>!ADiskImages2\t126.141.2\n>!AFIVRDriver\t4.1.0\n>!A!IMCEReporter\t115\n>!A!ISlowAdaptiveClocking\t4.0.0\n>!AThunderboltIP\t4.0.3\n>!ARAID\t5.1.0\n|SCSITaskUserClient\t456.140.3\n>PioneerSuperDrive\t533.120.2\n@private.KextAudit\t1.0\n>AirPort.BrcmNIC\t1400.1.1\n>!AAHCIPort\t351.100.4\n>!AFileSystemDriver\t3.0.1\n@filesystems.tmpfs\t1\n@filesystems.lifs\t1\n@filesystems.apfs\t1934.141.2\n@filesystems.hfs.kext\t583.100.10\n@BootCache\t40\n@!AFSCompression.!AFSCompressionTypeZlib\t1.0.0\n@!AFSCompression.!AFSCompressionTypeDataless\t1.0.0d1\n>!AHPET\t1.8\n>!AACPIButtons\t6.1\n>!ARTC\t2.0.1\n>!ASMBIOS\t2.1\n>!AAPIC\t1.7\n@!ASystemPolicy\t2.0.0\n@nke.applicationfirewall\t402\n|IOKitRegistryCompatibility\t1\n|EndpointSecurity\t1\n@Dont_Steal_Mac_OS_X\t7.0.0\n>!A!ICPUPowerManagement\t222.0.0\n@kec.!AEncryptedArchive\t1\n>driverkit.serial\t6.0.0\n|IOSerial!F\t11\n|IOAccelerator!F2\t462.8\n>!ASMBus!C\t1.0.18d1\n|IOSMBus!F\t1.1\n@kext.AMDRadeonX6000HWLibs\t1.0\n>!UAudio\t416.2\n>!AAudioClockLibs\t140.1\n>!ASMBusPCI\t1.0.14d1\n@kext.AMDRadeonX6000HWServices\t4.0.8\n>!AHDA!C\t340.2\n|IOHDA!F\t340.2\n|IOAudio!F\t340.2\n@vecLib.kext\t1.2.0\n@kext.triggers\t1.0\n>!AGraphicsControl\t6.5.7\n|IONDRVSupport\t597\n@kext.AMDRadeonX6000Framebuffer\t4.0.8\n@kext.AMDSupport\t4.0.8\n>IOPlatformPluginLegacy\t1.0.0\n|IO!BSerialManager\t9.0.0\n|IO!BPacketLogger\t9.0.0\n|IO!BHost!CUSBTransport\t9.0.0\n|IO!BHost!CUARTTransport\t9.0.0\n|IO!BHost!CTransport\t9.0.0\n>IO!BHost!CPCIeTransport\t9.0.0\n|IOAVB!F\t1040.6\n@plugin.IOgPTPPlugin\t1040.3\n|IOEthernetAVB!C\t1.1.0\n|CSR!BHost!CUSBTransport\t9.0.0\n|Broadcom!BHost!CUSBTransport\t9.0.0\n|Broadcom!B20703USBTransport\t9.0.0\n>!AIPAppender\t1.0\n>X86PlatformPlugin\t1.0.0\n>IOPlatformPlugin!F\t6.0.0d8\n@!AGPUWrangler\t6.5.7\n@!AGraphicsDeviceControl\t6.5.7\n|IOGraphics!F\t597\n|IOSlowAdaptiveClocking!F\t1.0.0\n>!AThunderboltEDMSink\t5.0.3\n>!AThunderboltPCIUpAdapter\t4.1.1\n>!AThunderboltPCIDownAdapter\t4.1.1\n>!AThunderboltDPInAdapter\t8.5.1\n>!AThunderboltDPOutAdapter\t8.5.1\n>!AThunderboltDPAdapter!F\t8.5.1\n>!AHPM\t3.4.4\n>!A!ILpssI2C!C\t3.0.60\n>!A!ILpssI2C\t3.0.60\n>!A!ILpssDmac\t3.0.60\n>usb.IOUSBHostHIDDevice\t1.2\n>usb.cdc\t5.0.0\n>usb.networking\t5.0.0\n>usb.!UHostCompositeDevice\t1.2\n>usb.!UHub\t1.2\n|IOSCSIMultimediaCommandsDevice\t456.140.3\n|IOBD!S!F\t1.8\n|IODVD!S!F\t1.8\n|IOCD!S!F\t1.8\n|IOAHCIBlock!S\t333.140.2\n|IOAHCISerialATAPI\t270\n>!A!ILpssGspi\t3.0.60\n|IO80211!FLegacy\t1200.12.2b1\n|IOSkywalk!F\t1.0\n>mDNSOffloadUserClient\t1.0.1b8\n>corecapture\t1.0.4\n|IOAHCI!F\t297\n>!AThunderboltNHI\t7.2.81\n|IOThunderbolt!F\t9.3.3\n>!AXsanScheme\t3\n>usb.!UXHCIPCI\t1.2\n>usb.!UXHCI\t1.2\n|IONVMe!F\t2.1.0\n>!ABSDKextStarter\t3\n|IOSurface\t302.14\n@filesystems.hfs.encodings.kext\t1\n>usb.!UHostPacketFilter\t1.0\n|IOUSB!F\t900.4.2\n>!AEFINVRAM\t2.1\n|IOHID!F\t2.0.0\n>!AEFIRuntime\t2.1\n|IOTimeSync!F\t1040.3\n|IONetworking!F\t3.4\n>DiskImages\t493.0.0\n|IO!B!F\t9.0.0\n|IOReport!F\t47\n$quarantine\t4\n$sandbox\t300.0\n@kext.!AMatch\t1.0.0d1\n|CoreAnalytics!F\t1\n>!ASSE\t1.0\n>!AKeyStore\t2\n>!UTDM\t533.120.2\n|IOUSBMass!SDriver\t210.120.3\n|IOSCSIBlockCommandsDevice\t456.140.3\n|IO!S!F\t2.1\n|IOSCSIArchitectureModel!F\t456.140.3\n>!AMobileFileIntegrity\t1.0.5\n$!AImage4\t4.2.0\n@kext.CoreTrust\t1\n>!AFDEKeyStore\t28.30\n>!AEffaceable!S\t1.0\n>!ACredentialManager\t1.0\n>KernelRelayHost\t1\n|IOUSBHost!F\t1.2\n>!UHostMergeProperties\t1.2\n>usb.!UCommon\t1.0\n>!ABusPower!C\t1.0\n>!ASEPManager\t1.0.1\n>IOSlaveProcessor\t1\n>!AACPIPlatform\t6.1\n>!ASMC\t3.1.9\n|IOPCI!F\t2.9\n|IOACPI!F\t1.4\n>watchdog\t1\n@kec.pthread\t1\n@kec.Libm\t1\n@kec.corecrypto\t12.0\n\n\n"}
That would be great! The binary for Monterey is in /S/L/E —> IOPCIFamily.kext/Contents@CaseySJ I was going to look at making it one patch via masking but where is the binary for Monterey?
Can't seem to locate it.
Thank you again for your suggestions throughout the process — and for asking @alyxferrari to post a kernel build guide. This would not have happened otherwise!Great work! I'll ask people on MSI motherboards to test it as well, and I'll test it on my own Zen 2 desktop as well. If it doesn't break anything, then maybe @Shaneee could merge it to the patches repo? Also, if you don't mind, what exactly did you change in the source code?
Certainly — will post an explanation of the patch today.Outstanding work!
On behalf of the mere mortals among us who cannot read compiled binary code, may I ask what this decompiles to and what this code is doing?