107MmNotPresentFaultCachePage (
124 DPRINT(
"Not Present: %p %p (%p-%p)\n",
171 DPRINT(
"Have file and page, set page %x in section @ %x #\n",
229 DPRINT(
"Take reference to page %x #\n",
Page);
233 DPRINT1(
"Found no PFN entry for page 0x%x in page entry 0x%x (segment: 0x%p, offset: %08x%08x)\n",
259 DPRINT(
"Get page into section\n");
289 PVOID TempAddress, TempSource;
293 if (TempAddress ==
NULL)
324MiCowCacheSectionPage (
338 DPRINT(
"MmAccessFaultSectionView(%p, %p, %p, %u)\n",
364 DPRINTC(
"setting non-cow page %p %p:%p offset %I64x (%Ix) to writable\n",
393 DPRINT(
"Not supposed to be writable\n");
407 if (SwapEntry == MM_WAIT_ENTRY)
428 DPRINT(
"Allocated page %x\n", NewPage);
435 MiCopyPageToPage(NewPage, OldPage);
446 DPRINT1(
"MmCreateVirtualMapping failed, not out of memory\n");
590 DPRINT(
"Type %x (%p -> %p)\n",
627 DPRINT(
"Already fault handling ... going to work item (%Ix)\n",
638 DPRINT(
"Queue work item\n");
666 DPRINT1(
"Type %x (%p -> %p)\n",
707 DPRINT1(
"Page fault at high IRQL %u, address %Ix\n",
788 DPRINT1(
"Process %p, Address %Ix\n",
794 DPRINTC(
"Type %x (%p -> %08Ix -> %p) in %p\n",
832 DPRINT(
"Clear resource\n");
839 DPRINTC(
"Already fault handling ... going to work item (%Ix)\n",
Address);
849 DPRINT(
"Queue work item\n");
864 DPRINT(
"DoAcquisition %p -> %x\n",
886 DPRINTC(
"Completed page fault handling: %p:%Ix %x\n",
927 DPRINT1(
"Page fault at high IRQL %u, address %Ix\n",
952 Status = MmNotPresentFaultCacheSectionInner(
Mode,
961 DPRINT(
"MmAccessFault %p:%Ix -> %x\n",
DECLSPEC_NORETURN VOID NTAPI KeBugCheck(ULONG BugCheckCode)
_In_ PFCB _In_ LONGLONG FileOffset
#define NT_SUCCESS(StatCode)
#define PsGetCurrentThread()
#define KeWaitForSingleObject(pEvt, foo, a, b, c)
#define KeInitializeEvent(pEvt, foo, foo2)
#define KeSetEvent(pEvt, foo, foo2)
#define KeGetCurrentIrql()
_In_opt_ PFILE_OBJECT _In_opt_ PETHREAD Thread
_Must_inspect_result_ _In_ PLARGE_INTEGER _In_ PLARGE_INTEGER _In_ ULONG _In_ PFILE_OBJECT _In_ PVOID Process
void __cdecl __debugbreak(void)
#define memcpy(s1, s2, n)
#define _Function_class_(x)
NTSTATUS NTAPI MmAccessFaultCacheSection(KPROCESSOR_MODE Mode, ULONG_PTR Address, BOOLEAN FromMdl)
_In_ PMEMORY_AREA _In_ PVOID _In_ BOOLEAN _Inout_ PMM_REQUIRED_RESOURCES Required
_In_ PMEMORY_AREA MemoryArea
NTSTATUS NTAPI MiReadFilePage(PMMSUPPORT AddressSpace, PMEMORY_AREA MemoryArea, PMM_REQUIRED_RESOURCES RequiredResources)
_In_ PMEMORY_AREA _In_ PVOID _In_ BOOLEAN Locked
NTSTATUS NTAPI MmNotPresentFaultCacheSection(KPROCESSOR_MODE Mode, ULONG_PTR Address, BOOLEAN FromMdl)
NTSTATUS NTAPI MiGetOnePage(PMMSUPPORT AddressSpace, PMEMORY_AREA MemoryArea, PMM_REQUIRED_RESOURCES RequiredResources)
NTSTATUS(NTAPI * AcquireResource)(PMMSUPPORT AddressSpace, struct _MEMORY_AREA *MemoryArea, struct _MM_REQUIRED_RESOURCES *Required)
#define PAGE_EXECUTE_READWRITE
_In_ ULONG _In_ ULONG Offset
#define IMAGE_SCN_MEM_SHARED
#define MmSystemRangeStart
#define MmSetDirtyPage(__P, __A)
#define MmGetPageEntrySectionSegment(S, O)
FORCEINLINE PMMPFN MiGetPfnEntry(IN PFN_NUMBER Pfn)
FORCEINLINE VOID MmLockAddressSpace(PMMSUPPORT AddressSpace)
VOID NTAPI MmSetPageProtect(struct _EPROCESS *Process, PVOID Address, ULONG flProtect)
VOID NTAPI MiUnmapPageInHyperSpace(IN PEPROCESS Process, IN PVOID Address, IN KIRQL OldIrql)
VOID NTAPI MmGetPageFileMapping(PEPROCESS Process, PVOID Address, SWAPENTRY *SwapEntry)
#define MmLockSectionSegment(x)
VOID NTAPI MmReferencePage(PFN_NUMBER Page)
PVOID NTAPI MiMapPageInHyperSpace(IN PEPROCESS Process, IN PFN_NUMBER Page, IN PKIRQL OldIrql)
#define MmSetPageEntrySectionSegment(S, O, E)
#define MmUnlockSectionSegment(x)
BOOLEAN NTAPI MmIsPageSwapEntry(struct _EPROCESS *Process, PVOID Address)
_In_ PVOID _Out_opt_ BOOLEAN _Out_opt_ PPFN_NUMBER Page
PMEMORY_AREA NTAPI MmLocateMemoryAreaByAddress(PMMSUPPORT AddressSpace, PVOID Address)
#define MA_GetEndingAddress(_MemoryArea)
PFN_NUMBER NTAPI MmGetPfnForProcess(struct _EPROCESS *Process, PVOID Address)
#define MA_GetStartingAddress(_MemoryArea)
FORCEINLINE VOID MmUnlockAddressSpace(PMMSUPPORT AddressSpace)
FORCEINLINE PEPROCESS MmGetAddressSpaceOwner(IN PMMSUPPORT AddressSpace)
BOOLEAN NTAPI MmIsPagePresent(struct _EPROCESS *Process, PVOID Address)
VOID NTAPI MmSetSavedSwapEntryPage(PFN_NUMBER Page, SWAPENTRY SavedSwapEntry)
NTSTATUS NTAPI MmCreateVirtualMapping(struct _EPROCESS *Process, PVOID Address, ULONG flProtect, PFN_NUMBER Page)
NTSTATUS NTAPI MmCreatePageFileMapping(struct _EPROCESS *Process, PVOID Address, SWAPENTRY SwapEntry)
VOID NTAPI MmDeleteRmap(PFN_NUMBER Page, struct _EPROCESS *Process, PVOID Address)
#define MM_ROUND_DOWN(x, s)
#define MM_IS_WAIT_PTE(E)
#define IS_SWAP_FROM_SSE(E)
NTSTATUS NTAPI MmReleasePageMemoryConsumer(ULONG Consumer, PFN_NUMBER Page)
FORCEINLINE PMMSUPPORT MmGetKernelAddressSpace(VOID)
VOID NTAPI MmInsertRmap(PFN_NUMBER Page, struct _EPROCESS *Process, PVOID Address)
#define STATUS_MM_RESTART_OPERATION
#define STATUS_ACCESS_VIOLATION
struct _WORK_QUEUE_WITH_CONTEXT * PWORK_QUEUE_WITH_CONTEXT
struct _WORK_QUEUE_WITH_CONTEXT WORK_QUEUE_WITH_CONTEXT
#define STATUS_MORE_PROCESSING_REQUIRED
base of all file and directory entries
struct _MEMORY_AREA::@1796 SectionData
#define RtlZeroMemory(Destination, Length)
#define STATUS_INVALID_PARAMETER
#define STATUS_UNSUCCESSFUL
_Must_inspect_result_ _In_ WDFDMAENABLER _In_ _In_opt_ PWDF_OBJECT_ATTRIBUTES Attributes
_In_ WDFDPC _In_ BOOLEAN Wait
_Must_inspect_result_ _In_ PWDF_WORKITEM_CONFIG _In_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFWORKITEM * WorkItem
VOID NTAPI ExQueueWorkItem(IN PWORK_QUEUE_ITEM WorkItem, IN WORK_QUEUE_TYPE QueueType)
#define ExInitializeWorkItem(Item, Routine, Context)
WORKER_THREAD_ROUTINE * PWORKER_THREAD_ROUTINE
_In_ ULONG _In_ PHYSICAL_ADDRESS _Inout_ PULONG AddressSpace
_Requires_lock_held_ Interrupt _Releases_lock_ Interrupt _In_ _IRQL_restores_ KIRQL OldIrql
#define PsGetCurrentProcess
_Inout_opt_ PVOID Parameter