Contribute
Register

[Guide] USB power property injection for Sierra (and later)

RehabMan

Moderator
Joined
May 2, 2012
Messages
183,494
Motherboard
Intel DH67BL
CPU
i7-2600K
Graphics
HD 3000
Mac
  1. MacBook Air
Mobile Phone
  1. iOS
Thanks, RehabMan. That guidance, I can work with... especially since you were kind enough to use iMac 17,1 as your example. Since my AppleBusPowerController.kext info.plist did not include the iMac 17,1 SMBIOS, I had nothing to override. So, I just compiled the two patches you referenced above and placed them in in Clover/ACPI/Patched and restarted.

USBX is now appearing in the IOreg, and if the measure of success is that a USB port will charge an iPad, then I'm in good shape, because my iPad is charging as I type this.

Still, if you have a moment to take a peek to make sure I've done this correctly, I'd be grateful. Thanks again for your guidance.

No ioreg in those PR files, but ACPI/patched looks ok.
 
Joined
Sep 1, 2016
Messages
542
Motherboard
Gigabyte Z490 I Aorus Ultra
CPU
i9-10900K
Graphics
RX 580
No ioreg in those PR files, but ACPI/patched looks ok.

That's odd. I used VioletDragon's script to collect. Thanks for the verification, and here's the IOreg, if it helps.
 

Attachments

  • Bill’s iMac.ioreg
    3.8 MB · Views: 121

RehabMan

Moderator
Joined
May 2, 2012
Messages
183,494
Motherboard
Intel DH67BL
CPU
i7-2600K
Graphics
HD 3000
Mac
  1. MacBook Air
Mobile Phone
  1. iOS
That's odd. I used VioletDragon's script to collect. Thanks for the verification, and here's the IOreg, if it helps.

As far as this guide, looks good.
(you have other problems though... such as CPU PM not implemented, perhaps others).
 
Joined
Apr 2, 2018
Messages
18
Motherboard
GA-Z390 Designare
CPU
i9-9900K
Graphics
UHD630
Mac
  1. MacBook Pro
Read post #1 carefully.

Well ok , I had the wrong impression.
I've added Device USBX to SSDT-UIAC but the properties I'd like to inject still not there.
There must be some other mistake I'm making, unfortunately I can't figure it out !

Please take a look again, thank you.
 

Attachments

  • debug_SSDT-EC_SSDT-UIAC:USBX.zip
    2 MB · Views: 109

RehabMan

Moderator
Joined
May 2, 2012
Messages
183,494
Motherboard
Intel DH67BL
CPU
i7-2600K
Graphics
HD 3000
Mac
  1. MacBook Air
Mobile Phone
  1. iOS
Well ok , I had the wrong impression.
I've added Device USBX to SSDT-UIAC but the properties I'd like to inject still not there.
There must be some other mistake I'm making, unfortunately I can't figure it out !

Please take a look again, thank you.

Your code in _SB.USBX._DSM is wrong.
This code:
Code:
        Method (_DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
        {
            If (Arg2)

Should be:
Code:
        Method (_DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
        {
            If (!Arg2)

Read post #1 carefully... it has the correct code for _DSM.
 
Joined
Apr 2, 2018
Messages
18
Motherboard
GA-Z390 Designare
CPU
i9-9900K
Graphics
UHD630
Mac
  1. MacBook Pro
Your code in _SB.USBX._DSM is wrong.
This code:
Code:
        Method (_DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
        {
            If (Arg2)

Should be:
Code:
        Method (_DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
        {
            If (!Arg2)

Read post #1 carefully... it has the correct code for _DSM.

In fact I did read carefully and added the code as provided but during compilation
the "!" gets lost...
I get the following error message : In Line 26 / Code 6126 "Invalid character (0x21) expecting ASL keyword or name"

NEVER MIND , I SOLVED IT !

Now all working as expected , thank you !!
 
Last edited:

RehabMan

Moderator
Joined
May 2, 2012
Messages
183,494
Motherboard
Intel DH67BL
CPU
i7-2600K
Graphics
HD 3000
Mac
  1. MacBook Air
Mobile Phone
  1. iOS
In fact I did read carefully and added the code as provided but during compilation
the "!" gets lost...
I get the following error message : In Line 26 / Code 6126 "Invalid character (0x21) expecting ASL keyword or name"

Must use correct version of MaciASL.
It is linked from the ACPI guide:
https://www.tonymacx86.com/threads/guide-patching-laptop-dsdt-ssdts.152573/

NEVER MIND , I SOLVED IT !

Now all working as expected , thank you !!

My guess is you discovered the correct tools (MaciASL/iasl)...
 
Joined
Apr 2, 2018
Messages
18
Motherboard
GA-Z390 Designare
CPU
i9-9900K
Graphics
UHD630
Mac
  1. MacBook Pro
Top