HalpBlkPoWritePerfMsr

NTSTATUS __stdcall HalpBlkPoWritePerfMsr(ULONG_PTR a1){
  int v1; 
  __int64 v2; 
  __int64 v3; 
  __int64 v4; 
  __int64 v6; 
  void *v7; 
  int v8; 
  __int64 v9; 
  unsigned __int64 v10; 
  int v11; 
  __int64(__fastcall *v12)(_QWORD, int *, __int128 *, __int64, int *); 
  NTSTATUS v13; 
  __int128 v15; 
  __int64 v16; 
  int v17; 
  int v18; 
  int v19; 
  int v20; 
  int v21; 

  v4 = v3;
  v6 = v2;
  v7 = (void *)a1;
  v8 = v1;
  v9 = *(_QWORD *)(*(&CmpDummyThreadEvent + 487) + 8i64 * a1);
  v10 = (unsigned __int8)KeAcquireSpinLockRaiseToDpc((UINT64 *)(v9 + 2216));
  HalpBlkPoBusyWait(2u, a1, v9 + 2216);
  *(_DWORD *)(v9 + 2236) = v8;
  *(_DWORD *)(v9 + 2228) = 2;
  *(_DWORD *)(v9 + 2232) = 1;
  *(_QWORD *)(v9 + 2240) = v6;
  *(_QWORD *)(v9 + 2248) = v4;
  _InterlockedExchange((volatile __int32 *)(v9 + 2224), 1);
  v11 = *(_DWORD *)(v9 + 20);
  v18 = -1;
  v15 = 0i64;
  DWORD2(v15) = v11;
  v16 = 0i64;
  LODWORD(v15) = 4;
  v19 = 1;
  v21 = *(_DWORD *)(qword_140C50700 + 20);
  v20 = *(_DWORD *)(qword_140C50700 + 16);
  v12 = *(__int64(__fastcall **)(_QWORD, int *, __int128 *, __int64, int *))(Controller + 120);
  _disable();
  v13 = v12(*(_QWORD *)(Controller + 16), &v20, &v15, 225i64, &v18);
  if( (v17 & 0x200) != 0 )
    _enable();
  if( v13 < 0 )
    KeBugCheckEx(0x1DAu, (PVOID)4, (PVOID)2, v7, (PVOID)(v9 + 2216));
  KxReleaseSpinLock((UINT64 *)(v9 + 2216));
  __writecr8(v10);
  return v13;
}

Referenced by:

No references.