Contribute
Register

[Guide] Patching LAPTOP DSDT/SSDTs

My hack reboot when I wake the system from sleep, I followed the steps you provided to patch my DSDT file but whatever method I use to patch my DSDT SystemMemory never matched with original DSDT extracted through Clover.

Code:
Idriss-iMac-Pro:ACPI eddie$ diff origin/DSDT.dsl patched/DSDT.dsl|grep -y SystemMemory
<         OperationRegion (TBNV, SystemMemory, 0x7888DF98, 0x0003)
>         OperationRegion (TBNV, SystemMemory, 0x7888DF98, 0x03)
<             OperationRegion (PCFG, SystemMemory, Local0, 0x01)
>             OperationRegion (PCFG, SystemMemory, Local0, One)
<             OperationRegion (PCFG, SystemMemory, Local0, 0x01)
>             OperationRegion (PCFG, SystemMemory, Local0, One)

Those SystemMemory addresses match perfectly. Don't know why you think they are different.
Your profile has no laptop hardware details.
Please fix as per FAQ:
http://www.tonymacx86.com/el-capita...faq-read-first-laptop-frequent-questions.html

For your "reboot on wake", it is best you open a separate thread.
 
Hi i tried to follow this guide for patching DSDT, but cannot have the fils disassembled correctly :

Extracted with Clover F4. Looked for duplicate files but no files have same size.
If i try to disassemble with refs.txt, i get this :

Code:
Jo-MAC:ACPIOrigin jo-mac$ iasl -da -dl -fe refs.txt DSDT.aml SSDT*.aml

Intel ACPI Component Architecture
ASL+ Optimizing Compiler/Disassembler version 20180427(RM)
Copyright (c) 2000 - 2018 Intel Corporation

