I have now attached the Problem Reporting Files. For the instant Wake I had used in the past were I had patched directly my DSDT with these patches usb_prw_0x6d_xhc_skl.txt and usb_prw_0x0d_xhc_skl.txt and then I had no instant wake anymore. Maybe there is a possiblity to implement these patches with an Hotpatch? I have also moved the Kext from the Clover Folder to /Library/Extensions and edit the SSDT-IGPU.dsl with only one Patch that will disable may DGPU.
You should not apply multiple _PRW patches.
Apply only the patch that corresponds to the value your native DSDT uses (it is obvious when looking at the preview in MaciASL).
Your DSDT uses 0x6d. Look at _PRW in XHC for example:
Code:
Method (_PRW, 0, NotSerialized) // _PRW: Power Resources for Wake
{
Return (GPRW (0x6D, 0x04))
}
You could patch GPRW and UPRW in order to solve instant wake (essentially disabling USB wake).
There are patches in the hotpatch repo that do this... (for GPRW), but the UPRW you will need to write custom code as it is different from other UPRW methods I've seen.
I would either patch _PRW in XHC directly (eg. create a targeted rename patch for it, and provide new XHC._PRW in an SSDT), or rename the UPRW method, to provide a replacement for it in an SSDT.
Or you might take the approach I just did with the Intel ComputeStick. I found that it suffered from "instant wake", but I did not want to disable wake on USB (it is a desktop, and the power button is very small and likely hard to reach).
I found that two things were causing instant wake... by checking "Wake reason" after an instant wake event:
Code:
log show --predicate processID==0 --info --debug|grep -y "Wake reason"
Showed that GLAN and XDCI were causing the wake...
Then I looked in ioreg and found that GLAN and XDCI were not present in IOService. GLAN I could have predicted as this device has WiFi only. XDCI I would have to read up on it in the 100-series chipset data sheet to understand why it is not present...
But no matter, the problem is these two devices declare a _PRW, return "present" from _STA, but are not present on the PCIe bus... The fix (which I tested first with static patch), is to return 0 from _STA, or patch _PRW as normal... Either worked. But _STA turned out easier to patch with hotpatch, so I went that route.
Your first task is to determine which device is causing the instant wake (run the "log show" I mention above after an instant wake event). From there you can decide how to address it.
Just looking at the ioreg, I can see that you don't have any Ethernet, and you do have a GLAN device... and a XDCI device... and both are not present in IOService. In fact, your DSDT with regard to these two objects is identical to the code for my Intel ComputeStick... If it turns out this is the cause, you can probably use the same solution already checked into my NUC repo.