Contribute
Register

Solved > Inject audio HDMI with custom values - APPLEHDA (appleHDAcontroller.kext) gtx970

Joined
Apr 22, 2021
Messages
128
Motherboard
MSI B150M BAZOOKA (U3E1)
CPU
i5 6500
Graphics
GTX 970
Mac
  1. iMac
  2. Mac mini
Mobile Phone
  1. Android
Hi all, I'm trying to modify the AppleALC kext by inserting certain values, to make AppleHDA recognize the address of my HDAU device.
I'm using AppleALC v. 1.5.9 and all ports are running except HDMI output of my GTX970.

So I want to inject the code in AppleALC before build the kext and later use clover to patch AppleHDAController to recognize the device HDAU.

In ioregistryexplorer, these are the informations of my HDAU.
- IoName = pci10de,fbb. ----- 10de0fbb
- Device id = <bb 0f 00 00>

In appleALC, downloaded the source code, in resources/controller.plist. searching for NVIDIA HDMI for GM204, I found in 5/Patches/0:
- Find = 4E564441 --------------------------- ????? I don't know how to insert in this line
- Replace = DE10BB0F



Then in Clover/Config.plist/KernelAndKextPatches/KextsToPatch/0:
Comment - string - 10.13.6-Nvidia_HDMI_Audio
Disabled - Boolean - NO
Find - Data - DE101A0E --------------------------- ????? I don't know how to insert in this line
InfoPlistPatch - Boolean - NO
MatchOS - String - 10.13.6
Name - String - com.apple.driver.AppleHDAController
Replace - Data -
DE10BB0F



Could anyone help me?

Thank you!
 
Joined
Apr 22, 2021
Messages
128
Motherboard
MSI B150M BAZOOKA (U3E1)
CPU
i5 6500
Graphics
GTX 970
Mac
  1. iMac
  2. Mac mini
Mobile Phone
  1. Android
I was able to solve the HDMI audio problem with the gtx970:

Follow this link.
 
Last edited:
Joined
Mar 18, 2020
Messages
73
Motherboard
ASRock W480 Creator
CPU
i9-10850K
Graphics
GT 710
Mac
  1. MacBook Pro
I was able to solve the HDMI audio problem with the gtx970:



High Sierra 10.13.6 (17G65)
HDAU device injected by SSDT.
AppleALC 1.5.2
LILU 1.4.7
Xcode Version 10.1 (10B61)

PATCH to ControllerHDA
- First we open the config.plist and in the kernelekextpatches section, we insert a new element 0 in patches, in which we are going to insert this:

Comment - string - 10.13.6-Nvidia_HDMI_Audio
Disabled - Boolean - NO
Find - Data - DE101A0E (old address to be replaced)
InfoPlistPatch - Boolean - NO
MatchOS - String - 10.13.6
Name - String - com.apple.driver.AppleHDAController
Replace - Data - DE10BB0F


The purple address is that of my HDAU device. (injected via SSDT, for the GTX970)
- To search for it, open ioreg and search for audio. Go to the HDAU device and search for: id-device and Ioname. In ioname, I have the same address as the ID device, but written in the way we need it:
10DE0FBB - only is written by inverting the bits: DE10BB0F


PATCH to AppleALC
- Download the version suitable for the XCODE compiler. As long as it is beyond 1.4. I used 1.5.6 with Lilu version 1.4.7.
Download the source code. Which will then be compiled. Di lilu, download both the source code.zip and the RELEASE (ie already compiled) = this we will then put in EFI.
- Let's compile LILU first. Then in the path: / Users / “pc name” / Library / Developer / Xcode. We take the kext, and inside its folder we find the built version.

- Open the AppleALC / Resources / controller.plist folder. Search for GM204 and under item you enter:

Count - Number - 1
Find - Data - de100b0e
MinKernel - Number - 17
Name - String - AppleHDAController
Replace - Data - DE10BB0F


- After saving you need to insert the kext built first in the AppleALC folder, and then open the Xcode project file and compile it!
- After taking the new file, / Users / “pc name” / Library / Developer / Xcode / AppleALC etc .. Copy it to EFI / Clover / Kext / Others. Together with the LILU release and the config.plist.