Input file DSDT.aml, Length 0x411D2 (266706) bytes
ACPI: DSDT 0x0000000000000000 0411D2 (v02 GBT    GBTUACPI 01072009 INTL 20160527)
External object resolution file SSDT-x1_6-HwpLvt.aml
Input file SSDT-x1_6-HwpLvt.aml, Length 0x724 (1828) bytes
ACPI: SSDT 0x0000000000000000 000724 (v02 PmRef  HwpLvt   00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_5-ApHwp.aml
Input file SSDT-x1_5-ApHwp.aml, Length 0x317 (791) bytes
ACPI: SSDT 0x0000000000000000 000317 (v02 PmRef  ApHwp    00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_4-Cpu0Hwp.aml
Input file SSDT-x1_4-Cpu0Hwp.aml, Length 0x10A (266) bytes
ACPI: SSDT 0x0000000000000000 00010A (v02 PmRef  Cpu0Hwp  00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_3-ApCst.aml
Input file SSDT-x1_3-ApCst.aml, Length 0x30A (778) bytes
ACPI: SSDT 0x0000000000000000 00030A (v02 PmRef  ApCst    00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_2-Cpu0Cst.aml
Input file SSDT-x1_2-Cpu0Cst.aml, Length 0x400 (1024) bytes
ACPI: SSDT 0x0000000000000000 000400 (v02 PmRef  Cpu0Cst  00003001 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_1-ApIst.aml
Input file SSDT-x1_1-ApIst.aml, Length 0xEF1 (3825) bytes
ACPI: SSDT 0x0000000000000000 000EF1 (v02 PmRef  ApIst    00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_0-Cpu0Ist.aml
Input file SSDT-x1_0-Cpu0Ist.aml, Length 0x5BE (1470) bytes
ACPI: SSDT 0x0000000000000000 0005BE (v02 PmRef  Cpu0Ist  00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-9-OptTabl.aml
Input file SSDT-9-OptTabl.aml, Length 0x1E57 (7767) bytes
ACPI: SSDT 0x0000000000000000 001E57 (v01 OptRef OptTabl  00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-8-SgPeg.aml
Input file SSDT-8-SgPeg.aml, Length 0xAE (174) bytes
ACPI: SSDT 0x0000000000000000 0000AE (v02 SgRef  SgPeg    00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-7-TbtTypeC.aml
Input file SSDT-7-TbtTypeC.aml, Length 0x1082 (4226) bytes
ACPI: SSDT 0x0000000000000000 001082 (v02 INTEL  TbtTypeC 00000000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-6-PtidDevc.aml
Input file SSDT-6-PtidDevc.aml, Length 0x27DE (10206) bytes
ACPI: SSDT 0x0000000000000000 0027DE (v02 INTEL  PtidDevc 00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-5-xh_cfhd4.aml
Input file SSDT-5-xh_cfhd4.aml, Length 0x294C (10572) bytes
ACPI: SSDT 0x0000000000000000 00294C (v02 INTEL  xh_cfhd4 00000000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-4-Ther_Rvp.aml
Input file SSDT-4-Ther_Rvp.aml, Length 0xF9E (3998) bytes
ACPI: SSDT 0x0000000000000000 000F9E (v02 INTEL  Ther_Rvp 00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-3-PegSsdt.aml
Input file SSDT-3-PegSsdt.aml, Length 0x1FC7 (8135) bytes
ACPI: SSDT 0x0000000000000000 001FC7 (v02 PegSsd PegSsdt  00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-2-SaSsdt.aml
Input file SSDT-2-SaSsdt.aml, Length 0x31C7 (12743) bytes
ACPI: SSDT 0x0000000000000000 0031C7 (v02 SaSsdt SaSsdt   00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-1-CpuSsdt.aml
Input file SSDT-1-CpuSsdt.aml, Length 0x17D5 (6101) bytes
ACPI: SSDT 0x0000000000000000 0017D5 (v02 CpuRef CpuSsdt  00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-0-SataTabl.aml
Input file SSDT-0-SataTabl.aml, Length 0x334 (820) bytes
ACPI: SSDT 0x0000000000000000 000334 (v01 SataRe SataTabl 00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
refs.txt: Importing method external (1 arguments) MDBG
refs.txt: Importing method external (0 arguments) _GPE.MMTB
refs.txt: Importing method external (2 arguments) _SB.PCI0.LPCB.H_EC.ECWT
refs.txt: Importing method external (1 arguments) _SB.PCI0.LPCB.H_EC.ECRD
refs.txt: Importing method external (1 arguments) _SB.PCI0.LPCB.H_EC.ECMD
refs.txt: Importing method external (2 arguments) _SB.PCI0.PEG0.PEGP.SGPO
refs.txt: Importing method external (1 arguments) _SB.PCI0.GFX0.DD02._BCM
refs.txt: Importing method external (4 arguments) _SB.PCI0.SAT0.SDSM
refs.txt: Importing method external (3 arguments) _GPE.VHOV
refs.txt: Importing method external (2 arguments) _SB.PCI0.XHC.RHUB.TPLD
iASL: Segmentation Fault
iASL: Terminating

If i try to disassemble without refs.txt i get this :

Code:
Jo-MAC:ACPIOrigin jo-mac$ iasl -da -dl DSDT.aml SSDT*.aml

Intel ACPI Component Architecture
ASL+ Optimizing Compiler/Disassembler version 20180427(RM)
Copyright (c) 2000 - 2018 Intel Corporation

Input file DSDT.aml, Length 0x411D2 (266706) bytes
ACPI: DSDT 0x0000000000000000 0411D2 (v02 GBT    GBTUACPI 01072009 INTL 20160527)
External object resolution file SSDT-x1_6-HwpLvt.aml
Input file SSDT-x1_6-HwpLvt.aml, Length 0x724 (1828) bytes
ACPI: SSDT 0x0000000000000000 000724 (v02 PmRef  HwpLvt   00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_5-ApHwp.aml
Input file SSDT-x1_5-ApHwp.aml, Length 0x317 (791) bytes
ACPI: SSDT 0x0000000000000000 000317 (v02 PmRef  ApHwp    00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_4-Cpu0Hwp.aml
Input file SSDT-x1_4-Cpu0Hwp.aml, Length 0x10A (266) bytes
ACPI: SSDT 0x0000000000000000 00010A (v02 PmRef  Cpu0Hwp  00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_3-ApCst.aml
Input file SSDT-x1_3-ApCst.aml, Length 0x30A (778) bytes
ACPI: SSDT 0x0000000000000000 00030A (v02 PmRef  ApCst    00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_2-Cpu0Cst.aml
Input file SSDT-x1_2-Cpu0Cst.aml, Length 0x400 (1024) bytes
ACPI: SSDT 0x0000000000000000 000400 (v02 PmRef  Cpu0Cst  00003001 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_1-ApIst.aml
Input file SSDT-x1_1-ApIst.aml, Length 0xEF1 (3825) bytes
ACPI: SSDT 0x0000000000000000 000EF1 (v02 PmRef  ApIst    00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-x1_0-Cpu0Ist.aml
Input file SSDT-x1_0-Cpu0Ist.aml, Length 0x5BE (1470) bytes
ACPI: SSDT 0x0000000000000000 0005BE (v02 PmRef  Cpu0Ist  00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-9-OptTabl.aml
Input file SSDT-9-OptTabl.aml, Length 0x1E57 (7767) bytes
ACPI: SSDT 0x0000000000000000 001E57 (v01 OptRef OptTabl  00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-8-SgPeg.aml
Input file SSDT-8-SgPeg.aml, Length 0xAE (174) bytes
ACPI: SSDT 0x0000000000000000 0000AE (v02 SgRef  SgPeg    00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-7-TbtTypeC.aml
Input file SSDT-7-TbtTypeC.aml, Length 0x1082 (4226) bytes
ACPI: SSDT 0x0000000000000000 001082 (v02 INTEL  TbtTypeC 00000000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-6-PtidDevc.aml
Input file SSDT-6-PtidDevc.aml, Length 0x27DE (10206) bytes
ACPI: SSDT 0x0000000000000000 0027DE (v02 INTEL  PtidDevc 00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-5-xh_cfhd4.aml
Input file SSDT-5-xh_cfhd4.aml, Length 0x294C (10572) bytes
ACPI: SSDT 0x0000000000000000 00294C (v02 INTEL  xh_cfhd4 00000000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-4-Ther_Rvp.aml
Input file SSDT-4-Ther_Rvp.aml, Length 0xF9E (3998) bytes
ACPI: SSDT 0x0000000000000000 000F9E (v02 INTEL  Ther_Rvp 00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-3-PegSsdt.aml
Input file SSDT-3-PegSsdt.aml, Length 0x1FC7 (8135) bytes
ACPI: SSDT 0x0000000000000000 001FC7 (v02 PegSsd PegSsdt  00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-2-SaSsdt.aml
Input file SSDT-2-SaSsdt.aml, Length 0x31C7 (12743) bytes
ACPI: SSDT 0x0000000000000000 0031C7 (v02 SaSsdt SaSsdt   00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-1-CpuSsdt.aml
Input file SSDT-1-CpuSsdt.aml, Length 0x17D5 (6101) bytes
ACPI: SSDT 0x0000000000000000 0017D5 (v02 CpuRef CpuSsdt  00003000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
External object resolution file SSDT-0-SataTabl.aml
Input file SSDT-0-SataTabl.aml, Length 0x334 (820) bytes
ACPI: SSDT 0x0000000000000000 000334 (v01 SataRe SataTabl 00001000 INTL 20160527)
Pass 1 parse of [SSDT]
Pass 2 parse of [SSDT]
Pass 1 parse of [DSDT]
ACPI Error: AE_ALREADY_EXISTS, During name lookup/catalog (20180427/psobject-371)

I can only disassemble by removing the -da option, but then files are not correctly disassembled, right?
Any idea?
Thanks

Your files have embedded External opcodes, therefore no reason to use -da or refs.txt.
Disassemble with: iasl -dl DSDT.aml SSDT*.aml
 
Hello! Can I ask someone to help me fix the sleep/shutdown and battery? What should be done?
I tried to edit myself in MaciASL, but I do not know how to fix the errors. Thank you!
 

Attachments

  • fr0stbridge.zip
    2.2 MB · Views: 73
Hello! Can I ask someone to help me fix the sleep/shutdown and battery? What should be done?
I tried to edit myself in MaciASL, but I do not know how to fix the errors. Thank you!

There are no errors in your DSDT.
 
There are no errors in your DSDT.
Thank you for your reply!
Indeed, there are no mistakes now.
Prior to this, applying the patch Rename-PCI0_GFX0 received a bunch of errors, but now fixed it. I used the ASUS N55SL patch and the battery now works properly on U31SD.
Sleep / shutdown still does not work with system_Shutdown 1/2.
Could you please check is everything implemented rightly or not and help me with solving this problem? Thank you!

Updated files
 

Attachments

  • fr0stbridge2.zip
    2.3 MB · Views: 68
Last edited:
I created the patch for my laptop as per instructed and i am uploading the files for review by Rehabman. Just one small problem the text file which i am uploading contains 7 errors all of which were encountered for 16 bit registers though i corrected all of them in the DSDT file manually and sure enough it works but i couldn't find the problems that were actually there in the patch i made maybe you could look into it. I even included a screenshot of my screen with working battery status.

Laptop: hp 348 g3
Graphics: Intel HD 520
Cpu: Intel Core-i5 6200u
and sorry if i made some mistakes this is my first post.
 

Attachments

  • HP348-G3.zip
    2.1 MB · Views: 68
Thank you for your reply!
Indeed, there are no mistakes now.
Prior to this, applying the patch Rename-PCI0_GFX0 received a bunch of errors, but now fixed it. I used the ASUS N55SL patch and the battery now works properly on U31SD.
Sleep / shutdown still does not work with system_Shutdown 1/2.
Could you please check is everything implemented rightly or not and help me with solving this problem? Thank you!

Updated files

Open a separate thread with complete details and PR files.
 
I created the patch for my laptop as per instructed and i am uploading the files for review by Rehabman. Just one small problem the text file which i am uploading contains 7 errors all of which were encountered for 16 bit registers though i corrected all of them in the DSDT file manually and sure enough it works but i couldn't find the problems that were actually there in the patch i made maybe you could look into it. I even included a screenshot of my screen with working battery status.

Laptop: hp 348 g3
Graphics: Intel HD 520
Cpu: Intel Core-i5 6200u
and sorry if i made some mistakes this is my first post.

The DSDT.aml you attached is not native (it is already patched).
 
@RehabMan, I have a dual boot with MacOs Sierra in one drive and Windows 10 in another drive. What I want to do is to disable hyper threading only in Sierra but left it enabled in BIOS to work in Windows.
I used to do this in the past with the Instruments utility which comes with Xcode, but it doesn’t works in Sierra.
Do you know if it is possible to do it via DSDT?
Thanks in advance, and thanks for your great support!
 
@RehabMan, I have a dual boot with MacOs Sierra in one drive and Windows 10 in another drive. What I want to do is to disable hyper threading only in Sierra but left it enabled in BIOS to work in Windows.
I used to do this in the past with the Instruments utility which comes with Xcode, but it doesn’t works in Sierra.
Do you know if it is possible to do it via DSDT?
Thanks in advance, and thanks for your great support!

No need to disable hyperthreading in macOS.
Not an ACPI issue anyway (therefore off-topic here).
 
Back
Top