PfSnSetPrefetcherInformation
NTSTATUS __stdcall PfSnSetPrefetcherInformation(
PVOID SystemInformation,
UINT64 SystemInformationLength,
INT8 PreviousMode){
INT8 v3;
CHAR v4;
int v5;
int v6;
int v8;
bool v9;
unsigned int v10;
__int128 v11;
__int128 v12;
INT64 v13;
int v14;
INT64 v15;
int v16;
__int128 v17;
int v18;
__int128 v19;
INT64 a1[2];
__int128 v21;
__int128 v22;
__int128 v23;
__int64 v24;
v4 = v3;
if( PreviousMode != 32 )
return -1073741820;
v11 = *(_OWORD *)SystemInformationLength;
v12 = *(_OWORD *)(SystemInformationLength + 16);
if( *(_QWORD *)SystemInformationLength != 0x6B75684300000001i64 )
return -1073741811;
if( DWORD2(v11) > 8 || (v5 = 296, !_bittest(&v5, DWORD2(v11))) )
{
if( !SeSinglePrivilegeCheck(*(_QWORD *)&SeProfileSingleProcessPrivilege, v3) )
return -1073741790;
}
if( DWORD2(v11) == 3 )
{
if( DWORD2(v12) != 4 )
return -1073741811;
if( v4 && (v12 & 3) != 0 )
ExRaiseDatatypeMisalignment();
v10 = *(_DWORD *)v12;
if( *(_DWORD *)v12 == 2 || !v4 )
{
v6 = PfSnBeginBootPhase(v10);
if( v10 == 2 )
{
v17 = 0i64;
v18 = 0;
v15 = 0x400000004i64;
v16 = 1;
PfpProcessScenarioPhase((INT64)&v15, v4);
}
v9 = v6 < 0;
LABEL_23:
if( v9 )
return v6;
return 0;
}
return -1073741790;
}
if( DWORD2(v11) == 5 )
{
if( DWORD2(v12) == 12 )
{
if( v4 && (v12 & 3) != 0 )
ExRaiseDatatypeMisalignment();
v13 = *(_QWORD *)v12;
v14 = *(_DWORD *)(v12 + 8);
v8 = PfSnOperationProcess((INT64)&v13);
LABEL_22:
v6 = v8;
v9 = v8 < 0;
goto LABEL_23;
}
return -1073741811;
}
if( DWORD2(v11) != 6 )
{
if( DWORD2(v11) != 8 )
return -1073741821;
if( DWORD2(v12) != 16 )
return -1073741306;
if( v4 && (v12 & 7) != 0 )
ExRaiseDatatypeMisalignment();
v19 = *(_OWORD *)v12;
v8 = PfSnAppLaunchScenarioControl((INT64)&v19, v4);
goto LABEL_22;
}
if( DWORD2(v12) != 72 )
return -1073741306;
if( v4 && (v12 & 3) != 0 )
ExRaiseDatatypeMisalignment();
*(_OWORD *)a1 = *(_OWORD *)v12;
v21 = *(_OWORD *)(v12 + 16);
v22 = *(_OWORD *)(v12 + 32);
v23 = *(_OWORD *)(v12 + 48);
v24 = *(_QWORD *)(v12 + 64);
if( LODWORD(a1[0]) != 2 )
return -1073741811;
PfSnPrefetchCacheEntryUpdate((INT64)a1);
return 0;
}Referenced by:
NtSetSystemInformation