Closed kingo132 closed 3 years ago
I read some code of WEG today. WEG does have the IceLake HDMI patch code.
From the code, I can see the patch is done by modifying the value of the AppleIntelICLLPGraphicsFramebuffer.kext (in the memory, maybe).
The offset of these values is found by search the platform id in AppleIntelICLLPGraphicsFramebuffer.kext.
As you can see, it has a start address to begin searching. And this start address is found by a global variable called "_gPlatformInformationList".
I can find this _gPlatformInformationList variable in AppleIntelICLLPGraphicsFramebuffer.kext. Which do have many framebuffer configuration values.
While patching, it just static_casted the memory he finds to a struct called "FramebufferICLLP".
The definition of this structure can indeed reflect the value in AppleIntelICLLPGraphicsFramebuffer.kext accordingly.
The above is the current process of how WEG is patching connector type to HDMI. In order to verify whether WEG modified the interface type correctly, I did a small test.
I managed to find the offset of the connector configuration data of my platform id 0x8A5C0001 in AppleIntelICLLPGraphicsFramebuffer.text. Here is what I found.
I just replaced the connector type in this binary image from 00040000 to 00080000. And I putted it back into /System/Library/Extensions/AppleIntelICLLPGraphicsFramebuffer.kext/Contents/MacOS/ and then rebuilt the kext cache.
After reboot, I found the modified binary has taken effect, WEG read the connector type 00080000.
But the connector type of my external display is still 00 04 00 00. So I can draw some conclusion that maybe the way WEG is trying to patch the HDMI connector type of IceLake devices does not affect the final connector type. There may be other places of the apple driver that need to be modified too.
@kingo132 Please check ICL framebuffers in IGPU Chart. Apple has dropped HDMI connecter type support in ICL platform, so there’s no reason to add dp->hdmi feature for ICL platform.
@kingo132 Please check ICL framebuffers in IGPU Chart. Apple has dropped HDMI connecter type support in ICL platform, so there’s no reason to add dp->hdmi feature for ICL platform.
Thanks stevezhenshiqi, I know about this, I'm not going to get HDMI working, I'm trying to get my Displayport audio working. As the FAQ of WEG says, it need to change the connector type to HDMI to get the Display port audio working.
I would say it’s more like an AppleHDA issue which needs to be pathced on your model, like what https://github.com/acidanthera/AppleALC/blob/master/Resources/Controllers.plist#L793 does.
As explained above it is not an issue. If you have issues with AppleALC HDMI patches, provide new ones that resolve things for you. This is oss.
I would say it’s more like an AppleHDA issue which needs to be pathced on your model, like what https://github.com/acidanthera/AppleALC/blob/master/Resources/Controllers.plist#L793 does.
As explained above it is not an issue. If you have issues with AppleALC HDMI patches, provide new ones that resolve things for you. This is oss.
Thanks bros. The initial reason I'm researching this is that I can't output any audio to my external display. No matter using any type-c, type-c to DP, or type-c to HDMI cable.
First I'm trying from AppleALC. I tested all the layout-id of AppleALC and also I tried to dump the audio codec from ubuntu. Both no success. Also, I tried to change many device ids in the device property, still no success.
By the way, AppleALC does have a patch for IceLake, I tried to modify it but also no success.
https://github.com/acidanthera/bugtracker/issues/1283#issuecomment-824802110
After all of this, I'm trying to find a solution in WEG. I'm wondering if it is because WEG not patching the connector type correctly. Here is what the FAQ of WEG says.
So if this quote is correct, then the connector type of my external display is still DP (00 04 00 00), but not HDMI (00 08 00 00). The HDMI patch of WEG has no effect.
Also, I searched nearly all the IceLake Hackintoshes in Github. All of them are laptops. You can find them here.
None of them can output any audio to the external display. So I'm wondering this may not be a specific problem related only to my device.
I do not believe this applies to Ice Lake. Ice Lake is quite different from the previous generations, and a lot of code in it was community-contributed.
I do not believe this applies to Ice Lake. Ice Lake is quite different from the previous generations, and a lot of code in it was community-contributed.
Thank you for this information. If IceLake platform is so different, then another new patch may be needed to get the external display audio to work. I shall continue to analyze AppleALC, AppleIntelICLLPGraphicsFramebuffer, or any other related kexts to find this new patch.
Most likely it is to be supported by AppleHDAGFX driver, which AppleALC turns off as it cannot coexist with AppleHDA to our experience. You could try experimenting with it.
Most likely it is to be supported by AppleHDAGFX driver, which AppleALC turns off as it cannot coexist with AppleHDA to our experience. You could try experimenting with it.
OK, thanks, and do you mean AppleGFXHDA instead of AppleHDAGFX ? I can only find this name in my Catalina version.
jason@my299 Extensions % ls *HDA*
AppleGFXHDA.kext:
Contents
AppleHDA.kext:
Contents
And by the way, I tried another VoodooHDA for opencore, which is called VoodooHDA-OC. It seems recently come out.
https://github.com/chris1111/VoodooHDA-OC
This one also can not output audio to the external display.
Yes, made a mistake in the name. VoodooHDA has never supported any recent digital audio. VoodooHDA-OC is nothing else but a normal VoodooHDA just more accurately compiled for an older macOS.
Yes, made a mistake in the name. VoodooHDA has never supported any recent digital audio. VoodooHDA-OC is nothing else but a normal VoodooHDA just more accurately compiled for an older macOS.
I see. Thank you!
Most likely it is to be supported by AppleHDAGFX driver, which AppleALC turns off as it cannot coexist with AppleHDA to our experience. You could try experimenting with it.
Hello @vit9696! I was able to load AppleGFXHDA8086_9D71Controller, with that one DP audio is working properly, but no analog output (speakers, headphones). But Type-C to HDMI now can output external sound.
I just did remove some unload AppleGFXHDA stuff from AppleALC and that's worked. AppleHDA is not loading (only AppleGFXHDA and AppleHDAController). Is there any chance to get them (maybe force?) to work both together?
Here is the IOreg
P.S. > or maybe there is a chance to fix that panic in AppleHDA to use it for both digital and analog sound? https://github.com/acidanthera/bugtracker/issues/1283#issue-742282212
I'm using the latest version of WhateverGreen, the version number is 1.4.9.
You can find the information of my device and EFI here: https://github.com/kingo132/GPD-Win-Max-Hackintosh
This is my device configuration
And this is the boot log of WhateverGreen
From the log, you can see it has successfully done the DP to HDMI patch. But the connector type of my external display is still DP (00 04 00 00). Shouldn't it be HDMI (00 08 00 00)?
And here is my full ioreg: mywm.ioreg.zip