HvlLpWriteMultipleMsr
INT64 __stdcall HvlLpWriteMultipleMsr(UINT64 LpIndex, UINT64 Count, UINT64 *MsrIndices, UINT64 *MsrValues){
int v5;
unsigned __int64 v6;
__int64 v8;
int v9;
LONGLONG *v11;
_DWORD *v12;
int v13;
__int64 v14;
__int16 v15;
unsigned int v16;
__int128 v17[3];
v5 = Count;
v6 = 32i64 * (unsigned int)Count;
v8 = (unsigned int)Count;
v9 = LpIndex;
memset(v17, 0, 32);
if( v6 > 0x1000 )
return 3221225485i64;
v11 = HvlpAcquireHypercallPage((PHYSICAL_ADDRESS *)v17, 1, 0i64, v6);
if( v5 )
{
v12 = v11 + 1;
do
{
*(v12 - 2) = v9;
*(v12 - 1) = 65537;
v13 = *(_DWORD *)MsrIndices;
MsrIndices = (UINT64 *)((char *)MsrIndices + 4);
*v12 = v13;
v12 += 8;
v14 = *MsrValues++;
*((_QWORD *)v12 - 3) = v14;
--v8;
}
while( v8 );
}
HvcallInitiateHypercall();
v16 = v15 != 0 ? 0xC0000001 : 0;
HvlpReleaseHypercallPage((unsigned int *)v17);
return v16;
}Referenced by:
No references.