Skip to content

😈 Tutorial for Beginners who also want to modify their own DSDT/SSDTs like a guru!

Notifications You must be signed in to change notification settings

Kaijun/Acer-V5-573g-DSDT

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

###Process of Modifying DSDT (Based On Tables from Bios 2.30)

  1. Download iasl51 use iasl to extract clean DSDT/SSDTs from raw DSDT/SSDTs
./iasl51 -da -dl -fe refs.txt *.aml
// move clean dsl files to clean/ , you can also do it manually!
mkdir clean && mv raw/*.dsl clean/

As i know, different Models have different DSDT/SSDTs structures: For my own Model: i5 Version non-HD:

DSDT - we all have it!
SSDT0 - Nvidia Graphical Card parAt! Which contains lot of `\_SB.PCI0` scopes
SSDT1 - Unknown, but keep it! Contains only one scope `\_SB` and one device `IAOE`
SSDT2 - Internal Graphical Card part! Which contains one `\_SB.PCI0` scopes and `B0D3`(or different) and `GFX0` device
SSDT3,4 - CPU part. You will see lot of `CPU` scopes. Just **Remove** them! We don't need it! We generate SSDT for CPU later with tools.

Others like i7 Version HD, or maybe i5 Version HD:

DSDT - we all have it!
SSDT0-4 - CPU part. You will see lot of `CPU` scopes. Just **Remove** them! We don't need it! We generate SSDT for CPU later with tools.
SSDT5 - Internal Graphical Card part! Which contains one `\_SB.PCI0` scopes and `B0D3`(or different) and `GFX0` device
SSDT6 - Nvidia Graphical Card part! Which contains lot of `\_SB.PCI0` scopes
SSDT7 - Unknown, but keep it! Contains only one scope `\_SB` and one device `IAOE`

Notice! My tutorial is based on the structure of mine! Please notice your filenames and fit to your own related DSDT/SSDTs! 2. Download MaciASL and start editing clean dsl files. Add Laptop-DSDT-Patch repo into MaciASL.

  1. Error Fix: Now we are using ./iasl51 -da -dl -fe refs.txt *.aml command with help of refs.txt (Referenced Topic). So there should be No Errors in your DSDT/SSDTs. If you are interested in how to fix errors manually, please checkout the deprecated branch.

  2. At the very beginning, we patch Common Fixes: (Referenced Topic)

  • Apply Rename _DSM methods to XDSM patch to all DSDT/SSDTs!
  • Apply following patched to DSDT
    • Fix _WAK Arg0 v2
    • HPET Fix
    • SMBUS Fix
    • IRQ Fix
    • RTC Fix
    • OS Check Fix (Windows 8)
    • Fix Mutex with non-zero SyncLevel
    • Add IMEI
  1. Disable Nvdia:
  • At the top of DSDT, add
External (_SB_.PCI0.RP05.PEGP._OFF, MethodObj) // Warning: Unresolved Method, guessing 0 arguments (may be incorrect, see warning above)
External (_SB_.PCI0.RP05.PEGP._ON, MethodObj) // Warning: Unresolved Method, guessing 0 arguments (may be incorrect, see warning above)
  • Add \_SB.PCI0.RP05.PEGP._ON() at the beginning of _PTS method
  • Add \_SB.PCI0.RP05.PEGP._OFF() at the end of _WAK method, but before Return statement
  • Add \_SB.PCI0.RP05.PEGP._OFF() at the end of SB.PCI0._INI method
  1. Graphic Fix:
  • DSDT: Apply Patch Rename GFX0 to IGPU
  • SSDT-0 (Nvidia Graphic fix): Apply Patch Rename GFX0 to IGPU
  • SSDT-1: Apply Patch Rename GFX0 to IGPU
  • SSDT-2(Internal Graphic): Apply Patch Rename GFX0 to IGPU -> Haswell HD4400 (However replace 0x06, 0x00, 0x26, 0x0a to 0x0C, 0x00, 0x16, 0x0A in the patch, which more compatible with HD4400 ) -> Brightness fix Haswell
  1. USB Fix in DSDT for El Capitan:
  • Apply Patch 7-Series/8-Series USB
  • Apply Patch USB3 _PRW 0x6D: Check the description in patch if you're interested. It will fix almost all the USB related stuffs.
  • As Rehabman mentioned, rename EHC* and XHC are not the long term solution. So a patch in Clover 45484331 -> 45483031 is then the tempory solution. It works only with two Kexts provided by Rehabman: FakePCIID_XHCIMux.kext + USBInjectAll.kext
  1. Audio Fix
  • Apply Patch Audio Layout 03 in DSDT, works together with AppleHDA/DummyHDA with 03 Layout.
  1. Shutdown Fix in DSDT:
  • Apply the Patch in DSDT:
#Shutdown Fix
into method label _PTS code_regex (If\s*\(LEqual\s*\(Arg0,\s*0x05\)\)\s*\n\s*\{\s*\n)(?:[^\n\}]+\n)+(\s*\}) replace_matched begin
%1
            Store (Zero, SLPE)\n
            Sleep (0x10)\n
%2
end;
into definitionblock code_regex . code_regex_not OperationRegion\s*\(PMRS insert begin
OperationRegion (PMRS, SystemIO, 0x1830, One)\n
Field (PMRS, ByteAcc, NoLock, Preserve)\n
{\n
        ,   4, \n
    SLPE,   1\n
}
end;
  1. Brightness Keys ( Only for Synaptics with VoodooPS2 ): I don't know if your keys' codes are same as mine, You may need to follow the tutorial and find out yours! (Tutorial)
  • Apply patch below: (Notice: _Q8E and _Q8F are what i captured with ACPIDebug.kext)
# Make EC-based brightness up/down work with RehabMan VoodooPS2 ACPI keyboard mechanism
into method label _Q8F replace_content
begin
// Brightness Down\n
    Notify(\_SB.PCI0.LPCB.PS2K, 0x0405)\n
end;
into method label _Q8E replace_content
begin
// Brightness Up\n
    Notify(\_SB.PCI0.LPCB.PS2K, 0x0406)\n
end;
  1. Wait for your contribution!

###SSDT Generation ssdtPRGen.sh is the tool we are using.

curl -o ssdtPRGen.sh https://raw.githubusercontent.com/Piker-Alpha/ssdtPRGen.sh/Beta/ssdtPRGen.sh
chmod +x ssdtPRGen.sh
./ssdtPRGen.sh -x 1 -p 'i5-4200U'
ASL Input:     /Users/Kaijun/Library/ssdtPRGen/ssdt.dsl - 264 lines, 7903 bytes, 49 keywords
AML Output:    /Users/Kaijun/Library/ssdtPRGen/ssdt.aml - 1619 bytes, 16 named objects, 33 executable opcodes

Copy ssdt.aml to Clover! Notice: i5-4200U is my CPU model, replace with yours!

About

😈 Tutorial for Beginners who also want to modify their own DSDT/SSDTs like a guru!

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages