Module: wine Branch: master Commit: 22e9093c801d30b31dee5df41e45fca8a57047fe URL: https://gitlab.winehq.org/wine/wine/-/commit/22e9093c801d30b31dee5df41e45fca...
Author: Etaash Mathamsetty etaash.mathamsetty@gmail.com Date: Sat Oct 29 00:15:47 2022 -0400
ntoskrnl.exe: Implement KeQueryActiveProcessorCount.
---
dlls/ntoskrnl.exe/ntoskrnl.c | 10 ++++++++++ dlls/ntoskrnl.exe/ntoskrnl.exe.spec | 1 + 2 files changed, 11 insertions(+)
diff --git a/dlls/ntoskrnl.exe/ntoskrnl.c b/dlls/ntoskrnl.exe/ntoskrnl.c index a0a073eda2e..66c39996d59 100644 --- a/dlls/ntoskrnl.exe/ntoskrnl.c +++ b/dlls/ntoskrnl.exe/ntoskrnl.c @@ -2602,6 +2602,16 @@ ULONG WINAPI KeQueryActiveProcessorCountEx(USHORT group_number) return GetActiveProcessorCount(group_number); }
+ULONG WINAPI KeQueryActiveProcessorCount(PKAFFINITY active_processors) +{ + TRACE("active_processors %p.\n", active_processors); + + if(active_processors) + *active_processors = KeQueryActiveProcessors(); + + return KeQueryActiveProcessorCountEx(ALL_PROCESSOR_GROUPS); +} + /********************************************************************** * KeQueryInterruptTime (NTOSKRNL.EXE.@) * diff --git a/dlls/ntoskrnl.exe/ntoskrnl.exe.spec b/dlls/ntoskrnl.exe/ntoskrnl.exe.spec index cfb74a008b6..0a484829ca3 100644 --- a/dlls/ntoskrnl.exe/ntoskrnl.exe.spec +++ b/dlls/ntoskrnl.exe/ntoskrnl.exe.spec @@ -600,6 +600,7 @@ @ stub KePulseEvent @ stdcall KeQueryActiveProcessors() @ stdcall KeQueryActiveProcessorCountEx(long) +@ stdcall KeQueryActiveProcessorCount(ptr) @ stdcall KeQueryActiveGroupCount() GetActiveProcessorGroupCount @ stdcall KeQueryInterruptTime() @ stdcall KeQueryPriorityThread(ptr)