Asus X670E Gene EFI -- Adaptable to Other X670, X670E, B650 and B650E Boards

karatefylla

New member
AMD OS X Member
Joined
Nov 29, 2023
Messages
6
Hi,

First, thanks for all the work you people have done! If anyone has some time and can check my EFI I'm struggling with, I would be more than greatful.
I have a Monterey install that I previously used with an Intel 6700k and an Asus z170-a board.
Now I would like to use that install with my new HW.
It doesn't work on every boot but when it works it's stable.

When it crashes: verbose text, black screen, reboots
Or if it works: verbose text, black screen, login window


System Specs:
Asus Rog Strix X670E-F Gaming Wifi
Ryzen 9 7950x
Kingston 64GB (2K) DDR5 6000MHz FURY Beast B
Radeon 6650XT
MAC OS Monterey
USB Audiointerface
3x NVME SSD
4x SATA SSD

Disabled in bios: wifi, bluetooth, igpu

Here is my EFI.

Thank you!!
 

Attachments

  • efi_files.zip
    6.9 MB · Views: 39
  • Mac Pro.ioreg.zip
    4.4 MB · Views: 11

CaseySJ

Guru
Guru
Donator
Joined
May 10, 2020
Messages
1,269
Where do you copy the EFI folder to in order for the hackintosh to boot without the usb?
Because you're asking a very basic question, it may help to skim through the build procedure for Asus Z690 ProArt Creator at the link below. Even though that procedure is tailored for a different motherboard, it provides a good overview and covers many of the basics.

Screenshot 2023-12-19 at 9.19.21 AM.pngScreenshot 2023-12-19 at 9.18.55 AM.png
 

CaseySJ

Guru
Guru
Donator
Joined
May 10, 2020
Messages
1,269
Hi,

First, thanks for all the work you people have done! If anyone has some time and can check my EFI I'm struggling with, I would be more than greatful.
I have a Monterey install that I previously used with an Intel 6700k and an Asus z170-a board.
Now I would like to use that install with my new HW.
It doesn't work on every boot but when it works it's stable.

When it crashes: verbose text, black screen, reboots
Or if it works: verbose text, black screen, login window


System Specs:
Asus Rog Strix X670E-F Gaming Wifi
Ryzen 9 7950x
Kingston 64GB (2K) DDR5 6000MHz FURY Beast B
Radeon 6650XT
MAC OS Monterey
USB Audiointerface
3x NVME SSD
4x SATA SSD

Disabled in bios: wifi, bluetooth, igpu

Here is my EFI.

Thank you!!
Good job putting together the OC configuration. First thought that comes to mind: Disable AmdTscSync.kext.
 

karatefylla

New member
AMD OS X Member
Joined
Nov 29, 2023
Messages
6
Good job putting together the OC configuration. First thought that comes to mind: Disable AmdTscSync.kext.
Thanks for the reply CaseySJ! :) I disabled AmdTscSync.kext but it's the same issue still. Anything else I can try?
 

CaseySJ

Guru
Guru
Donator
Joined
May 10, 2020
Messages
1,269
Thanks for the reply CaseySJ! :) I disabled AmdTscSync.kext but it's the same issue still. Anything else I can try?
Because this system was transplanted from an Intel-based Hackintosh, and because the crash seems intermittent, I would suggest:
  • Creating a new APFS Volume (using Disk Utility) in the same NVMe SSD as the main system OR on a different SSD if you have one
  • Install fresh copy of macOS using the same EFI folder
  • Boot the fresh copy of macOS and see whether it is stable
  • If it is, then we know EFI Folder is not the problem; instead, the problem may be due to a third-party software component in the transplanted copy of macOS
 

karatefylla

New member
AMD OS X Member
Joined
Nov 29, 2023
Messages
6
Because this system was transplanted from an Intel-based Hackintosh, and because the crash seems intermittent, I would suggest:
  • Creating a new APFS Volume (using Disk Utility) in the same NVMe SSD as the main system OR on a different SSD if you have one
  • Install fresh copy of macOS using the same EFI folder
  • Boot the fresh copy of macOS and see whether it is stable
  • If it is, then we know EFI Folder is not the problem; instead, the problem may be due to a third-party software component in the transplanted copy of macOS
