Contribute
Register

<< Solved >> Dell Optiplex 7020 - 4K monitors on Intel 4600 Integrated GPU

Status
Not open for further replies.
Joined
Jan 21, 2012
Messages
991
Motherboard
HP 8300 Elite
CPU
i5-3570
Graphics
GT 710
Mobile Phone
  1. Android
EDIT: See pages 16 on for a better way to achieve this. Changed DVMT refs to 64MB - 1st Aug 2020
This 1st post is superseded by later findings - (if anyone wants to rewrite with new stuff?) make sure you read pages 16-18 ish before following this first post.

This thread deals with making the changes needed to make a Dell 7020/9020 capable of displaying 4K screen resolutions using just the on-board Intel 4600 graphics by adding entries to config.plist and changing two values held in the UEFI firmware. The Video memory many also be increased to 2GB (from 1.5).

The UEFI firmware changes set the;
CFG Lock to Disabled, Which is enabled by default and the setting is not shown in the bios setup screens,
DVMT Pre Allocation size to 64MB, which may be set to 32MB by default but again, missing displaying this or any options in the bios.

Together with a config.plist edit and DP cables this is enough to get 4k output on both DP's but only with purely DP connections. Adding another config.plist entry increases the VRAM which should make the GPU more effective with higher resolution screens.

Full 4k is only possible using a DisplayPort to DisplayPort cable, and
Dual monitor setups require both monitors connected by DP to DP cables.


Other cables or any adaptors are likely to cause issues with sleep, sound and crashes.

If you do not use DP to DP cables then this method is likely to negatively impact your hack and
unless you have a 4k monitor there is no reason to do it.

Problem reporting files from dual 4k and 1080, working well config, attached below.

Based on previous Dell 7020/9020 OSX builds
The base build for the Dell without additional GPU is described here, that thread shows the differences needed between using the on-board rather than an additional GPU. It is a spin-off from trs92's comprehensive guide which uses an external GPU here and should be used in conjunction with trs96's guide.
These are great Hackintosh builds with just about everything working perfectly.

Other builds may also work.

This post is an expansion and clarification of a post by @li3p.
li3p's original report of success is now the 2nd post on here.
Li3p linked to this Github repository which may be theirs.
The increase in VRAM is taken from Jaymonkey's excellent guide on Lilu and its plugins, which gives a great deal of info about patching in general and about the 4600 GPU in particular.


Process
1. Find the info you need to know to make the changes
2. Write those changes to the UEFI firmware
3. Add entry to Kext to Patch


1. Find the info you need to know
We have two settings we want to change;
  1. Cfg Lock - which we want to Disable, and
  2. DVMT Pre-Allocation - which we want to set to use 64MB of RAM
For each setting, we need to know;
a. the number in hex of the BIOS offset where the setting is stored, and​
b. the current number stored in that offset, and​
c. the correct number to store to get the settings we want.​

That information is held in the bios and can be discovered by finding it in the bios or being told what it is.

We have the information needed for;
BIOS A18 for the Dell 7020, and
BIOS A25 for the Dell 9020, the details are the same.
The offsets for other BIOS versions are not known and should not be presumed to be the same.

The Settings for a Dell 9020 with Bios A25 or a Dell 7020 with Bios A18 are;

CFG Lock
Offset - 0xDA2,
normal value – 0x2 or 0x1 = enabled,
new value to be set - 0x0 = disabled

DVMT Pre-Allocated
Offset - 0x263,
normal value – 0x1 = 32MB or 0x2 = 64MB,
new value 0x2 = 64MB

Finding out details for other BIOS versions
If you are using another BIOS you can either upgrade to one of the BIOS numbers shown or find the info needed for your version of the BIOS. Finding the info in the bios is relatively straightforward and is shown as a screenshot step through on page 6 of this thread which is based on the general description written by @iLikeHackintosh shown on post 16 here and the details for our particular BIOS from @li3p.


2. Write to the UEFI firmware
Writing to the UEFI firmware has risks including making a machine permanently impossible to boot.
If you are unsure of the risks involved, please do not do this.


We need a specially formatted bootable USB drive to make the changes. This USB drive will boot to the "Grub Shell" command prompt, where we enter the commands needed to write to the UEFI firmware variables.

