[DELAYIMP] Fix 2 Clang-Cl warnings about __pfnDliNotifyHook2Default and __pfnDliFailu...
[reactos.git] / sdk / lib / drivers / ntoskrnl_vista / ke.c
1 /*
2 * PROJECT: ReactOS Kernel - Vista+ APIs
3 * LICENSE: GPL v2 - See COPYING in the top level directory
4 * FILE: lib/drivers/ntoskrnl_vista/ke.c
5 * PURPOSE: Ke functions of Vista+
6 * PROGRAMMERS: Pierre Schweitzer <pierre@reactos.org>
7 */
8
9 #include <ntdef.h>
10 #include <ntifs.h>
11
12 NTKERNELAPI
13 ULONG
14 NTAPI
15 KeQueryActiveProcessorCount(OUT PKAFFINITY ActiveProcessors OPTIONAL)
16 {
17 RTL_BITMAP Bitmap;
18 KAFFINITY ActiveMap = KeQueryActiveProcessors();
19
20 if (ActiveProcessors != NULL)
21 {
22 *ActiveProcessors = ActiveMap;
23 }
24
25 RtlInitializeBitMap(&Bitmap, &ActiveMap, sizeof(ActiveMap) * 8);
26 return RtlNumberOfSetBits(&Bitmap);
27 }