Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Expand Minimize

KeGetProcessorIndexFromNumber routine

The KeGetProcessorIndexFromNumber routine converts a group number and a group-relative processor number to a systemwide processor index.

Syntax


ULONG KeGetProcessorIndexFromNumber(
  _In_ PPROCESSOR_NUMBER ProcNumber
);

Parameters

ProcNumber [in]

A pointer to a caller-allocated PROCESSOR_NUMBER structure that contains a group number and a group-relative processor number.

Return value

KeGetProcessorIndexFromNumber returns a systemwide processor index if the call is successful. If ProcNumber points to an invalid PROCESSOR_NUMBER value, the routine returns INVALID_PROCESSOR_INDEX, which is defined in the Wdm.h header file.

Remarks

This routine accepts as input a PROCESSOR_NUMBER structure that identifies a processor by its group number and its processor number within the group. The return value is a processor index that identifies the processor across the entire multiprocessor system.

For example, if a multiprocessor system contains two groups, and each group contains 64 logical processors, the processor numbers in each group range from 0 to 63, but the systemwide processor indexes range from 0 to 127.

To obtain the total number of active logical processors in the system, call the KeQueryActiveProcessorCountEx routine and set this routine's GroupNumber parameter to ALL_PROCESSOR_GROUPS.

The KeGetProcessorNumberFromIndex routine converts a systemwide processor index to a group number and a group-relative processor number.

Requirements

Target platform

Universal

Version

Available in Windows 7 and later versions of Windows.

Header

Wdm.h (include Wdm.h, Ntddk.h, or Ntifs.h)

Library

NtosKrnl.lib

DLL

NtosKrnl.exe

IRQL

Any level

See also

KeGetProcessorNumberFromIndex
KeQueryActiveProcessorCountEx
PROCESSOR_NUMBER

 

 

Send comments about this topic to Microsoft

Show:
© 2015 Microsoft