diff --git a/EFI-OpenCore/EFI/OC/ACPI/SSDT-AC.aml b/EFI-OpenCore/EFI/OC/ACPI/SSDT-AC.aml new file mode 100644 index 0000000..8563a32 Binary files /dev/null and b/EFI-OpenCore/EFI/OC/ACPI/SSDT-AC.aml differ diff --git a/EFI-OpenCore/EFI/OC/config.plist b/EFI-OpenCore/EFI/OC/config.plist index 3ce998a..347b098 100755 --- a/EFI-OpenCore/EFI/OC/config.plist +++ b/EFI-OpenCore/EFI/OC/config.plist @@ -22,6 +22,14 @@ Path SSDT-INIT.aml + + Comment + Patch AC: Load AppleACPIACAdapter + Enabled + + Path + SSDT-AC.aml + Comment Patch Battery diff --git a/patches/SSDT-AC.dsl b/patches/SSDT-AC.dsl new file mode 100644 index 0000000..1922988 --- /dev/null +++ b/patches/SSDT-AC.dsl @@ -0,0 +1,37 @@ +// +// AC-Adapter +// + +DefinitionBlock ("", "SSDT", 2, "tyler", "_AC", 0x00001000) +{ + // Common utils from SSDT-Darwin.dsl + External (OSDW, MethodObj) // 0 Arguments + + External (_SB.PCI0.LPCB.EC.AC, DeviceObj) + External (LWCP, FieldUnitObj) // LID control power + + // Patching AC-Device so that AppleACPIACAdapter-driver loads. + // Device named ADP1 on Mac + // See https://github.com/khronokernel/DarwinDumped/blob/b6d91cf4a5bdf1d4860add87cf6464839b92d5bb/MacBookPro/MacBookPro14%2C1/ACPI%20Tables/DSL/DSDT.dsl#L7965 + Scope (\_SB.PCI0.LPCB.EC.AC) + { + Method (_PRW, 0, NotSerialized) // _PRW: Power Resources for Wake + { + If (\OSDW () || \LWCP) + { + Return (Package (0x02) + { + 0x17, + 0x04 + }) + } + + Return (Package (0x02) + { + 0x17, + 0x03 + }) + } + } +} +// EOF