AMD Rayon R7 5800H Install Monterey kernel Panic

zxc2689963

Active member
AMD OS X Member
Feb 27, 2022
135
92
28
Hello everyone, the Monterey kernel panic problem has been solved for AMD R7 5800H notebook installation. It is a great thing that the CPU can now run on 8 cores. Thank you guys very much.Thank them for discovering the problem and providing kernel patches @ExtremeX@Visual

Brand: Lenovo
Model: Legion 5 6th Gen
CPU: AMD Ryzen 7 5800h
GPU: AMD Radeon RX 6600m 8GB ( Separate GPU mode)
HDD: Samsung SSD 970 EVO Plus 1TB (1000 GB, PCI-E 3.0 x4)
WDS500G3X0C-00SJG0 (500 GB, PCI-E 3.0 x4)
Network: RealTek Semiconductor RTL8168/8111 PCI-E Gigabit Ethernet NIC
Intel(R) Wi-Fi 6E AX210 160MHz
Ram: x2 8GB 3200mhz ddr4
Display: 15.6 1080p 165HZ

Updated October 5, 2023
Problems solved:
1. You do not need to disable XHCI
2. The microphone problem is rectified
3. Monitor brightness can be adjusted, only in Ventura

Unresolved issues:
Failure to wake from sleep

 

Attachments

Last edited:
Solution
Panic from Monterey 12.6
View attachment 7258
Thanks. I looked at the sched_prim.c file in the XNU Kernel source code (nice of Apple to let us know exactly where to search) and found that it's related to the TSC (Time Stamp Counter) Syncronization of the CPU cores. The section of the code which gives the panic is: https://github.com/apple-oss-distributions/xnu/blob/xnu-8020.140.41/osfmk/kern/sched_prim.c#L2836
Unfortunately Apple didn't update the XNU Source Code for macOS 12.6 yet, but I still managed to find the place where it calls the panic.
Image 1 is the code of XNU that panics if the time between cores does not match (not syncronized properly).

As seen when comparing the Big Sur and Monterey code (Image 2), Big Sur...
Haven't used clover in a long time. Don't tell me how?
Can you run DPCIManager in macOS? You can dump the DSDT with that.
Also if you have Windows, see if you can make a note of the hardware ids in Device Manager,
mainly for the GPUs and/or audio codec. Also name the codec if you can.
A check for the WiFi and BT (if they are Intel or Broadcom) is also needed.
 
Can you run DPCIManager in macOS? You can dump the DSDT with that.
Also if you have Windows, see if you can make a note of the hardware ids in Device Manager,
mainly for the GPUs and/or audio codec. Also name the codec if you can.
A check for the WiFi and BT (if they are Intel or Broadcom) is also needed.
Mac os not installed
wifi module from mediatek
 

Attachments

  • Screenshot_399.png
    Screenshot_399.png
    14.3 KB · Views: 11
  • Screenshot_398.png
    Screenshot_398.png
    8.5 KB · Views: 10
  • Screenshot_397.png
    Screenshot_397.png
    12.6 KB · Views: 11
  • Screenshot_396.png
    Screenshot_396.png
    12.9 KB · Views: 11
  • Like
Reactions: Middleman
Mac os not installed
wifi module from mediatek
Okay that looks good. Let's see what we can do now.
We'll need to look at that DSDT as well.
 
  • Like
Reactions: lev12354
But as? Should I put it in the clover's kext folder and then let's run the Mac OS installer?
No, not recommended. Clover is a bit more tricky to install nowadays. It doesn't have the better functions like OC.
 
No, not recommended. Clover is a bit more tricky to install nowadays. It doesn't have the better functions like OC.
I don't quite understand what is required of me. That is, I need to install Mac OS on my laptop now and open this application in it? If yes, then how, I really can’t run the installer on opencore, not to mention the installed system on this laptop
 
Alright so I've gone and made the changes to the files.
Give these SSDTs a try.
OK, I removed SSDT-USBX from ACPI and added both of your patches, then tried all combinations with with & without USBtoolbox, UTBmap, Usbinjectall, GenericUSBXHCI and there was no change, no ports worked. One thing I did notice is that if I disabled GenericUSBXHCI.kext, it would hang at the picture below. I also attached the EFI that I have been using. If I re-enable GenericUSBXHCI.kext, it boots, but still with no USB.


IMG_0222.jpeg
 

Attachments

I don't quite understand what is required of me. That is, I need to install Mac OS on my laptop now and open this application in it? If yes, then how, I really can’t run the installer on opencore, not to mention the installed system on this laptop
I believe you can use SSDTTime in windows to get your DSDT Dump.... here is a link tho that site with info on how to do it.

https://github.com/corpnewt/SSDTTime
 
  • Like
Reactions: lev12354
Do you also have any other files aside from the DSDT?
 
OK, I removed SSDT-USBX from ACPI and added both of your patches, then tried all combinations with with & without USBtoolbox, UTBmap, Usbinjectall, GenericUSBXHCI and there was no change, no ports worked. One thing I did notice is that if I disabled GenericUSBXHCI.kext, it would hang at the picture below. I also attached the EFI that I have been using. If I re-enable GenericUSBXHCI.kext, it boots, but still with no USB.


View attachment 6168
No, you're meant to leave the SSDT-USBX in there as well along with the SSDT-EC and the two XHC files I gave you plus the USBMap or USBInjectall.
 
  • Like
Reactions: OG Nerd
Did it via ssdttime

No other files
I think you'll need to look at creating a Clover version of the boot stick. It will be purely for the BIOS dump (as it provides more info).
Just need to check for some things before I go make the EFI.
 
No, you're meant to leave the SSDT-USBX in there as well along with the SSDT-EC and the two XHC files I gave you plus the USBMap or USBInjectall.
I removed the SSDT-USBX.aml patch and installed both yours instead, do I need to keep SSDT-USBX.aml as well?

For the heck of it I added SSDT-USBX.aml back and it took out the m.2 intel wireless and no USB ports so I disabled and removed it again.
 
Last edited:
I removed the SSDT-USBX.aml patch and installed both yours instead, do I need to keep SSDT-USBX.aml as well?

For the heck of it I added SSDT-USBX.aml back and it took out the m.2 intel wireless and no USB ports so I disabled and removed it again.
You may have to search online for a solution on that in that case. But judging by the look of things, they should both be correct, esp. the first XHC file.
 
  • Like
Reactions: OG Nerd
Thanks for this, I'll be looking at it tomorrow for you.
 
@lev12345
Thanks for this, I'll be looking at it tomorrow for you.
@lev12345

I want to ask - when you made the Clover test boot drive did you put in the SSDTs that we made in this thread inside the ACPI ?
Because (according to the files I received) that's what seems like it, as I can see our processor and XHC renames in the column and top.
So I really need more of a 'raw' output of the SSDTs to get a better idea. If that's the case you'll need to remove any SSDT.amls found
inside the ACPI folder and try to dump the BIOS again. Clover should boot into the main screen without any issues.
 
  AdBlock Detected
Sure, ad-blocking software does a great job at blocking ads, but it also blocks some useful and important features of our website. For the best possible site experience please take a moment to disable your AdBlocker.