Upon reboot, the HDMI audio device will be available!
I'm trying to adapt this to OpenCore. Can someone help me with this, please?
In my case, in ioregistryexplorer, these are the informations of my HDAU.
- IoName = ppci10de,e0f. ----- 10de0e0f
- Device id = <0f 0e 00 00>

I don't know anything about this or if it applies to OpenCore:
HDAU device injected by SSDT
So I can add this (with modification in the "Replace..." line, to Kernal/Patch:
Comment - string - 10.13.6-Nvidia_HDMI_Audio
Disabled - Boolean - NO
Find - Data - DE101A0E (old address to be replaced)
InfoPlistPatch - Boolean - NO
MatchOS - String - 10.13.6
Name - String - com.apple.driver.AppleHDAController
Replace - Data - DE100F0E
I haven't yet tried the third step, relating to "PATCH to AppleALC".
 
Joined
Apr 22, 2021
Messages
128
Motherboard
MSI B150M BAZOOKA (U3E1)
CPU
i5 6500
Graphics
GTX 970
Mac
  1. iMac
  2. Mac mini
Mobile Phone
  1. Android
Hello ckrueger99, in config.plist to Kernel/Patch, you have to insert:

Name Find Replace
com.apple.driver.AppleHDAController DE101A0E DE100F0E

then in AppleALC/Resources/Controller.plist you have to find your gpu I think is GK208B.
(In my case is GM204 GPU) So replace in GK208 with DE100F0E. Build Kext and install it in EFI.

I have checked and this value is already set in AppleALC. So I Think you need only to modify config.plist.
But check anyway
 
Joined
Apr 22, 2021
Messages
128
Motherboard
MSI B150M BAZOOKA (U3E1)
CPU
i5 6500
Graphics
GTX 970
Mac
  1. iMac
  2. Mac mini
Mobile Phone
  1. Android
Info GT710
 
Joined
Mar 18, 2020
Messages
73
Motherboard
ASRock W480 Creator
CPU
i9-10850K
Graphics
GT 710
Mac
  1. MacBook Pro
Hello ckrueger99, in config.plist to Kernel/Patch, you have to insert:

Name Find Replace
com.apple.driver.AppleHDAController DE101A0E DE100F0E

then in AppleALC/Resources/Controller.plist you have to find your gpu I think is GK208B.
(In my case is GM204 GPU) So replace in GK208 with DE100F0E. Build Kext and install it in EFI.

I have checked and this value is already set. So I Think you need only to modify config.plist

Info GT710
Thank you!

For the SSDT, is it correct to follow the procedure outlined here?: https://www.tonymacx86.com/threads/ssdt-gpu-graphics-card-injection.183354/
 
Joined
Apr 22, 2021
Messages
128
Motherboard
MSI B150M BAZOOKA (U3E1)
CPU
i5 6500
Graphics
GTX 970
Mac
  1. iMac
  2. Mac mini
Mobile Phone
  1. Android
Yes in short words, in the guide it says to go and create a ssdt in which the two values in the PEG0 device in DSDT (in my case), PEGP and D053 they are canceled and replaced by those of the ssdt.

How to cancel? With these lines that you must insert at the end of SSDT (before the last brackets) as in mine, that I am attaching.

Name (\_SB.PCI0.PEG0.D053._STA, Zero) // _STA: Status
Name (\_SB.PCI0.PEG0.PEGP._STA, Zero) // _STA: Status



As a last step, in the attached ssdt there are two Devices, in which at the end of the line you enter the new names that replace the old ones you deleted before.

Es: Device (_SB.PCI0.PEG0.GFX1). that replace D053
Device (_SB.PCI0.PEG0.HDAU). that replace PEGP

You have done!
Ps. All changes are made only in the SSDT. The DSDT is not really changed.
 
Last edited:
Joined
Mar 18, 2020
Messages
73
Motherboard
ASRock W480 Creator
CPU
i9-10850K
Graphics
GT 710
Mac
  1. MacBook Pro
Yes in a nutshell, in the guide it says to go and create a ssdt in which the two values in the PEG0 device in DSDT (in my case), PEGP and D053 they are canceled and replaced by those of the ssdt.

How to cancel? With these lines that you must insert at the end of SSDT (before the last brackets) as in mine, that I am attaching.

Name (\_SB.PCI0.PEG0.D053._STA, Zero) // _STA: Status
Name (\_SB.PCI0.PEG0.PEGP._STA, Zero) // _STA: Status



As a last step, in the attached ssdt there are two Devices, in which at the end of the line you enter the new names that replace the old ones you deleted before.

Es: Device (_SB.PCI0.PEG0.GFX1). that replace D053
Device (_SB.PCI0.PEG0.HDAU). that replace PEGP

You have done!
Ps. All changes are made only in the SSDT. The DSDT is not really changed.
I'm not sure exactly where the 'PEGP' and 'D053' come from but, in my case, it turned out like this:
1. (From IORegistryExplorer) Location: PEG1 Name assigned to it in ACPI tables is GFX0@0
Screen Shot 2021-05-17 at 12.28.25 PM.png

2. (Searching on "PEG1" in DSDT shows Device(PEG1) Path is _SB.PCI0.PEG1. Name (_ADR, 0x00010001)
Screen Shot 2021-05-17 at 12.32.06 PM.png

3. Patching. (Since I have name GFX0@0, I skip directly to step 3b.)
3b.I have downloaded the SSDTfiles.zip. Based on path of "_SB.PCI0.PEG1", I chose the text file "Disable PCI0.PEG0.PEGP.txt" as being the most similar to my case. (Is this correct?) I apply the patch the code into the SSDT-1.aml file. After the patch, I replace "_SB.PCI0.NPE3" with "_SB.PCI0.PEG1". I also replace "PEG0" with PEG1". .........
3c. My GT 710 is Keplar architecture, so I choose "Nvidia Kepler HDMI SSDT patch.txt". ]
Screen Shot 2021-05-17 at 12.22.39 PM.png
 

Attachments

  • Screen Shot 2021-05-17 at 12.28.25 PM.png
    Screen Shot 2021-05-17 at 12.28.25 PM.png
    198.7 KB · Views: 5
  • Screen Shot 2021-05-17 at 12.21.16 PM.png
    Screen Shot 2021-05-17 at 12.21.16 PM.png
    205.5 KB · Views: 6
Last edited:
Joined
Apr 22, 2021
Messages
128
Motherboard
MSI B150M BAZOOKA (U3E1)
CPU
i5 6500
Graphics
GTX 970
Mac
  1. iMac
  2. Mac mini
Mobile Phone
  1. Android
can you send me your DSDT and SSDT?

Since your video card is recognized and working, there is no need to add any values, just the HDAU audio.

These are 2 patch for Dsdt e ssdt . You can modify them for your system
 

Attachments

  • Nvidia Kepler HDMI SSDT patch.txt
    994 bytes · Views: 9
  • Replace Current GPU@PCI0.PEG0.PEGP.txt
    329 bytes · Views: 9
Last edited:
Joined
Apr 22, 2021
Messages
128
Motherboard
MSI B150M BAZOOKA (U3E1)
CPU
i5 6500
Graphics
GTX 970
Mac
  1. iMac
  2. Mac mini
Mobile Phone
  1. Android
This is mine ssdt - gtx 970 without errors:
if you want, in ssdt, you can specify what type of connector is on each adress:

Connector types are of the following range:
  • 0100 0000 for VGA
  • 0200 0000 for LVDS (built-in LCD of laptops)
  • 0400 0000 for eDP (built-in LCD of laptops)
  • 0002 0000 for DVI
  • 0004 0000 for DP
  • 0008 0000 for HDMI
Return (Package (0x0E)
{
"@0,connector-type",
Buffer (0x04)
{
0x00, 0x08, 0x00, 0x00
},

"@1,connector-type",
Buffer (0x04)
{
0x00, 0x08, 0x00, 0x00
},

"@2,connector-type",
Buffer (0x04)
{
0x00, 0x08, 0x00, 0x00
},

"@3,connector-type",
Buffer (0x04)
{
0x00, 0x08, 0x00, 0x00
},


"@4,connector-type",

Buffer (0x04)
{
0x00, 0x08, 0x00, 0x00
},

"@5,connector-type",
Buffer (0x04)
{
0x00, 0x08, 0x00, 0x00
},

"hda-gfx",
Buffer (0x0A)
{
"onboard-1"
}
})
}
}
 

Attachments

  • SSDT-6-970.aml
    400 bytes · Views: 8
Top