PfSnStartTraceTimer

INT64 __fastcall PfSnStartTraceTimer(struct EX_RUNDOWN_REF *a1){
  struct _EX_RUNDOWN_REF *v1; 
  struct EX_RUNDOWN_REF *v2; 
  UINT64 v3; 
  UINT64 *p_Count; 
  unsigned __int8 v5; 
  unsigned __int64 v6; 
  char v7; 
  unsigned int v8; 
  v1 = a1 + 45;
  v2 = a1;
  if( ExAcquireRundownProtection(a1 + 45) )
  {
    p_Count = &v2[34].Count;
    KeAcquireSpinLockRaiseToDpc(&v2[34].Count, v3);
    v6 = v5;
    if( (v2[35].Count & 2) != 0 )
    {
      v8 = -1073741431;
    }
    else
    {
      KiSetTimerEx((_KTIMER *)&v2[17], (_LARGE_INTEGER)v2[25].Count, 0i64, 0, (_KDPC *)&v2[26]);
      if( v7 )
      {
        v8 = -1073741595;
      }
      else
      {
        LODWORD(v2[35].Count) |= 1u;
        v2 = 0i64;
        v8 = 0;
      }
    }
    KxReleaseSpinLock(p_Count);
    __writecr8(v6);
    if( v2 )
      ExReleaseRundownProtection(v1);
  }
  else
  {
    return(unsigned int)-1073741431;
  }
  return v8;
}

Referenced by:

PfSnBeginScenario