I will try this :). Thanks again!
 

agent2

Donator
Donator
Joined
May 3, 2020
Messages
160
Hey @CaseySJ, I'm loving the work on this project so far! I have been using your config for the last year and it helped me save a ton of time!
Would it be possible for you to update this thread and the corresponding posts to the current OpenCore version and for macOS Sonoma? That would be super.
I have been trying to update my X670E Gene system to this OS and I am not sure how to get it back as smooth as with Ventura.
My system had a very hard time updating, and I have very limited success getting macOS to boot without boot loops. And on top of that my 2.5Gb LAN also stopped working now so I am considering using your "outdated" EFI and starting my configuration from scratch, as I don't know what to pin the issue on. I was suspecting it could have to do with the kernel patches as you added many on top of the stock AMD ones, but it's just a hunch.
Any updates to this system and your help would be much appreciated!
Cheers and a jolly Christmas!
 

agarcia415mile

New member
AMD OS X Member
Joined
Dec 21, 2023
Messages
7
So I tried , but have not had luck.

I'll list my setup first, and my attempts next.

ComponentModel
MotherboardAsus ROG Strix B650E-F
CPUAMD Ryzen 9 7900X
MemoryG.Skill Flare X5 16GB 6000MHz
GPUMSI Radeon RX 6800
WLAN & BluetoothMediaTek RZ608 Wi-Fi 6E 80MHz
ChassisSome CyberPower bought chassis from a prebuilt
Storage NVMeWD Black SN850x 2TB NVMe
Storage NVMeSK hynix Platinum P41 2TB
Storage NVMeKingston SKC3000S1024G 1TB
Storage NVMeCrucial P5 Plus 2TB
Storage SSDApple SM512E 500GB
Storage SSDWDC WDS500G2b0a 500Gb
Storage HDWDC WDS500G2b0a 500Gb
Storage HDWDC WD10JPLX-00MBPT0 1TB
Storage HDWDC WD80EMAZ-00WJTA0 8TB


The closest I got was with the 0.9.7 version while I was on BIOS 1222. The output logs from that are here. The EFI and Configs I used are in the same folder.

I was using 0.9.7 debug version. After numerous attempts, I tried adapting my configs to this person's successful attempt.

Not quite sure what my issue is! but I can't seem to get it to work. My most recent attempts on BIOS 1654 are listed in the parent folder of my forked repo here. I would love to be able to make this work, ,but am at a loss as how to proceed . Does that log make sense to anyone here? Any thoughts on where to go next?
 

CaseySJ

Guru
Guru
Donator
Joined
May 10, 2020
Messages
1,269
Hey @CaseySJ, I'm loving the work on this project so far! I have been using your config for the last year and it helped me save a ton of time!
Would it be possible for you to update this thread and the corresponding posts to the current OpenCore version and for macOS Sonoma? That would be super.
I have been trying to update my X670E Gene system to this OS and I am not sure how to get it back as smooth as with Ventura.
My system had a very hard time updating, and I have very limited success getting macOS to boot without boot loops. And on top of that my 2.5Gb LAN also stopped working now so I am considering using your "outdated" EFI and starting my configuration from scratch, as I don't know what to pin the issue on. I was suspecting it could have to do with the kernel patches as you added many on top of the stock AMD ones, but it's just a hunch.
Any updates to this system and your help would be much appreciated!
Cheers and a jolly Christmas!
That's a good suggestion. I'm currently away from home for the holidays, but will do this when I return. Meanwhile, I'm also having problems with 2.5GbE on Sonoma only, which I wrote about here:
 

CaseySJ

Guru
Guru
Donator
Joined
May 10, 2020
Messages
1,269
So I tried , but have not had luck.

I'll list my setup first, and my attempts next.