Instructions for making the usb drive on Mac or Linux are under the heading -
How to create bootable USB for GRUB shell by ILikehackintosh here.
You end up with a bootable USB with only 1 file on it, the Grub Shell Bootloader, which gives us enough to run 'setup_var' a UEFI based program able to read and change UEFI variables held in firmware.

BE VERY VERY CAREFUL when using "setup_var"
Writing the wrong values or writing to the wrong location
may make your machine permanently unbootable.


We then boot from that UEFI based USB drive which should take us to a command prompt,
where we execute the setup_var command to;
  • Read from the UEFI Bios offsetts we are going to write to;

    The CFG Lock setting in our example is originally set at 0xDA2 and is normally set to 1 or 2,
    so if we entered the following into that command prompt,
    setup_var 0xDA2
    it should return 1 or 2 but will be proceeded by text which will say something along the lines of not finding what it expected - these messages can be ignored

    and the DVMT Pre-Allocated original setting at 0x263 is 2 and
    setup_var 0x263
    should also return 1 or 2.


  • Write the new values;

    CFG Lock
    - Disabled = 0
    setup_var 0xDA2 0x0

    DVMT Pre-Allocated
    - 64MB = 2
    setup_var 0x263 0x2

    Then remove USB and Reboot normally to OSX

    3. Add entry to Kext to Patch


    Do either A. or B. not both - they both do the same thing.

    A. Go into Clover Configurator and add the entry into Kexts to patch.
    Add a line to Kexts to patch with the following details

    Name:
    AppleIntelFramebufferAzul

    Find:
    0300220D 00030303 00000002 00003001

    Replace:
    0300220D 00030303 00000004 00000003

    Screenshot 2019-09-10 at 06.54.35.png



    B. Add this text into config.plist in the correct place
    <key>KextsToPatch</key>
    <array>
    <dict>
    <key>Disabled</key>
    <false/>
    <key>Find</key>
    <data>
    AwAiDQADAwMAAAACAAAwAQ==
    </data>
    <key>InfoPlistPatch</key>
    <false/>
    <key>Name</key>
    <string>AppleIntelFramebufferAzul</string>
    <key>Replace</key>
    <data>
    AwAiDQADAwMAAAAEAAAAAw==
    </data>
    </dict>
    </array>
    which sits in my config plist here - yours may be different.

    Screenshot 2019-08-30 at 11.05.23.png


    To increase video memory to 2Gb (which may help on dual monitor setups) - Either
  • A: Enter the following;

    <key>framebuffer-unifiedmem</key>
    <data>
    AAAAgA==
    </data>

    here
    Screenshot 2019-09-03 at 16.54.35.png

    or
  • B: Add
    framebuffer-unifiedmem entry in Clover, here

    Screenshot 2019-09-03 at 16.53.08.png


    Finished
    Reboot
    Plug in 4k monitor DP-DP without adaptors to test, with adaptors and hope.

    To revert and cancel changes
  • Remove Clover entries
  • Reboot with the GRUB Shell USB and issue commands to write back the original numbers;
    setup_var 0xDA2 0x1
    setup_var 0x263 0x2

    Other contributions will be especially welcome because the tools and processes mentioned are new to me.
    The 64MB DVMT pre-allocation limit is the lowest that gets 4k working (96MB was originaly chosen and the others have not been tested) but the general opinion in the forums is that the lowest pre-allocation that works is the best setting, as it keeps the ram available for the cpu when the gpu does not need it and will allocate more to vram when needed.
EDIT: Changed DVMT to 64MB 1st August - see pages 16- for discussion relating
 

Attachments

  • debug_5987.zip
    3 MB · Views: 406
  • Screenshot 2019-09-10 at 06.54.35.png
    Screenshot 2019-09-10 at 06.54.35.png
    300.2 KB · Views: 609
Last edited:
I was also having a hard time getting my GPU displaying 4K. I wasn't able to figure it out so I returned it but I was using a RX 570.

I solved this by put Lilu and Whatevergreen into /Library/Extension and use Kext Utility to rebuild the kext cache.
and Add a KextsToPatch in config.plist:

Name : AppleIntelFramebufferAzul
Find: 0300220D 00030303 00000002 00003001
Replace: 0300220D 00030303 00000004 00000003

Then save and reboot , you can use the 4K with the iGPU now, Actually I use dual 4K (Dell P2415Q) without problem.

