GetProcessAffinityMask
GetProcessAffinityMask retrieves the process affinity mask for the specified process and the system affinity mask for Real-Time Subsystem (RTSS).
Syntax
BOOL GetProcessAffinityMask(
[in] HANDLE hProcess,
[out] PDWORD PTR lpProcessAffinityMask,
[out] PDWORD PTR lpSystemAffinityMask
);
Parameters
[in] hProcess
A handle to the process whose affinity mask is desired.
[out] lpProcessAffinityMask
A pointer to a variable that receives the affinity mask for the specified process.
[out] lpSystemAffinityMask
A pointer to a variable that receives the affinity mask for Real-Time Subsystem (RTSS).
Return Value
If the function succeeds, it returns a non-zero value. The function sets the variables pointed to by lpProcessAffinityMask and lpSystemAffinityMask to the appropriate affinity masks.
If the function fails, it returns 0 (zero). The values of the variables pointed to by lpProcessAffinityMask and lpSystemAffinityMask are undefined.
To get extended error information, call GetLastError.
Remarks
A process affinity mask is a bit vector in which each bit represents the processors that a process is allowed to run on. A system affinity mask is a bit vector in which each bit represents the processors that are configured for the Real-Time Subsystem (RTSS). See Specifying a Processor Affinity Bitmask for more details.
Requirements
| Minimum supported version | Header | Library |
|---|---|---|
|
wRTOS 1.0 SDK |
windows.h |
wRTOS_rtss.lib |
See Also: