ReactOS  0.4.13-dev-100-gc8611ae
ke.c File Reference
#include <ntdef.h>
#include <ntifs.h>
Include dependency graph for ke.c:

Go to the source code of this file.

Functions

NTKERNELAPI ULONG NTAPI KeQueryActiveProcessorCount (OUT PKAFFINITY ActiveProcessors OPTIONAL)
 

Function Documentation

◆ KeQueryActiveProcessorCount()

NTKERNELAPI ULONG NTAPI KeQueryActiveProcessorCount ( OUT PKAFFINITY ActiveProcessors  OPTIONAL)

Definition at line 15 of file ke.c.

16 {
18  KAFFINITY ActiveMap = KeQueryActiveProcessors();
19 
20  if (ActiveProcessors != NULL)
21  {
22  *ActiveProcessors = ActiveMap;
23  }
24 
25  RtlInitializeBitMap(&Bitmap, (PULONG)&ActiveMap, sizeof(ActiveMap) * 8);
26  return RtlNumberOfSetBits(&Bitmap);
27 }
NTSYSAPI void WINAPI RtlInitializeBitMap(PRTL_BITMAP, PULONG, ULONG)
NTSYSAPI ULONG WINAPI RtlNumberOfSetBits(PCRTL_BITMAP)
smooth NULL
Definition: ftsmooth.c:416
KAFFINITY NTAPI KeQueryActiveProcessors(VOID)
Definition: cpu.c:433
ULONG_PTR KAFFINITY
Definition: compat.h:75
unsigned int * PULONG
Definition: retypes.h:1

Referenced by calc_csum(), check_csum(), and create_calc_threads().