MiFlushDataSection

UINT64 __stdcall MiFlushDataSection(FILE_OBJECT *File){
  _DWORD *v1; 
  _DWORD *v2; 
  _SECTION_OBJECT_POINTERS *SectionObjectPointer; 
  UINT64 result; 
  int v6; 
  _KEVENT *v7; 
  _SECTION_OBJECT_POINTERS *v8; 
  UINT64 Flags; 
  _IO_STATUS_BLOCK IoStatus; 
  KIRQL v11; 
  *v1 = 0;
  v2 = v1;
  v11 = 0;
  SectionObjectPointer = File->SectionObjectPointer;
  IoStatus = 0i64;
  result = MiLockSectionControlArea(SectionObjectPointer, 1, &v11);
  if( result )
  {
    if( *(_DWORD *)(result + 92) || *(_QWORD *)(result + 112) > 1ui64 )
      *v2 = 1;
    v6 = *(_DWORD *)(result + 88);
    ExReleaseSpinLockExclusiveFromDpcLevel((INT64 *)(result + 72));
    __writecr8(v11);
    v8 = File->SectionObjectPointer;
    if( v6 )
    {
      CcFlushCachePriv(v8, &CcFlushForImageSection, 0i64, 0i64, 0, &IoStatus);
      return(unsigned int)IoStatus.Status;
    }
    else
    {
      LODWORD(Flags) = 1;
      MmFlushSection(v8, 0i64, 0i64, v7, &IoStatus, Flags);
    }
  }
  return result;
}

Referenced by:

MiCreateImageFileMap