Skip to content

How to patch your DSDT

RehabMan edited this page Apr 2, 2013 · 24 revisions

Although there are pre-patched DSDTs available as downloads from the tonymacx86.com forums and in installer packages such as the HP ProBook Installer, there can be differences in individual DSDTs that can cause delays in booting and perhaps other problems. Perhaps there are slight differences in BIOS settings, memory installed, etc, that is causing these differences. It is best, therefore, to patch your own DSDT and install it into /Extra/dsdt.aml.

Extracting your native DSDT

I have included four different methods for extracting your native DSDT. Just pick the method that seems easiest for you. The easiest one will depend on whether you still have Windows installed, whether you already have a Linux USB stick prepared, and just how familiar you are with both systems.

Extracting your native/clean DSDT using MaciASL or DSDT Editor under OS X

Boot your OS X installation with DSDT=No or without a DSDT installed to /Extra/dsdt.aml. To boot with DSDT=No, just type it at the Chimera/Chameleon boot screen and press enter. This will boot your system with the OEM provided DSDT such that MaciASL or DSDT Editor can be used to extract the raw DSDT.

If you have a high-resolution screen (1600x900 or 1920x1080) you will not be able to boot without a DSDT. If this is your case, copy Mini-SSDT-DualLink.aml to the Unibeast USB /Extra/ssdt.aml. This SSDT inserts a small patch into ACPI namespace that allows you to get a valid screen on the laptop display, but will not impact the raw DSDT extracted by MaciASL or DSDT Editor.

Extracting your native/clean DSDT using Linux 'acpidump'

In order to use the patches provided in this repository, you first have to acquire your native/clean DSDT. One way to do that is with acpidump in Linux.

First of all, you need the ability to run Linux. For that I recommend creating a USB stick with Ubuntu. Read and follow these complete instructions: http://www.ubuntu.com/download/help/create-a-usb-stick-on-windows. After you get your Ubuntu USB stick made, boot from it. On the HP ProBook, you tap the F9 key during BIOS startup and you will get the opportunity to boot from devices other than the hard disk. Select your USB stick with Ubuntu on it. When the Ubuntu menu appears, choose the first one, where you are just running (not installing) Ubuntu. If you decide to use Ubuntu on a regular basis, you can install it. For that I suggest you see my guide at http://racerrehabman.wordpress.com/2012/07/06/guide-to-installing-windows-7-windows-8-mac-os-x-lion-and-ubuntu-multi-boot/ which has complete instructions for multi-booting Win7, Win8, Lion, and Ubuntu.

Now you should be running Ubuntu. To get 'acpidump' you first need to enable the 'universe' software repository. To do so, it is easiest to follow this guide: https://help.ubuntu.com/community/Repositories/Ubuntu#Adding_Repositories_in_Ubuntu

After adding 'universe' to the Ubuntu Software Center's software sources, you are ready to install acpidump and run it. You will need internet access to get the acpidump software, so if you are using a wireless connection, now is a good time to connect to it. After that, open Terminal (Ctrl+Alt+T), and type the following commands:

sudo apt-get update
sudo apt-get install acpidump

Now you have acpidump installed so, we can run it:

sudo acpidump -b -t DSDT -o dsdt.aml

Now copy the dsdt.aml file somewhere that you can access from your installation of Mac OS (a USB key perhaps). The dsdt.aml file you have now is a raw DSDT from your BIOS that you can use to apply the patches in this repository to create your patched DSDT.

Extracting your native/clean DSDT using Linux /sys/firmware/acpi/tables/DSDT

I didn't know this, but evidently the ACPI tables are directly available and mounted in the file system. This is much simpler than using acpidump, especially if running from the Ubuntu Live USB.

All you have to do is run the following command in Terminal:

sudo cat /sys/firmware/acpi/tables/DSDT >dsdt.aml

Then copy resulting dsdt.aml somewhere convenient to bring with you to your OS X install for patching.

Extracting your native/clean DSDT using Windows

I haven't used this method personally, but have used this application for other things and it seems that it also has the capability to extract ACPI tables. The program is "Read-Write Everything" and it is available at the following website: http://rweverything.phpnet.us/index.htm

Once you have installed RW-Everything, run it and from the "Access" menu, choose "ACPI Tables". From the "ACPI Table" window that opens, first select the DSDT tab to make sure the DSDT table is active, then choose the "Save as Binary" button on toolbar (or Shift+F2). Save that file to a place easy to transfer to your MAC OS installation.

Creating your patched DSDT using MaciASL

MaciASL is a very nice native OS X program. It is much faster than using DSDT Editor and more polished. MaciASL is the recommended way to patch your DSDT. MaciASL is available only on Lion and Mountain Lion.

