HvlSvmAttachPasidSpace

INT64 __fastcall HvlSvmAttachPasidSpace(UINT64 a1, INT64 rdx0, INT64 a3, INT64 a4){
  char v4; 
  __int64 v5; 
  int v6; 
  int v7; 
  NTSTATUS v8; 
  __int16 v9; 
  UINT64 v11; 
  __int64 a2; 
  int v13; 
  int v14; 
  v4 = 0;
  v5 = (unsigned int)a1;
  v6 = a3;
  v7 = rdx0;
  if( (HvlpFlags & 2) != 0 )
  {
    v8 = HvlpAttachRootSvmDevice((unsigned int)a1, (unsigned int)a4);
    if( v8 < 0 )
      return(unsigned int)v8;
    v4 = 1;
  }
  a2 = v5;
  v13 = v7;
  v14 = v6;
  while( 1 )
  {
    LODWORD(v11) = 0;
    v9 = HvcallFastExtended(65698i64, &a2, 0x10ui64, 0i64, v11);
    if( (HvlpFlags & 2) == 0 || !HvlpHvStatusIsInsufficientMemory(v9) )
      break;
    if( HvlpHandleInsufficientMemory() < 0 )
    {
      v8 = -1073741670;
      goto LABEL_10;
    }
  }
  v8 = HvlpHvToNtStatus(v9);
  if( v8 >= 0 )
    return(unsigned int)v8;
LABEL_10:
  if( v4 )
    HvlpDetachRootSvmDevice((unsigned int)v5);
  return(unsigned int)v8;
}

Referenced by:

No references.