PspApplyJobChainLimitsToProcess
NTSTATUS __fastcall PspApplyJobChainLimitsToProcess(__int64 a1, __int64 a2, INT64 a3){
_KSCHEDULING_GROUP *v6;
INT64 v7;
PspApplyJobLimitsToProcess((_EPROCESS *)a3, 0i64);
v6 = *(_KSCHEDULING_GROUP **)(a1 + 1016);
if( v6 )
{
if( a2 && *(_QWORD *)(a2 + 1016) || PsCpuFairShareEnabled )
{
PspSetProcessSchedulingGroup((_EPROCESS *)a3, 0i64);
v6 = *(_KSCHEDULING_GROUP **)(a1 + 1016);
}
PspSetProcessSchedulingGroup((_EPROCESS *)a3, v6);
}
v7 = (*(_DWORD *)(a1 + 864) != 0 ? 2 : 0) | 1u;
if( !*(_DWORD *)(a1 + 856) )
v7 = *(_DWORD *)(a1 + 864) != 0 ? 2 : 0;
PspRequestProcessExecutionState(a3, v7, 0);
if( *(_DWORD *)(a1 + 860) && (!a2 || !*(_DWORD *)(a2 + 860)) )
PspNotifyProcessBackgroundTransition((_EPROCESS *)a3, 1ui64);
if( (*(_DWORD *)(a1 + 1320) & 0x40000) != 0 )
_interlockedbittestandset((volatile signed __int32 *)(a3 + 632), 4u);
PsUpdateComponentPower((PEPROCESS)a3, 8i64, *(_QWORD *)(a1 + 1576));
return RtlInterlockedSetClearBits((UINT64 *)(a3 + 1120), 4ui64, 0x20ui64);
}Referenced by:
PspAssignProcessToJob
PspImplicitAssignProcessToJob