Oh, I forgot one thing, you should use GRUB Shell to mod BIOS vars like in this URL:

Easy for DELL OptiPlex 9020
Since I've already finished these steps above, just type the following command.
  • Disable MSR 0xE2 (i.e. cfg lock) setup_var 0xDA2 0x00
  • Increase DVMT to 96M setup_var 0x263 0x03

Above is the way to use one or two 4K monitor with the HD 4600 iGPU,
for me that is enough , I dont have Rx580 dGPU. actually I put a PCIE to NVME
adapter on the pciex16 slot with a intel 1T nvme ssd, which can perform 1500 MBps for writing
and 2700 MBps for reading, which I recommend you have a try.

FYI, I also attached my
 

Attachments

  • config.plist
    9.3 KB · Views: 434
I have made the changes described in the above notes and the machine still works, not yet tested with 4K monitors but expect to test sometime during the next couple of weeks.
EDIT: Made changes, plugged in 4k monitor and it worked!
 
Last edited:
I solved this by put Lilu and Whatevergreen into /Library/Extension and use Kext Utility to rebuild the kext cache.
and Add a KextsToPatch in config.plist:

Name : AppleIntelFramebufferAzul
Find: 0300220D 00030303 00000002 00003001
Replace: 0300220D 00030303 00000004 00000003

Then save and reboot , you can use the 4K with the iGPU now, Actually I use dual 4K (Dell P2415Q) without problem.

Oh, I forgot one thing, you should use GRUB Shell to mod BIOS vars like in this URL:

Easy for DELL OptiPlex 9020
Since I've already finished these steps above, just type the following command.
  • Disable MSR 0xE2 (i.e. cfg lock) setup_var 0xDA2 0x00
  • Increase DVMT to 96M setup_var 0x263 0x03

Above is the way to use one or two 4K monitor with the HD 4600 iGPU,
for me that is enough , I dont have Rx580 dGPU. actually I put a PCIE to NVME
adapter on the pciex16 slot with a intel 1T nvme ssd, which can perform 1500 MBps for writing
and 2700 MBps for reading, which I recommend you have a try.

FYI, I also attached my

I will be testing this in the coming week using my 42” TV and will report back.
 
I will be testing this in the coming week using my 42” TV and will report back.
Sounds good Craig. Will be great to have someone, possibly you and/or Nick write out a step by step for beginners with no previous UEFI editing experience. It can get fairly involved and complex very quickly. One question I have, are you going to be switching to virtualsmc to try this, per JimLee Github instructions ?
 
Last edited:
Sounds good Craig. Will be great to have someone, possibly you and/or Nick write out a step by step for beginners with no previous bios modding experience. It can get fairly involved and complex very quickly.

I’m up for that!. @nicksoph, I’ll read up on this over the next couple of days and start testing Wednesday. I’ll post back here with whatever results I get for a ‘beginners guide’.
 
One question I have, are you going to be switching to virtualsmc to try this, per JimLee Github instructions ?
I’ll read up on what ‘virtualsmc’ is first!, do you recommend I use it?. I should probably do my homework before diving in.
 
I’ll read up on what ‘virtualsmc’ is first!, do you recommend I use it?. I should probably do my homework before diving in.
I don't think it matters which SMC kext is used. I would try it with FakeSMC first and try the UEFI edits and the framebuffer patch to see what happens. My biggest question is why use a 96mb DVMT when a 64mb setting should get the job done ?
 
Last edited:
My biggest question is why use a 96mb DVMT when a 64mb setting should get the job done ?
I won’t pretend I know the answer to that question, or what DVMT is. BUT!, I was reading about this issue on another thread here. Is it something specific to the 5K monicker. I read something about splitting pixels, I could be just making this up of course!.
I
 
The Apple framebuffer kexts generally expect 64mb or larger DVMT pre-alloc and most PC OEMs use only 32mb i.e. Dell. Often, there is no way to change it easily due to limited BIOS, locked down BIOS, etc. By editing the UEFI and setting DVMT pre-alloc to 64mb it should theoretically make 4K work when running macOS on your Optiplex. This is where the testing is needed to confirm this. DVMT means dynamic video memory technology, just another sica, supposedly impressive computer acronym. It's a pool of memory used for video, shared with the system ram similar to the way Intel igfx shares/borrows from the system ram.
 
Last edited:
Status
Not open for further replies.
Back
Top