Contribute
Register
Status
Not open for further replies.
I've read it and I've understood how to debug ACPI but I'm still confused how to proceed with fixing Wake On USB.

Use ACPIDebug to print the data that is being returned from _PRW.
For example, original XHC._PRW:
Code:
            Method (_PRW, 0, NotSerialized)  // _PRW: Power Resources for Wake
            {
                If (ULTP)
                {
                    Return (GPRW (0x6D, Zero))
                }
                Else
                {
                    Return (GPRW (0x0D, Zero))
                }
            }

Instrumented:
Code:
            Method (_PRW, 0, NotSerialized)  // _PRW: Power Resources for Wake
            {
                If (ULTP)
                {
                    Local0 = GPRW (0x6D, Zero)
                }
                Else
                {
                    Local0 = GPRW (0x0D, Zero)
                }
                \rmdt.p2("XHC._PRW return", Local0)
                Return(Local0)
            }

Similar code can be implemented in other _PRW methods.

You can then check the result against your expectations by looking at the output from ACPIDebug in your kernel log.

And you should check your kernel log for wake reason, for example after an instant wake:
Code:
log show --predicate processID==0 --info --debug --last 5m|grep -y "wake reason"
 
Use ACPIDebug to print the data that is being returned from _PRW.
For example, original XHC._PRW:
What if a package is being returned? Example:
Code:
Method (_PRW, 0, NotSerialized)  // _PRW: Power Resources for Wake
            {
                Return (Package (0x02)
                {
                    0x0E,
                    0x04
                })
            }
Should I use \rmdt.p3 in the above case? Should I store 0x0E and 0x04 in separate variables?
 
What if a package is being returned? Example:
Code:
Method (_PRW, 0, NotSerialized)  // _PRW: Power Resources for Wake
            {
                Return (Package (0x02)
                {
                    0x0E,
                    0x04
                })
            }
Should I use \rmdt.p3 in the above case? Should I store 0x0E and 0x04 in separate variables?

In that code, you know exactly what is being returned as it is all there in the code... Package() { 14, 4 }...
What are you trying to do?
I think you should be instrumenting other _PRW methods...
 
In that code, you know exactly what is being returned as it is all there in the code... Package() { 14, 4 }...
What are you trying to do?
I think you should be instrumenting other _PRW methods...

ACPIDebug isn't printing anything in kernel log
Wake reason: PEGA XHC

Instrumented DSDT attached.
 

Attachments

  • DSDT.aml
    89.4 KB · Views: 99

Attachments

  • kernel log 2017-06-06.txt
    8.3 MB · Views: 329
ACPIDebug provides output during startup but I don't see how it relates to Instant Wake.
Wake reason: PEGA XHC

Kernel log from today is attached.
Problem reporting files attached in post #76

You should try patching PEGA._PRW (in SSDT-7) to return Package() { 9, 0 }.
 
You should try patching PEGA._PRW (in SSDT-7) to return Package() { 9, 0 }.
OH MY GOD I CANT BELIVE IT. ENTERED SLEEP SUCCESSFULLY.
I've been troubleshooting this for almost a year now. Thank you so much for your time and patience.
 
Status
Not open for further replies.
Back
Top