DSDT patch

Deleted member 22707

New member
AMD OS X Member
Dec 26, 2023
23
2
3
CPU:
R5 7500F
Where I can find guide how to patch DSDT for my mb (Asus rog B650e-e wifi)?
 
Ah, right: The name is maciasl.
And the cask actually installs Acidanthera's graphical application MaciASL.
Once the application is installed, the command line compiler is available (kind of…) at
/Applications/MaciASL/Contents/MacOS/iasl-stable

And then, after making a link
ln /Applications/MaciASL.app/Contents/MacOS/iasl-stable /usr/local/sbin/iasl
DSDT_Analysis_Tool_macOS-Linux.py works as expected.
 
Yes, you're right, it was missed..install, and still nothing
Warning: No available formula with the name "iasl". Did you mean isl?
Have you followed these instructions?


Edit:
I’m aware that Python can cause some issues on Windows and is often blocked by antivirus or firewall software.
I use Comodo Antivirus and Firewall, and the file DSDT-Analysis-Tool-Win.py is frequently blocked by Comodo.
To ensure the program runs correctly, you need to manually set the file as “Trusted” in the File Rating section.

After that, you can start the tool via the command line using the following command:

Code:
python DSDT-Analysis-Tool-Win.py
Then press Enter to run the command.

The tool works!
I’m currently working on further development. The goal is to enable the tool to insert various patches in the future to allow targeted modification of the DSDT.
 

Attachments

Last edited:
  • Like
