Advanced DSDT Fixes: nVidia Graphics

I've been receiving a lot of requests to do a step by step guide on how to enable graphics by DSDT injection. As stated in my post Enable Full Graphics Card Acceleration, there are many ways to enable graphics on your Hackintosh. This guide will allow you to directly inject information via your DSDT, therefore eliminating the use of methods such as Enabler kexts, or EFI Strings.

NOTE TO ATI USERS: I did not include a solution for ATI graphics card in this post. Although you could probably work it out, I do not own an ATI card, so I can't test. I'd love to duplicate this post for ATI users. Contact me on the forum if you've successfully injected DSDT code for ATI cards. Download an untested example of the code- the process seems a bit more involved.

BEFORE YOU BEGIN
This guide assumes you've read and understand the following DSDT posts, and are familiar with the editing process. You will need to have enabled full graphics acceleration (QE/CI) via Enabler kext or EFI Strings.
You will also need to have XCode, Apple's Development platform for OS X installed on your system. It is an optional install on your Mac OS X Retail DVD. You can also download the full version for free here.

The main tool we'll be using is IORegistryExplorer which is located in /Developer/Applications/Utilities on the root of your Snow Leopard drive. This application gives us a view of the hardware registry. I encourage you to explore the full version of XCode, but if you want to simply get the IORegistryExplorer application only, it is available here.

STEP 1: INSERT DSDT GRAPHICS CODE TEMPLATE
In this step you will insert a template of DSDT code from tonymacx86-DSDT-FIXES.dsl into your DSDT.aml that will enable Graphics detection.
  1. Download the updated tonymacx86-DSDT-FIXES.zip
  2. Open DSDTSE. You can download the application from here.
  3. Open tonymacx86-DSDT-FIXES.dsl in DSDTSE.
  4. Locate 09 - DSDT Graphics - nVidia
  5. Open your DSDT.aml in DSDTSE.
  6. Type Device (PCI0) in the search box.
  7. You'll see something like this:
  8. Copy and paste the updated code as shown in tonymacx86-DSDT-FIXES.dsl
STEP 2: EDIT YOUR DSDT WITH YOUR REGISTRY INFORMATION
In this step, you'll examine your registry information and modify the template. You can check your work by comparing to my fully edited GA-P55M-UD2 DSDT with 9400 GT and Core i5 SpeedStep as a guide.
  1. Open /Developer/Applications/IORegistryExplorer
  2. Locate your display data as shown:
  3. Highlight display@0 in the left column.
  4. Locate AAPL,gart-width in right column.
  5. Find the entry for "VRAM,totalsize" in the DSDT graphics code.
  6. Edit your information to match. This entry will be 0x40 for 1GB cards, 0x20 for 512MB cards. 0x10 for 256MB cards If yours doesn't match, make sure you use these values.
  7. Locate NVCAP in right column.
  8. Find the matching entry for "NVCAP" in the DSDT code.
  9. Edit your information to match the NVCAP values.
  10. Locate the following section in your DSDT
  11. Customize this text with your specific card's information.
  12. Save your DSDT.aml
  13. When you are finished making changes, click Tools and choose Compile.
  14. If you don't get any errors, click Tools and choose DSDT files folder.
  15. Your DSDT files folder (/Library/Application Support/EvOSoftware/DSDT) will open in Finder. Helpful Hint: you can pull this folder into the sidebar to bookmark it.
  16. Copy your dsdt.aml.
  17. Paste your dsdt.aml into the root / of your hard drive (or /Extra folder for Chameleon RC4).
  18. Capitalize DSDT.aml
STEP 3: REMOVE ALL EXISTING GRAPHICS ENABLERS
You must now remove all Enablers, GraphicsEnabler=Yes, and EFI Strings from your system to test the new injection.
  1. Open /System/Library/Extensions
  2. Delete any Kext Enablers (NVEnabler, NVInject, NVKush, etc…) from your system.
  3. Drag /System/Library/Extensions to Kext Utility
  4. Open /Extra/Extensions/ and open com.apple.boot.plist in TextEdit
  5. Remove any EFI String information and GraphicsEnabler=Yes
STEP 4: REBOOT AND INSPECT PERFORMANCE AND DETECTION
Now is the moment you've been waiting for! To see if it worked.
  1. Reboot your system.
  2. Check your system for QE/CI acceleration.
  3. Open Utilities/System Profiler
  4. You should see the correct information under Graphics as shown below:

Congratulations! You've just hard-coded your graphics information directly into your DSDT! Enjoy your somewhat more 'vanilla' Hackintosh installation!

If QE/CI doesn't work, or you can't change resolutions, check the DSDT code and IORegistryExplorer entries again. You will have to insert your previous method (Enabler/EFI String) back into your system and restart the process. This guide worked on my GA-P55M-UD2 and nVidia 9400 GT, but I haven't tested on any other systems or cards. Other hardware may need different modifications to operate effectively. Post on the forum in the DSDT section if you're having issues.

-tonymacx86

PS: Despite successfully completing this guide, I'm still using NVEnabler64.kext for my system. Unfortunately this method does NOT enable enable TV-OUT (mirroring) on my 9400 GT. I'll update the DSDT code and this page when I find a way. Below is what I see using the NVEnabler64 kext. As I always say, whatever works best! This method may not be relevant to you. Good luck!


For discussions on this and other topics, register today at tonymacx86.com!