ComponentModel
MotherboardAsus ROG Strix B650E-F
CPUAMD Ryzen 9 7900X
MemoryG.Skill Flare X5 16GB 6000MHz
GPUMSI Radeon RX 6800
WLAN & BluetoothMediaTek RZ608 Wi-Fi 6E 80MHz
ChassisSome CyberPower bought chassis from a prebuilt
Storage NVMeWD Black SN850x 2TB NVMe
Storage NVMeSK hynix Platinum P41 2TB
Storage NVMeKingston SKC3000S1024G 1TB
Storage NVMeCrucial P5 Plus 2TB
Storage SSDApple SM512E 500GB
Storage SSDWDC WDS500G2b0a 500Gb
Storage HDWDC WDS500G2b0a 500Gb
Storage HDWDC WD10JPLX-00MBPT0 1TB
Storage HDWDC WD80EMAZ-00WJTA0 8TB


The closest I got was with the 0.9.7 version while I was on BIOS 1222. The output logs from that are here. The EFI and Configs I used are in the same folder.

I was using 0.9.7 debug version. After numerous attempts, I tried adapting my configs to this person's successful attempt.

Not quite sure what my issue is! but I can't seem to get it to work. My most recent attempts on BIOS 1654 are listed in the parent folder of my forked repo here. I would love to be able to make this work, ,but am at a loss as how to proceed . Does that log make sense to anyone here? Any thoughts on where to go next?

Some questions:
  • Are you installing macOS Sonoma 14.2 as mentioned in your GitHub fork?
  • I downloaded the EFI folder; some comments:
    • Are you using the EFI Folder under Attempts -> 9?
      • This one is for Asus X670E Gene
      • Moreover, the settings inside your copy of the folder are incorrect
    • Or the EFI Folder at root level?
      • If you're using this folder, the SSDT SSDT-ASUS-B650E-F.aml has a problem as shown below:
Screenshot 2023-12-23 at 8.43.44 AM.png

We just combine all USB controllers into one USBW device as shown here:

Screenshot 2023-12-23 at 8.51.49 AM.png
Additionally:
  • Does the OpenCore boot menu appear?
  • Are you able to launch "Install macOS Sonoma" from the OpenCore boot menu?
  • Because -v is included in boot-args, you should see a lot of boot log message on screen; at what point do these messages freeze? Feel free to take photo and post it (but remove GPS location information for your privacy -- this can be done by uploading the photo to https://jimpl.com)
 

agarcia415mile

New member
AMD OS X Member
Joined
Dec 21, 2023
Messages
7
Actually, that is incorrect. I updated the Git, thanks. I'm using the Ventura (13) script from the macrecovery script in the /Utilities/macrecovery/ of OpenCore 0.9.6.
python3 macrecovery.py -b Mac-4B682C642B45593E -m 00000000000000000 download
which gave me a BaseSystem.chunklist and BaseSystem.dmg in an com.apple.recovery.boot folder

I'm not sure which version that outputs.... but whatever works! I just need to be able to run some XCode.

I'm using the EFI in the parent folder, I know yours is specific to X670E, but I just wanted to try it to see how far it goes.

Additionally:
Yes, the boot menu appears.
No, I only see 2 icons that both say "Windows".
The messages freeze after "Watchdog Status is 1".

I've got a picture of the output here. Note: This output is AFTER I went ahead and applied your suggestions to the aml file. Thank you for pointing that out.

As of now, I'm still stuck in the same spot. So much harder that I thought it'd be!
hMDKpC0.jpg
 

CaseySJ

Guru
Guru
Donator
Joined
May 10, 2020
Messages
1,269
Actually, that is incorrect. I updated the Git, thanks. I'm using the Ventura (13) script from the macrecovery script in the /Utilities/macrecovery/ of OpenCore 0.9.6.
python3 macrecovery.py -b Mac-4B682C642B45593E -m 00000000000000000 download
which gave me a BaseSystem.chunklist and BaseSystem.dmg in an com.apple.recovery.boot folder

I'm not sure which version that outputs.... but whatever works! I just need to be able to run some XCode.

I'm using the EFI in the parent folder, I know yours is specific to X670E, but I just wanted to try it to see how far it goes.

Additionally:
Yes, the boot menu appears.
No, I only see 2 icons that both say "Windows".
The messages freeze after "Watchdog Status is 1".

I've got a picture of the output here. Note: This output is AFTER I went ahead and applied your suggestions to the aml file. Thank you for pointing that out.

As of now, I'm still stuck in the same spot. So much harder that I thought it'd be!
Because "Install macOS Ventura" is not present in OpenCore boot picker, it means there is no valid macOS installer.

Please try STEP 1 and STEP 2 in the link below to create a USB install disk for Ventura.

Screenshot 2023-12-23 at 12.59.26 PM.png

Then copy your EFI folder to the EFI partition of that USB flash disk and boot from the USB flash disk (press F8 at Asus splash screen to open the BIOS boot menu and select the USB flash disk).

You may also try the attached config.plist. Just make a backup of the original before using the attached version.

At this point you should see a boot option called "Install macOS Ventura".

Let's see if we can get to this point.
 

Attachments

  • config.plist.zip
    6 KB · Views: 2
Last edited:

Lorys89

Active member
AMD OS X Member
Joined
Dec 16, 2022
Messages
183
View attachment 12961

We just combine all USB controllers into one USBW device as shown here:

View attachment 12962

hi casey, I think differently about this note of yours, each xhc controller has its own _PRW method and I think it is more correct that each controller refers to its own _PRW method. then if you think it is correct to use this way, explain to me, I would like to understand. I wish you and the entire forum a Merry Christmas.
 

CaseySJ

Guru
Guru
Donator
Joined
May 10, 2020
Messages
1,269
hi casey, I think differently about this note of yours, each xhc controller has its own _PRW method and I think it is more correct that each controller refers to its own _PRW method. then if you think it is correct to use this way, explain to me, I would like to understand. I wish you and the entire forum a Merry Christmas.
The USBW device is only used by USBWakeFixup.kext. The kext specifically looks for an ACPI device named USBW and invokes the _PRW method inside that device.

So if we create a separate ACPI device for each USB controller such as USBR, USBZ, USBY then those devices are simply ignored unless we modify the kext to look for them.

Screenshot 2023-12-23 at 8.43.44 AM.png

Now let's look at the screenshot above and the screenshot below. The screenshot above is creating separate ACPI device names, each with their own _PRW method. And each of those methods just calls the _PRW method of the USB controller, like this:

...XH00._PRW()
...XHC0._PRW()
...XHC1._PRW()


In the screenshot below we see that the same native _PRW methods are being invoked for each USB controller, but all of this is happening within a single USBW device that the kext recognizes. Each _PRW method can invoke its own parameters for GPRW ( x , y ).
Screenshot 2023-12-23 at 8.51.49 AM.png
Happy Holidays!
 
Last edited:

agarcia415mile

New member
AMD OS X Member
Joined
Dec 21, 2023
Messages
7
Because "Install macOS Ventura" is not present in OpenCore boot picker, it means there is no valid macOS installer.

Please try STEP 1 and STEP 2 in the link below to create a USB install disk for Ventura.

View attachment 12968

Then copy your EFI folder to the EFI partition of that USB flash disk and boot from the USB flash disk (press F8 at Asus splash screen to open the BIOS boot menu and select the USB flash disk).

You may also try the attached config.plist. Just make a backup of the original before using the attached version.

At this point you should see a boot option called "Install macOS Ventura".

Let's see if we can get to this point.

That got me farther!
With my current EFI (same as in the Repo here), I could see the icon for "install Mac OS Ventura" icon, click it, and see output start to happen.

With the same EFI, but using your config file, I had the same outcome, but did not see the OS icons, just text.
Both of them ended up on a screen with a couple of images that would repeat. 1 image shoed a side view of a laptop and the other showed top view of a desktop. Both indicated some kind green "turn on" button that I guess I had to press? I could see my mouse, but couldn't move it. Maybe my USBs were not detected?
 

Attachments

  • opencore-2023-12-23-124039-CaseyConfig.txt
    256 KB · Views: 1
  • opencore-2023-12-23-123129-GitConfigs.txt
    256 KB · Views: 0

CaseySJ

Guru
Guru
Donator
Joined
May 10, 2020
Messages
1,269
That got me farther!
With my current EFI (same as in the Repo here), I could see the icon for "install Mac OS Ventura" icon, click it, and see output start to happen.

With the same EFI, but using your config file, I had the same outcome, but did not see the OS icons, just text.
Both of them ended up on a screen with a couple of images that would repeat. 1 image shoed a side view of a laptop and the other showed top view of a desktop. Both indicated some kind green "turn on" button that I guess I had to press? I could see my mouse, but couldn't move it. Maybe my USBs were not detected?
At this point we can ignore the OpenCore log. Instead, simply post a photo of the screen but remove EXIF location information by uploading the photo to https://jimpl.com and selecting the option to remove location information.
 

Lorys89

Active member
AMD OS X Member
Joined
Dec 16, 2022
Messages
183
The USBW device is only used by USBWakeFixup.kext. The kext specifically looks for an ACPI device named USBW and invokes the _PRW method inside that device.

So if we create a separate ACPI device for each USB controller such as USBR, USBZ, USBY then those devices are simply ignored unless we modify the kext to look for them.

View attachment 12971

Now let's look at the screenshot above and the screenshot below. The screenshot above is creating separate ACPI device names, each with their own _PRW method. And each of those methods just calls the _PRW method of the USB controller, like this:

...XH00._PRW()
...XHC0._PRW()
...XHC1._PRW()


In the screenshot below we see that the same native _PRW methods are being invoked for each USB controller, but all of this is happening within a single USBW device that the kext recognizes. Each _PRW method can invoke its own parameters for GPRW ( x , y ).
View attachment 12972
Happy Holidays!
hi casey, I think you haven't studied the kext, the kext searches for PNP0D10, and activates its function in the acpi paths where it finds it and not just on the one defined as usbw with the return to only 1 _PRW method.


a single usbw device can only have 1 return to the _PRW method and only that one is called, if you want to call the _PRW methods of each xhc controller you need to divide them as I created by dividing them usbz, usbw, usby.
so each xhc controller has its return to the native _PRW method and the kext works, obviously originally I used your method but the 1 touch awakening from the remaining xhc controllers didn't work but only from the one where there was the return.
I hope I explained myself :)
 

