MCPcopy Create free account
hub / github.com/WinDurango/WinDurango / FreeTitlePhysicalPages

Function FreeTitlePhysicalPages

projects/WinDurango.KernelX/src/kernelx.cpp:209–227  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

207 FoundContiguousPages = FALSE;
208 break;
209 }
210 }
211
212 if (!FoundContiguousPages)
213 {
214 i++;
215 continue;
216 }
217
218 for (ULONG_PTR j = 0; j < PagesPerRegion; j++)
219 {
220 XwpPhysicalPages[i + j] = true;
221 PageArray[PagesAllocated++] = i + j;
222 }
223
224 i += PagesPerRegion;
225 }
226
227 ReleaseSRWLockExclusive(&XwpPhysicalMemoryLock);
228 *NumberOfPages = PagesAllocated;
229 SetLastError(PagesAllocated > 0 ? ERROR_SUCCESS : ERROR_OUTOFMEMORY);
230 return PagesAllocated > 0;

Callers

nothing calls this directly

Calls 1

SetLastErrorFunction · 0.85

Tested by

no test coverage detected