Reactions: Bor10n and Edhawk
When press decompile - nothing :(
 

Attachments

  • Screenshot 2025-06-14 at 02.03.44.png
    Screenshot 2025-06-14 at 02.03.44.png
    1,018.7 KB · Views: 30
I should have provided some more explanation on the "universal" patches.

Once decompiled, there are always the same conditions on the problematic declaration blocks that have to be patched. There are some padding bytes between If() (opcode: A0) and the conditions (opcodes: 90 and 9232 for && and !=). The content of these bytes can vary from board to board, but as long as the DSDT is not massively rewritten so as to change the number of padding bytes (here two), it's possible to set a mask and have "universal" patches.

With a hex editor one can look for the core parts of the patches (excluding the A00000 part at the beginning):

#1: 90 92934730 30320A03 93473030 3001

#2: 90 92934730 30320A03 90934730 30300192 93473030 340C2210 FA43

#3: 90 92934730 30320A03 93473030 300A02

There should be a single occurence of each of #2 and #3 in the whole DSDT.aml and a single occurence of #1 that is preceded by A0xxxx (A0 and TWO bytes), plus a few occurences of #1 preceded by A0xxxxxx (THREE bytes, thus not patched).
I have so far confirmed the pattern in Asus ROG Strix B650E-F (reported working by the user), X670 Hero, X870 Hero, X870E ProArt, and AsRock X870E Taichi Lite, so I'm reasonable confident they are generic enough.
 

Attachments

Currently, I am using SSDT-Basic-600-700-AM5.aml, I have generated new SSDT-Force.aml. Disable SSDT-Basic-600-700-AM5.aml and clean Nvram, and during boot, I got errors. What is wrong?
 

Attachments

  • 20250623_221328.jpg
    20250623_221328.jpg
    1.1 MB · Views: 25
X870E ProArt
Hi etorix
In my experience with this motherboard no need of any acpi patches
I used it in the past before asus x870e hero i am using by now
 
  • Like
Reactions: etorix
I should have provided some more explanation on the "universal" patches.

Once decompiled, there are always the same conditions on the problematic declaration blocks that have to be patched. There are some padding bytes between If() (opcode: A0) and the conditions (opcodes: 90 and 9232 for && and !=). The content of these bytes can vary from board to board, but as long as the DSDT is not massively rewritten so as to change the number of padding bytes (here two), it's possible to set a mask and have "universal" patches.

With a hex editor one can look for the core parts of the patches (excluding the A00000 part at the beginning):

#1: 90 92934730 30320A03 93473030 3001

#2: 90 92934730 30320A03 90934730 30300192 93473030 340C2210 FA43

#3: 90 92934730 30320A03 93473030 300A02

There should be a single occurence of each of #2 and #3 in the whole DSDT.aml and a single occurence of #1 that is preceded by A0xxxx (A0 and TWO bytes), plus a few occurences of #1 preceded by A0xxxxxx (THREE bytes, thus not patched).
I have so far confirmed the pattern in Asus ROG Strix B650E-F (reported working by the user), X670 Hero, X870 Hero, X870E ProArt, and AsRock X870E Taichi Lite, so I'm reasonable confident they are generic enough.
My motherboard model is MSI X670E Gaming Plus WiFi. I used condevscan.py to scan the DSDT, and the results met the patch requirements. However, the system fails to boot after applying your patch. Below is the result of my scan:
Code:
  6297:        If ((IT8D == 0xAA))
  6299:            Device (RHPX)

  6992:    If (((G002 != 0x03) && (G000 == One)))
  6996:            Device (UP00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
  7797:                Device (DP00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
  7802:                Device (DP08)

  6992:    If (((G002 != 0x03) && (G000 == One)))
  8620:                    Device (EP00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
  9435:                Device (DP10)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 10253:                    Device (WN00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 11102:                Device (DP18)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 11920:                    Device (LN00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 12810:                Device (DP20)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 12815:                Device (DP28)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 13635:                Device (DP30)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 14453:                    Device (EP00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 15268:                Device (DP38)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 16086:                    Device (EP00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 16901:                Device (DP40)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 16906:                Device (DP48)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 17724:                    Device (EP00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 18539:                Device (DP50)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 19357:                    Device (EP00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 20172:                Device (DP58)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 20990:                    Device (EP00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 21805:                Device (DP60)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 22623:                    Device (XH00)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 23433:                Device (DP68)

  6992:    If (((G002 != 0x03) && (G000 == One)))
 24251:                    Device (SA00)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25459:            Device (XHUB)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25462:                Device (POT1)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25476:                Device (POT5)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25490:                Device (POT2)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25504:                Device (POT3)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25518:                Device (POT7)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25532:                Device (POT4)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25546:                Device (POT8)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25560:                Device (POT9)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25574:                Device (POTA)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25588:                Device (POT6)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25602:                Device (POTB)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25616:                Device (POTC)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25630:                Device (POTD)

 25454:    If (((G002 != 0x03) && ((G000 == One) && (G004 ==
 25644:                Device (POTE)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25666:            Device (RHUB)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25669:                Device (POT1)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25683:                Device (POT6)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25697:                Device (POT2)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25711:                Device (POT7)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25725:                Device (POT3)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25739:                Device (POT8)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25753:                Device (POT4)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25767:                Device (POT9)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25781:                Device (POT5)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25795:                Device (POTA)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25809:                Device (POTB)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25823:                Device (POTC)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25837:                Device (POTG)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25851:                Device (POTD)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25865:                Device (POTE)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25879:                Device (POTF)

 25661:    If (((G002 != 0x03) && ((G000 == One) && (
 25893:                Device (POTH)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 25914:            Device (XH00)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 26685:            Device (EP01)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 27468:            Device (UP02)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 28271:                Device (DP00)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 29055:                Device (DP40)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 29841:                    Device (NV00)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 30686:                Device (DP80)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 31467:                    Device (WN00)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 32273:                Device (DP90)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33054:                    Device (LN00)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33831:            Device (RHUB)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33834:                Device (POT1)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33848:                Device (POT5)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33862:                Device (POT2)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33876:                Device (POT6)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33890:                Device (POT3)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33904:                Device (POT7)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33918:                Device (POT4)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33932:                Device (POT8)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33946:                Device (PO9)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33960:                Device (PO10)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33974:                Device (PO11)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 33988:                Device (PO12)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 34002:                Device (PO13)

 25910:    If (((G002 != 0x03) && (G000 == 0x02)))
 34016:                Device (PO14)

 34913:    If (((G002 != 0x03) && ((G000 == One) && (
 35733:            Device (NV00)

 36621:    If (((G002 != 0x03) && ((G000 == One) && (
 37441:            Device (NV00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 38358:            Device (UP00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 39159:                Device (DP00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 39977:                    Device (NV00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 40804:                Device (DP08)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 41622:                    Device (EP00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 42437:                Device (DP10)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 43255:                    Device (WN00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 44104:                Device (DP18)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 44922:                    Device (LN00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 45832:                Device (DP20)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 46650:                    Device (NV00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 47584:                Device (DP28)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 48404:                Device (DP30)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 49222:                    Device (EP00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 49265:                Device (DP38)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 50083:                    Device (EP00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 50898:                Device (DP40)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 50903:                Device (DP48)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 51721:                    Device (EP00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 52536:                Device (DP50)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 53354:                    Device (EP00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 54169:                Device (DP58)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 54987:                    Device (EP00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 55802:                Device (DP60)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56620:                    Device (XH00)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56643:                        Device (RHUB)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56646:                            Device (POT1)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56660:                            Device (POT7)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56674:                            Device (POT2)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56688:                            Device (POT8)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56702:                            Device (POT3)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56716:                            Device (POT9)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56730:                            Device (POT4)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56744:                            Device (POTA)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56758:                            Device (POT5)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56772:                            Device (POTB)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56786:                            Device (POT6)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56800:                            Device (POTC)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56814:                            Device (POTG)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56828:                            Device (POTD)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56842:                            Device (POTE)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56856:                            Device (POTF)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 56870:                            Device (POTH)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 57672:                Device (DP68)

 38353:    If ((((G002 != 0x03) && (G000 == One)) && (
 58490:                    Device (SA00)

 59329:    If ((((G002 != 0x03) && (G000 == One)) && (
 60191:            Device (EP00)

 64518:    If ((G001 == One))
 64530:            Device (PEP)
 
Thanks for your reply. So my patches are not universal, as I hoped. :(

Patch #1: looks for If (((G002 != 0x03) && (G000 == One))) and forces creating UP00 and further devices under \_SB.PCI0.GPP7.
There are several occurences of this condition. So far the one I was looking to patch was precded by A0xxxx (A0 and two bytes), excluding further occurences with A0xxxxxx (three bytes).
With your MSI board, the occurence I want to patch is preceded by A0xxxxxx (3 bytes); those I do not want to patch have 4 bytes (twice) or two bytes.

Patch #2: looks for If (((G002 != 0x03) && ((G000 == One) && (G004 != 0x43FA1022)))) and forces creating RHUB under \_SB.PCI0.GPP7.UP00.DP60.XH00. Unchanged!

Patch #3: looks for If (((G002 != 0x03) && (G000 == 0x02))) and forces creating XH00 under \_SB.PCI0.GPP7.
I was expecting A0xxxx (2 bytes). Again, your MSI board there are 3 bytes (A0xxxxxx).

Please try these modified patches instead (#1a and #3a to replace #1 and #3).
 

Attachments

Thanks for your reply. So my patches are not universal, as I hoped. :(

Patch #1: looks for If (((G002 != 0x03) && (G000 == One))) and forces creating UP00 and further devices under \_SB.PCI0.GPP7.
There are several occurences of this condition. So far the one I was looking to patch was precded by A0xxxx (A0 and two bytes), excluding further occurences with A0xxxxxx (three bytes).
With your MSI board, the occurence I want to patch is preceded by A0xxxxxx (3 bytes); those I do not want to patch have 4 bytes (twice) or two bytes.

Patch #2: looks for If (((G002 != 0x03) && ((G000 == One) && (G004 != 0x43FA1022)))) and forces creating RHUB under \_SB.PCI0.GPP7.UP00.DP60.XH00. Unchanged!

Patch #3: looks for If (((G002 != 0x03) && (G000 == 0x02))) and forces creating XH00 under \_SB.PCI0.GPP7.
I was expecting A0xxxx (2 bytes). Again, your MSI board there are 3 bytes (A0xxxxxx).

Please try these modified patches instead (#1a and #3a to replace #1 and #3).
Sorry, I'm on vacation and unable to test in a timely manner. I will provide timely feedback once the testing is done.
Thank you for your understanding and patience in waiting.
 
@etorix
Sorry for the late reply. The patch has taken effect, yet the onboard Ethernet controller still fails to be recognized. It only works when I manually remove G000~G02D.
 
Thanks for your reply. So my patches are not universal, as I hoped. :(

Patch #1: looks for If (((G002 != 0x03) && (G000 == One))) and forces creating UP00 and further devices under \_SB.PCI0.GPP7.
There are several occurences of this condition. So far the one I was looking to patch was precded by A0xxxx (A0 and two bytes), excluding further occurences with A0xxxxxx (three bytes).
With your MSI board, the occurence I want to patch is preceded by A0xxxxxx (3 bytes); those I do not want to patch have 4 bytes (twice) or two bytes.

Patch #2: looks for If (((G002 != 0x03) && ((G000 == One) && (G004 != 0x43FA1022)))) and forces creating RHUB under \_SB.PCI0.GPP7.UP00.DP60.XH00. Unchanged!

Patch #3: looks for If (((G002 != 0x03) && (G000 == 0x02))) and forces creating XH00 under \_SB.PCI0.GPP7.
I was expecting A0xxxx (2 bytes). Again, your MSI board there are 3 bytes (A0xxxxxx).

Please try these modified patches instead (#1a and #3a to replace #1 and #3).
Will these patches work for my setup?
 
(Context here.)
Yes, you have an Asus board, I took a quick look at the DSDT, and saw the same patterns as any other Asus/Gigabyte/non-MSI board so far so the patches should work and get you a step closer. These won't correct the ACPI errors from G02F and G027 but I don't think that these are blocking.
 
In a further twist, AsRock B650E Steel Legend and X670E PG Lightning have been found to fit the patterns for MSI boards, while AsRock X870E Taichi Lite fits the "general" patterns … which are not so general, and just looking at the manufacturer may not be good enough.

Which leaves my "Universal Patches" in this unfortunate situation:
itdepends.jpg

The Problem​

Modern DSDT tables (Intel and AMD) refer to configuration variables (G000 and so forth…) from "Operational Regions" in RAM, and then conditionally initialise devices accordingly. macOS operates according to an outdated version of the APCI specification, does not read these variables properly, does not correctly evaluates the conditions and fails to create ACPI devices it should.
This affects PCIe devices hanging from the B650/X650 and newer chipsets, including USB controllers and network controllers.

Syntax and ACPI code may differ by motherboard and by BIOS version for the same motherboard, but so far there are mainly three offending snippets in the DSDT:
If (((G002 != 0x03) && (G000 == One))) responsible for creating the whole hierarchy of devices under _SB.PCI0.GPP7, including USB controllers
If (((G002 != 0x03) && ((G000 == One) && (G004 != 0x43FA1022)))) responsible for creating RHUB under the USB controllers which are deep under GPP7
If (((G002 != 0x03) && (G000 == 0x02))) further responsible for creating USB controller XH00 directly under GPP7
This may change with future BIOS updates, and may well require further analysis to determine what is really needed.

The Solution(s)​

  • Painstakingly edit your DSDT and drop the original one. Generally advised against…

  • Use OpenCore to apply ACPI patches on the fly. But you need patches…
    1. Work these out.
    2. Ask CorpGhost for ACPI patches for your motherboard and current BIOS (i.e. your current DSDT).
    3. Use my semi-generic patches.
Nobody can blame you for going with option 2… But this may need to be rechecked and redone with every BIOS update.

For Intel, Dortania came up with generic ACPI patches using masks for variable parts. With option 3 I tried to apply this method to make generic patches for AMD boards, but it turns out that there's more variability in ACPI code than with Intel, and the mask itself needs to be of variable length. So there are different patches with different masks after all… but the mask part should still make these more resilient to BIOS updates.

Which patches to use?​

letmeexplain.jpg

To find out, you'll need your DSDT in AML binary form and an hex editor such as Hex Fiend.

Patches come in the form
Find: A0000090 92934730 30320A03 93473030 3001
Mask: FF0000FF FFFFFFFF FFFFFFFF FFFFFFFF FFFF
Replace: A3A3A3A3 A3A3A3A3 A3A3A3A3 A3A3A3A3 A3A3
All three parts should be of the same length. 'FF' in mask means that we care about this byte ('Find' needs to match); '00' means that this is ignored for matching. 'A0' is ACPI OpCode for 'If', the '00' bytes just after are padding and ignored for matching, the non-zero bytes are the condition (if you want to decipher it, Section 20.3 of the ACPI Specification is your friend…). 'A3' is NoOp.

To check whether the patches are suitable, take the condition part in Find:, leaving out 'A000…00', and search for it in the DSDT with the hex editor. Locate the nearest 'A0' before the search string and count the bytes in-between. Repeat until you have found all occurrences.

Patch #1
Search for 90 92934730 30320A03 93473030 3001
The first hit should be the one we're after, and the only one with this number of padding bytes.
If it has TWO bytes (four hex digits) of padding between 'A0' and '90…', use version #1 (mask 'FF0000FF…' ).
If it has THREE bytes of padding (six hex digits), use version #1a (mask 'FF000000FF…') in the MSI plist.
To confirm, search for further occurrences of the pattern, of which there should be several, and count the padding bytes:
Multiple occurrences with three padding bytes => version #1
Multiple occurrences with four padding bytes, or a mix of four and two padding bytes => version #1a

v1.jpg

v1A.jpg

(to understand what we are looking at, we need to read AML opcodes… or find some context elements in the DSDT to confirm, such as the obvious long 'FundamentalDeviceReset' string in the above AsRock X670E; in both cases the condition is followed by _SB_PCI0GPP7 and then UPP00, the scope and the first of many devices created under it)

padding.jpg

(we are not interested in patching this one, but if there is more than one occurrence with the same number of padding bytes as in the one that we want to patch we could be in trouble)

Patch #2
Search for 90 92934730 30320A03 90934730 30300192 93473030 340C2210 FA43
There should be one occurrence in the whole DSDT, with two padding bytes between 'A0' and the pattern: Version #2 applies.

Patch #3
Search for 90 92934730 30320A03 93473030 300A02
There should be one occurrence in the whole DSDT.
TWO bytes (four hex digits) of padding between 'A0' and '90…' => version #3 (mask 'FF0000FF…' ) in the original generic plist.
THREE bytes of padding (six hex digits) => version #3a (mask 'FF000000FF…') in the MSI plist (even if your motherboard is not MSI).


If what you find does not fit the above cases, a new version may be necessary…
So far there is a total of five patches in two sets of three:
#1, #2 and #3 (original generic set), found in multiple Asus boards and limited samples (one?) from Gigabyte and AsRock
#1a, #2 and #3a found in MSI boards and two AsRock
For simplicity and avoidance of doubt (not releasing multiple zip files with the same content under different names), I re-attach the two sets as already posted above under the same names: am5_patches ("generic") and am5_patches _msi ('a' versions,not only for MSI… and maybe not even for all MSI boards).
Do not trust the names alone: Check with your DSDT.

Disclaimer

I am no guru. I'm not even trained in IT. It would be fair to say I know enough to be occasionally dangerous. As of this writing I have even never attempted an AMD hackintosh. But it seems that my patches work.
Use carefully, and please report what works and what doesn't.
 

Attachments

Last edited:
  • Like
Reactions: Edhawk
  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.