AMD Rayon R7 5800H Install Monterey kernel Panic

zxc2689963

Active member
AMD OS X Member
Joined
Feb 27, 2022
Messages
135
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

  • EFI-2023-10-5.zip
    40 MB · Views: 194
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...

medni78

New member
AMD OS X Member
Joined
Dec 25, 2023
Messages
2
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 eight 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

Hi, I am new; I have the same model, R7000P 2021A, with Ryzen 5800H and 6600M, intel 210 WiFi. On the Ventura installer with boot-arg -v, the boot process goes on, but I get a black screen after verbose using your EFI. Any Idea on how to fix it?

Boot args used:
-v keepsyms=1 debug=0x100 -vi2c-force-polling agdpmod=pikera

A video showing the problem: https://drive.google.com/file/d/1caR_zViXd5ksMcUXpUrWLoMF_GROsfil/view?usp=sharing
 
Last edited:

medni78

New member
AMD OS X Member
Joined
Dec 25, 2023
Messages
2
Hi, I am new; I have the same model, R7000P 2021A, with Ryzen 5800H and 6600M, intel 210 WiFi. On the Ventura installer with boot-arg -v, the boot process goes on, but I get a black screen after verbose using your EFI. Any Idea on how to fix it?

Boot args used:
-v keepsyms=1 debug=0x100 -vi2c-force-polling agdpmod=pikera

A video showing the problem: https://drive.google.com/file/d/1caR_zViXd5ksMcUXpUrWLoMF_GROsfil/view?usp=sharing
The problem was solved by installing BigSur using the aforementioned EFI, installing it without any issues, then updating itwl Kext to enable WiFi and update to Ventura. Then again update the WiFi Kext to support Ventura.


Thanks to all the contributors for enabling this device to work flawlessly.
 

craighazan

Donator
Donator
Joined
Nov 22, 2021
Messages
392
@Shaneee Thanks for your input. I'm pretty sure it would fix it since that's where it panics, but I'm guessing that it's not worth the time.

On another note, this seems like what we need! (Image)

@zty199 Please try this EFI.

@craighazan Do you also have this laptop? If so can you test it?

- ExtremeXT
I'm getting the same panic on a GenMachine Ren5000, 5700U. Trying to install Sonoma but not getting very far!.
 

craighazan

Donator
Donator
Joined
Nov 22, 2021
Messages
392
So after reading through this thread and testing some of the EFI's, I still don't seem to be getting anywhere. Edhawk kindly put together an EFI for me to try, it contains the patches from Visual, attached below. The purpose of this build is a case mod for a Nintendo GameCube, any advice would be appreciated.

I'm attempting to install Sonoma, should I install Monterey instead?.

IMG_0127.jpeg


IMG_0121.jpeg
 

Attachments

  • EFIv4.zip
    28.2 MB · Views: 10

zxc2689963

Active member
AMD OS X Member
Joined
Feb 27, 2022
Messages
135
So after reading through this thread and testing some of the EFI's, I still don't seem to be getting anywhere. Edhawk kindly put together an EFI for me to try, it contains the patches from Visual, attached below. The purpose of this build is a case mod for a Nintendo GameCube, any advice would be appreciated.

I'm attempting to install Sonoma, should I install Monterey instead?.

View attachment 13060


View attachment 13062
Your SSDT-CPUR has the wrong number of CPU cores, you should remove some and leave only 16 cores
 

craighazan

Donator
Donator
Joined
Nov 22, 2021
Messages
392
Your SSDT-CPUR has the wrong number of CPU cores, you should remove some and leave only 16 cores
Thanks for the tip, I remember reading about that somewhere within this thread. so my first four patches should be;

B8100000 0000
BA100000 0000
BA100000 0090
BA100000 00

instead of;

B8080000 0000
BA080000 0000
BA080000 0090
BA080000 00

And will Sonoma work, or should I install Monterey?. TIA
 

zxc2689963

Active member
AMD OS X Member
Joined
Feb 27, 2022
Messages
135
Thanks for the tip, I remember reading about that somewhere within this thread. so my first four patches should be;

B8100000 0000
BA100000 0000
BA100000 0090
BA100000 00

instead of;

B8080000 0000
BA080000 0000
BA080000 0090
BA080000 00

And will Sonoma work, or should I install Monterey?. TIA
No, your kernel patch is 8 correct, your SSDT-CPUR is not right, there are too many cores do not know whether it has an impact, try the SSDT-CPUR I provide屏幕截图 2024-01-06 173935.png
 

Attachments

  • SSDT-CPUR.aml.zip
    907 bytes · Views: 10

craighazan

Donator
Donator
Joined
Nov 22, 2021
Messages
392
No, your kernel patch is 8 correct, your SSDT-CPUR is not right, there are too many cores do not know whether it has an impact, try the SSDT-CPUR I provided.

Thanks for your help, unfortunately I’m still getting this kp.

IMG_0157.jpeg
 

craighazan

Donator
Donator
Joined
Nov 22, 2021
Messages
392
Try using parameter CPUS=1
We're all good, I established that CPUR wasn't needed for the Ren5000, the chipset isn't a 500 series board. But thanks for the help.
 

redhorse1990

Member
AMD OS X Member
Joined
Jul 2, 2022
Messages
161
Also waiting for Zen3+ 6800h laptop
Do you have the same brand with mine?
If your laptop is the same with mine, you can go to this thread and work together with us
 

Edhawk

Guru
Guru
Joined
May 2, 2020
Messages
2,505
Try this revised EFI-10 folder. Don't change anything, just post a photo of the verbose text if it kernel panics.

I checked the ACPI SSDT's and patches in your current EFI, and these seem to be OK. Same with Drivers, Tools and Resources folders.

I have removed some kexts, USB, Bluetooth, WiFi and TSC.
  1. The USB kexts are not doing anything helpful, as they don't include a custom USB configuration, just the empty 'Default' kext.
  2. The Bluetooth and WiFi kext removal is just a precaution as some recent releases of macOS have KP'd when these are present during the installation. So I thought it would be good to try installing Monterey without them present in the OC setup.
  3. I have replaced the AmdTscSync.kext with an alternative TSC kext (ForgedInvariant.kext).
Made a couple of minor changes to the config, as well as the kext changes above.

Let me know how you get on.
 

Attachments

  • EFI-10.zip
    5.6 MB · Views: 5

redhorse1990

Member
AMD OS X Member
Joined
Jul 2, 2022
Messages
161
Try this revised EFI-10 folder. Don't change anything, just post a photo of the verbose text if it kernel panics.

I checked the ACPI SSDT's and patches in your current EFI, and these seem to be OK. Same with Drivers, Tools and Resources folders.

I have removed some kexts, USB, Bluetooth, WiFi and TSC.
  1. The USB kexts are not doing anything helpful, as they don't include a custom USB configuration, just the empty 'Default' kext.
  2. The Bluetooth and WiFi kext removal is just a precaution as some recent releases of macOS have KP'd when these are present during the installation. So I thought it would be good to try installing Monterey without them present in the OC setup.
  3. I have replaced the AmdTscSync.kext with an alternative TSC kext (ForgedInvariant.kext).
Made a couple of minor changes to the config, as well as the kext changes above.

Let me know how you get on.
Still get a forbidden icon after here.
 

Attachments

  • IMG_0586.jpeg
    IMG_0586.jpeg
    3.9 MB · Views: 2

Edhawk

Guru
Guru
Joined
May 2, 2020
Messages
2,505
How far did you get with creating a custom USB kext, in Windows using the USBToolBox Tool?

 
Back
Top Bottom
  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.