RtlpHpSegFreeRangeRemove

NTSTATUS __stdcall RtlpHpSegFreeRangeRemove(INT64 a1, UINT64 a2){
  unsigned __int16 v4; 
  __int64 v5; 
  __int64 v6; 

  RtlRbRemoveNode((UINT64 *)(a1 + 96), a2);
  *(_OWORD *)a2 = 0i64;
  *(_QWORD *)(a2 + 16) = 0i64;
  v4 = ~(unsigned __int16)*(_DWORD *)(a2 + 28);
  *(_DWORD *)a2 = -857879331;
  v5 = v4;
  v6 = *(__int16 *)(a1 + 22);
  _InterlockedExchangeAdd64((volatile signed __int64 *)(v6 + a1 + 16), -v5);
  return v6;
}

Referenced by:

RtlpHpSegContextCompact
RtlpHpSegLargeRangeAllocate
RtlpHpSegPageRangeCoalesce