CaseySJ

Guru
Guru
Donator
Joined
May 10, 2020
Messages
1,269
@Lorys89,

Very good points. I had not read the source code until now.

If you have already tested the multi-device method and it works from all USB controllers, then your implementation is correct. Different motherboards may work differently depending on how their _GPE methods are defined. If we look at the technical explanation below, we see the conditions under which this workaround is needed.

There is a more detailed explanation located here:


Some excerpts:

When you press a key on the keyboard, the USB device sends an interrupt to the USB XHCI controller which wakes it up. The XHCI controller then wakes up the PCH which wakes up the processor through the PCIe interface through the PME# signal. The PCH maps all the PME# signals from its various internal controllers into a single GPE, which is seen by the processor. On the Intel 100 series PCH, the USB, LAN, HDA, and SATA controllers share a single GPE (0x6D). These controllers are seen by the processor as separate PCIe devices, but are all implemented internally in the PCH (a single chip) and controls different protocols. As an aside, the PCH also has PCIe controllers which acts as a PCIe root bus to the processor. The PME# signals for those map to a separate GPE (0x6B).

If multiple PCI devices can map to a single GPE interrupt signal, then how does the operating system know which device caused the interrupt? There are two ways OSX checks.

First, if the system has an Embedded Controller (most modern laptops do for battery management), then the GPE is effectively ignored (it's seen as a "legacy feature"). The EC provides much more information about what caused the interrupt and can even differentiate between events such as "low battery" and "battery charged" even though they come from the same event source.

On the NUC (and many other desktop systems), there is no EC and then OSX falls back to using the GPE. By querying the ACPI tables, OSX can get a list of all possible event sources corresponding to a single GPE. It then does a series of filtering actions.
...

Workaround​

So now that we understand the issue, our workaround for the issue introduced by Intel's workaround is simple. We create a new "fake" (non-PCI) ACPI device and claim that it is associated with the 0x6D GPE. Then we add the acpi-wake-type property to the fake device with a fake driver. Then when OSX attempts to identify the "source" of the wakeup, it will see our fake device and assume that was the source.

But that's not all. Remember there is a priority of wake types? Remember that GPE 0x6D is shared with LAN, HDA, and SATA? Well HDA and SATA don't have a special wake type, so they're the same priority as USB. But LAN falls under the "Network" type which has lower priority than USB's "User" type. A proper fix would have to somehow differentiate between a USB wakeup and a LAN wakeup. It might not even be possible due to Intel trashing the USB's PMCS register. Fortunately for us though, the third party LAN drivers we use don't support wake-on-lan so it's not an issue.
 
Last edited:

agarcia415mile

New member
AMD OS X Member
Joined
Dec 21, 2023
Messages
7
At this point we can ignore the OpenCore log. Instead, simply post a photo of the screen but remove EXIF location information by uploading the photo to https://jimpl.com and selecting the option to remove location information.

Ok, fantastic. I am able to get to the Disk Utility screen and I was able to format the destination disk as Mac Journaled. Unfortunately, I got the "macOS Ventura is not compatible with this Mac." Screen when I tried installing.
I then tried converting the Disk to APFS, but that did not help either. I also tried resstoring an older OCLP OS, but I couldn't get there without getting the OS installed.

I'm not sure what happened between now and yesterday, but I just used your configs again with the OS I downloaded.

I couldn't find see that initial screen I saw, with the alternating Desktop/Laptop images, but I'm not complaining. The EFI here is what I used. I guess, I'm slowly getting there! What do you think I need to do in order to get around the "not compatible" screen?
EDIT: In case the logs are needed, the most recent attempt, was either this or this one. I suspect it's the latter, since the timestamp is multiple hours ahead, almost like it indicates a UTC timestamp?
 

Attachments

  • Screenshot_20231224_142057_Gallery (1).jpg
    Screenshot_20231224_142057_Gallery (1).jpg
    197.5 KB · Views: 12
  • Screenshot_20231224_142433_Gallery (1).jpg
    Screenshot_20231224_142433_Gallery (1).jpg
    195.4 KB · Views: 5
  • Screenshot_20231224_142459_Gallery (1).jpg
    Screenshot_20231224_142459_Gallery (1).jpg
    201.4 KB · Views: 5
Last edited:

CaseySJ

Guru
Guru
Donator
Joined
May 10, 2020
Messages
1,269
Ok, fantastic. I am able to get to the Disk Utility screen and I was able to format the destination disk as Mac Journaled. Unfortunately, I got the "macOS Ventura is not compatible with this Mac." Screen when I tried installing.
I then tried converting the Disk to APFS, but that did not help either. I also tried resstoring an older OCLP OS, but I couldn't get there without getting the OS installed.

I'm not sure what happened between now and yesterday, but I just used your configs again with the OS I downloaded.

I couldn't find see that initial screen I saw, with the alternating Desktop/Laptop images, but I'm not complaining. The EFI here is what I used. I guess, I'm slowly getting there! What do you think I need to do in order to get around the "not compatible" screen?
EDIT: In case the logs are needed, the most recent attempt, was either this or this one. I suspect it's the latter, since the timestamp is multiple hours ahead, almost like it indicates a UTC timestamp?
Some suggestions:
  • Please try attached config.plist, which should enable the OpenCore Boot Picker (it's based on the latest version posted to your GitHub repo)
  • Start the macOS Ventura installer once again and open Terminal from the Tools menu and type date
    • Are the date and time both correct or within a few hours of local time?
    • The year should be 2023 (not 1970 or 1960 ...)
  • If date and time are reasonable, try installing macOS again, but this time open the installer log window by pressing CMD-L
    • Then on the upper right side of the log window you will see a pop menu
    • Click that menu and select All Logs (not just errors or warnings)
  • If you again see "Ventura is not compatible with this computer", post a photo of the installer log
Another option is to re-generate all serial numbers, which we can do as follows (using OpenCore Configurator):
Screenshot 2023-12-25 at 8.58.00 AM.png
 

Attachments

  • config.plist.zip
    6 KB · Views: 6
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.