1

When I connect a Lenovo laptop with embedded Intel Graphics to an eGPU dock (Nvidia) which drives all monitors, the CPU usage remains high with the kernel ("System") always consuming more than 8% CPU.

Using procexp to view the kernel threads, I can see a number of simultaneous calls to PoFxReportDevicePoweredOn, which makes me suspect a misbehaving driver. Guessing random drivers to disable, though, did not locate the issue.

How can I locate the misbehaving driver?

Mitch
  • 1,143
  • 1
  • 9
  • 16
  • That is exactly my case. After I've disconnected the Lenovo P1 laptop from the Lenovo Dock Station the CPU consumption returned back to normal – Dmytro Ovdiienko Nov 13 '22 at 21:30

2 Answers2

2

You can run an xperf trace to capture driver power events with:

C:\> xperf.exe -start power_session -on Microsoft-Windows-Kernel-Power
C:\> timeout 15
C:\> xperf.exe -stop power_session
C:\> xperf.exe -i c:\user.etl > c:\power_log.txt
C:\> start c:\power_log.txt

Search the log for lines starting with Microsoft-Windows-Kernel-Power/Irp/win:Start and ending with 0 (which represents a transition to D0 power state). Whatever is calling PoFxReportDevicePoweredOn will have it's device path listed.

Microsoft-Windows-Kernel-Power/Irp/win:Start,  TimeStamp,     Process Name ( PID),   ThreadID, CPU, etw:ActivityId, etw:Related ActivityId, etw:UserSid, etw:SessionId, Irp, PowerStateType, MinorFunction, TargetDevice, InstanceNameLength, InstanceName, PowerState
Microsoft-Windows-Kernel-Power/Irp/win:Start,      15417,        "Unknown" (   4),         20,   2, , , , , 0xffffaa0804fb1c20, 1, 2, 0xffffaa07fd742ca0, 60, "PCI\VEN_8086&DEV_5917&SUBSYS_225917AA&REV_07\3&11583659&0&10", 0
Microsoft-Windows-Kernel-Power/Irp/win:Start,      93924,        "Unknown" (   4),        660,   1, , , , , 0xffffaa0804fb1c20, 1, 2, 0xffffaa07fd742ca0, 60, "PCI\VEN_8086&DEV_5917&SUBSYS_225917AA&REV_07\3&11583659&0&10", 3
Microsoft-Windows-Kernel-Power/Irp/win:Start,     442694,        "Unknown" (   4),         20,   0, , , , , 0xffffaa0804fb1c20, 1, 2, 0xffffaa07fd742ca0, 60, "PCI\VEN_8086&DEV_5917&SUBSYS_225917AA&REV_07\3&11583659&0&10", 0
Microsoft-Windows-Kernel-Power/Irp/win:Start,     506018,        "Unknown" (   4),        660,   0, , , , , 0xffffaa0804fb1c20, 1, 2, 0xffffaa07fd742ca0, 60, "PCI\VEN_8086&DEV_5917&SUBSYS_225917AA&REV_07\3&11583659&0&10", 3
Microsoft-Windows-Kernel-Power/Irp/win:Start,     856490,        "Unknown" (   4),         20,   3, , , , , 0xffffaa0804fb1c20, 1, 2, 0xffffaa07fd742ca0, 60, "PCI\VEN_8086&DEV_5917&SUBSYS_225917AA&REV_07\3&11583659&0&10", 0
Microsoft-Windows-Kernel-Power/Irp/win:Start,     934942,        "Unknown" (   4),        660,   0, , , , , 0xffffaa0804fb1c20, 1, 2, 0xffffaa07fd742ca0, 60, "PCI\VEN_8086&DEV_5917&SUBSYS_225917AA&REV_07\3&11583659&0&10", 3
Microsoft-Windows-Kernel-Power/Irp/win:Start,    1296908,        "Unknown" (   4),         20,   6, , , , , 0xffffaa0804fb1c20, 1, 2, 0xffffaa07fd742ca0, 60, "PCI\VEN_8086&DEV_5917&SUBSYS_225917AA&REV_07\3&11583659&0&10", 0
Microsoft-Windows-Kernel-Power/Irp/win:Start,    1377503,        "Unknown" (   4),        660,   0, , , , , 0xffffaa0804fb1c20, 1, 2, 0xffffaa07fd742ca0, 60, "PCI\VEN_8086&DEV_5917&SUBSYS_225917AA&REV_07\3&11583659&0&10", 3
Microsoft-Windows-Kernel-Power/Irp/win:Start,    1724611,        "Unknown" (   4),         20,   3, , , , , 0xffffaa0804fb1c20, 1, 2, 0xffffaa07fd742ca0, 60, "PCI\VEN_8086&DEV_5917&SUBSYS_225917AA&REV_07\3&11583659&0&10", 0

You can get the description of the device with Get-PnPDevice:

PS C:\WINDOWS\system32> Get-PnPDevice 'PCI\VEN_8086&DEV_5917&SUBSYS_225917AA&REV_07\3&11583659&0&10'

Status     Class           FriendlyName                                                                     InstanceId
------     -----           ------------                                                                     ----------
OK         Display         Intel(R) UHD Graphics 620                                                        PCI\VEN_...

In my case, the culprit was "Intel(R) UHD Graphics 620", which was rapidly transitioning between D3 (sleep) and D0 (powered on). Since the eGPU was driving all displays, I disabled the Intel graphics driver in Device Manager, and the problem ceased.

Mitch
  • 1,143
  • 1
  • 9
  • 16
  • Thanks so much. I was having microstutters and the situation in Process Explorer was similar. The problem device for me was PCI\VEN_10DE&DEV_2420&SUBSYS_0B2B1028&REV_A1\4&6bd3583&0&0008, or the NVIDIA "High Definition Audio Controller". I disabled it in Device Manager and the problem immediately stopped. I'm not sure why the NVIDIA audio controller was doing anything, anyway; it has not been in use, I do not and have not connected any displays to the NVIDIA GPU. (This is on a laptop in Optimus configuration with the Intel GPU driving all of the displays.) – Truisms Hounds Mar 02 '23 at 01:41
0

I had the same problem, which was fixed with the following workaround:

in the NVIDIA Control Panel, under Manage 3d Settings, configure one of the applications you are usually running to use NVIDIA GPU.

This will prevent the GPU switches to power save mode and wake up permanently.

I found this workaround in this thread: https://answers.microsoft.com/en-us/windows/forum/all/high-cpu-usage-by-process-called-system/0714de1f-8ee6-4b5a-928e-1f1989e12414