http://raw.github.com/RehabMan/HP-ProBook-4x30s-DSDT-Patch/master
  • Now you can close Preferences
  • Use File Open to open your unpatched/raw DSDT you extracted earlier
  • Choose Patch from the toolbar
  • On the left you should see "ProBook" patch repo added in Preferences earlier
  • The patches are divided into groups. Select one from the first group "ProBook 4x30s" "ProBook 4x40s Ivy Bridge" or "ProBook 4x40s Sandy Bridge" depending on your specific laptop.
  • The patch text will load in the upper part of the patch window, and after a few seconds the preview window in the lower section will fill in with before/after data
  • For my machine (4530s w/ F.40 BIOS) it shows 110 Patches, 146 changes, 0 Rejects
  • Click on the Apply button to apply the patches. The patch window will clear.
  • Now select from the next group, either "IGPU/LVDS Single-Link" if you have the standard 1366x768 laptop display, or "IGPU/LVDS Dual-Link" if you have the high resolution 1600x900 or 1920x1080 upgraded screen.
  • Again the patch text will load in the upper part of the patch window. Click on the Apply button to apply the patches. The patch window will clear.
  • Now select from the next group, your desired fan behavior. The patch window will fill, then hit Apply to apply the patch.
  • Finally, if you have Atheros 9285 WiFi, select the "Atheros 9285 WiFi Airport Patch" and hit Apply to apply the patch.
  • You can now Close the patch window by clicking on the Close button.
  • Choose Save As... and pick a location to save your patched DSDT. Be sure to save it as File Format "ACPI Machine Language Binary" Save it to the desktop if you're not sure where to save it.
  • Now copy the resulting DSDT.aml to your /Extra/dsdt.aml. You can use Terminal:
sudo cp ~/Desktop/DSDT.AML /Extra/DSDT.AML

Creating your patched DSDT using DSDT Editor

For this step you will be running "DSDT Editor" under OS X.

Note: DSDT Editor is written in Java, so you will need to install Java in order to run it. OS X should prompt you to install Java and automatically download and install it through Software Update. If it doesn't, I suggest you visit http://support.apple.com and download the Java package appropriate for your version of OS X.

  • In addition you will need a copy of the latest patches. Download from here: https://github.com/RehabMan/HP-ProBook-4x30s-DSDT-Patch/archive/master.zip. After downloading, extract them from the archive.
  • After downloading the DSDT Editor, extract it, then run the "DSDT Editor" application. You can copy it to your Applications folder if you wish as well.
  • Once in DSDT Editor, choose File, Open. Open your un-patched, native DSDT extracted earlier. It will take a while to load and parse.
  • Once it is done, choose Patch, Open, then select the "4x30s.txt" "4x40s_IvyBridge.txt" or "4x40s_SandyBridge.txt" depending on your specific laptop.
  • In the Patch window that opens, click Apply, then wait for it to complete.
  • After it is done, click Close. Do not move onto the next step right away. Instead, wait for DSDT Editor to parse the results of the patch. It will do this a few seconds after you close the patch window. You will notice the progress indicator in the lower right light up and start animating. When the progress indication animation stops, you are ready to move to the next step.
  • Once it is done, choose Patch, Open, then select the "03a_HDMI.txt" if you have the standard 1366x768 laptop display. Choose "03b_1080p+HDMI.txt" if you have the 1600x900 or 1920x1080 upgraded display.
  • In the Patch window that opens, click Apply, then wait for it to complete.
  • After it is done, click Close. Do not move onto the next step right away. Instead, wait for DSDT Editor to parse the results of the patch. It will do this a few seconds after you close the patch window. You will notice the progress indicator in the lower right light up and start animating. When the progress indication animation stops, you are ready to move to the next step.
  • Once it is done, choose Patch, Open, then select "04a_FanPatch.txt" "04b_FanQuiet.txt" or "04c_FanSpeed.txt" depending on your desired fan behavior.
  • In the Patch window that opens, click Apply, then wait for it to complete.
  • After it is done, click Close. Do not move onto the next step right away. Instead, wait for DSDT Editor to parse the results of the patch. It will do this a few seconds after you close the patch window. You will notice the progress indicator in the lower right light up and start animating. When the progress indication animation stops, you are ready to move to the next step.
  • If you have the Atheros 9285 WiFi card, choose Patch, Open, then select "08_AR9285.txt"
  • In the Patch window that opens, click Apply, then wait for it to complete.
  • After it is done, click Close. Do not move onto the next step right away. Instead, wait for DSDT Editor to parse the results of the patch. It will do this a few seconds after you close the patch window. You will notice the progress indicator in the lower right light up and start animating.
  • After it is done, you are ready to compile and save your patched DSDT. Choose IASL, Compile. In the window that results, you will see several Warnings and Remarks... this is normal. There should be no errors. Now choose IASL, Save AML as, and select a destination. After you have your new DSDT.AML saved, you may then copy it to /Extra/DSDT.AML. You can so so with Finder or at the command line in Terminal:
sudo cp ~/Desktop/DSDT.AML /Extra/DSDT.AML
Clone this wiki locally