|
ReactOS 0.4.16-dev-1946-g52006dd
|

Go to the source code of this file.
Macros | |
| #define | NDEBUG |
| #define | MODULE_INVOLVED_IN_ARM3 |
| #define | MI_MAPPED_COPY_PAGES 14 |
| #define | MI_POOL_COPY_BYTES 512 |
| #define | MI_MAX_TRANSFER_SIZE 64 * 1024 |
| FORCEINLINE BOOLEAN MI_IS_LOCKED_VA | ( | PMMPFN | Pfn1, |
| ULONG | LockType | ||
| ) |
Definition at line 3242 of file virtual.c.
Referenced by MiLockVirtualMemory(), and MiUnlockVirtualMemory().
| FORCEINLINE VOID MI_LOCK_VA | ( | PMMPFN | Pfn1, |
| ULONG | LockType | ||
| ) |
Definition at line 3259 of file virtual.c.
Referenced by MiLockVirtualMemory().
| FORCEINLINE VOID MI_UNLOCK_VA | ( | PMMPFN | Pfn1, |
| ULONG | LockType | ||
| ) |
Definition at line 3280 of file virtual.c.
Referenced by MiUnlockVirtualMemory().
| ULONG NTAPI MiCalculatePageCommitment | ( | IN ULONG_PTR | StartingAddress, |
| IN ULONG_PTR | EndingAddress, | ||
| IN PMMVAD | Vad, | ||
| IN PEPROCESS | Process | ||
| ) |
Definition at line 42 of file virtual.c.
Referenced by NtFreeVirtualMemory().
|
static |
FIXME: this might be a memory area for a section view...
Definition at line 3301 of file virtual.c.
Referenced by MiLockVirtualMemory(), and MiUnlockVirtualMemory().
| ULONG NTAPI MiDecommitPages | ( | IN PVOID | StartingAddress, |
| IN PMMPTE | EndingPte, | ||
| IN PEPROCESS | Process, | ||
| IN PMMVAD | Vad | ||
| ) |
Definition at line 2592 of file virtual.c.
Referenced by NtFreeVirtualMemory().
| VOID NTAPI MiDeletePte | ( | IN PMMPTE | PointerPte, |
| IN PVOID | VirtualAddress, | ||
| IN PEPROCESS | CurrentProcess, | ||
| IN PMMPTE | PrototypePte | ||
| ) |
Definition at line 369 of file virtual.c.
Referenced by MiDeletePde(), MiDeleteVirtualAddresses(), MiResolveProtoPteFault(), and MmArmAccessFault().
| PFN_COUNT NTAPI MiDeleteSystemPageableVm | ( | IN PMMPTE | PointerPte, |
| IN PFN_NUMBER | PageCount, | ||
| IN ULONG | Flags, | ||
| OUT PPFN_NUMBER | ValidPages | ||
| ) |
Definition at line 275 of file virtual.c.
Referenced by MiFreeInitializationCode(), MiFreePoolPages(), MmFreeDriverInitialization(), and MmFreeSpecialPool().
| VOID NTAPI MiDeleteVirtualAddresses | ( | _In_ ULONG_PTR | Va, |
| _In_ ULONG_PTR | EndingAddress, | ||
| _In_opt_ PMMVAD | Vad | ||
| ) |
Definition at line 530 of file virtual.c.
Referenced by MiRemoveMappedView(), MmCleanProcessAddressSpace(), MmDeleteTeb(), and NtFreeVirtualMemory().
| NTSTATUS NTAPI MiDoMappedCopy | ( | IN PEPROCESS | SourceProcess, |
| IN PVOID | SourceAddress, | ||
| IN PEPROCESS | TargetProcess, | ||
| OUT PVOID | TargetAddress, | ||
| IN SIZE_T | BufferSize, | ||
| IN KPROCESSOR_MODE | PreviousMode, | ||
| OUT PSIZE_T | ReturnSize | ||
| ) |
Definition at line 795 of file virtual.c.
Referenced by MmCopyVirtualMemory().
| NTSTATUS NTAPI MiDoPoolCopy | ( | IN PEPROCESS | SourceProcess, |
| IN PVOID | SourceAddress, | ||
| IN PEPROCESS | TargetProcess, | ||
| OUT PVOID | TargetAddress, | ||
| IN SIZE_T | BufferSize, | ||
| IN KPROCESSOR_MODE | PreviousMode, | ||
| OUT PSIZE_T | ReturnSize | ||
| ) |
Definition at line 1020 of file virtual.c.
Referenced by MmCopyVirtualMemory().
| VOID NTAPI MiFlushTbAndCapture | ( | IN PMMVAD | FoundVad, |
| IN PMMPTE | PointerPte, | ||
| IN ULONG | ProtectionMask, | ||
| IN PMMPFN | Pfn1, | ||
| IN BOOLEAN | CaptureDirtyBit | ||
| ) |
Definition at line 1821 of file section.c.
Referenced by MiProtectVirtualMemory().
| LONG MiGetExceptionInfo | ( | IN PEXCEPTION_POINTERS | ExceptionInfo, |
| OUT PBOOLEAN | HaveBadAddress, | ||
| OUT PULONG_PTR | BadAddress | ||
| ) |
Definition at line 750 of file virtual.c.
Referenced by MiDoMappedCopy(), and MiDoPoolCopy().
Definition at line 1361 of file virtual.c.
Referenced by MiProtectVirtualMemory(), MiQueryAddressState(), and NtAllocateVirtualMemory().
| BOOLEAN NTAPI MiIsEntireRangeCommitted | ( | IN ULONG_PTR | StartingAddress, |
| IN ULONG_PTR | EndingAddress, | ||
| IN PMMVAD | Vad, | ||
| IN PEPROCESS | Process | ||
| ) |
Definition at line 2004 of file virtual.c.
Referenced by MiProtectVirtualMemory().
|
static |
Definition at line 3346 of file virtual.c.
Referenced by NtLockVirtualMemory(), and RunTest().
| VOID NTAPI MiMakePdeExistAndMakeValid | ( | IN PMMPDE | PointerPde, |
| IN PEPROCESS | TargetProcess, | ||
| IN KIRQL | OldIrql | ||
| ) |
Definition at line 2446 of file virtual.c.
Referenced by _Success_(), MiDecommitPages(), MiMapLockedPagesInUserSpace(), MiProtectVirtualMemory(), MmCreatePageFileMapping(), MmCreateVirtualMappingUnsafeEx(), MmDeletePageFileMapping(), MmGetPageFileMapping(), MmGetPageProtect(), MmGetPfnForProcess(), MmIsDisabledPage(), MmIsPagePresent(), MmIsPageSwapEntry(), MmSetDirtyBit(), MmSetPageProtect(), and NtAllocateVirtualMemory().
| ULONG NTAPI MiMakeSystemAddressValid | ( | IN PVOID | PageTableVirtualAddress, |
| IN PEPROCESS | CurrentProcess | ||
| ) |
Definition at line 183 of file virtual.c.
Referenced by MiCalculatePageCommitment(), MiDeleteVirtualAddresses(), MiIsEntireRangeCommitted(), MiIsPageTablePresent(), MiMakePdeExistAndMakeValid(), and MiQueryAddressState().
Definition at line 235 of file virtual.c.
Referenced by MiGetPageProtection(), and MiSegmentDelete().
Definition at line 2540 of file virtual.c.
Referenced by MiDecommitPages().
| NTSTATUS NTAPI MiProtectVirtualMemory | ( | IN PEPROCESS | Process, |
| IN OUT PVOID * | BaseAddress, | ||
| IN OUT PSIZE_T | NumberOfBytesToProtect, | ||
| IN ULONG | NewAccessProtection, | ||
| OUT PULONG OldAccessProtection | OPTIONAL | ||
| ) |
Definition at line 2160 of file virtual.c.
Referenced by CcPreparePinWrite(), CcpUnpinData(), NtAllocateVirtualMemory(), and NtProtectVirtualMemory().
| ULONG NTAPI MiQueryAddressState | ( | IN PVOID | Va, |
| IN PMMVAD | Vad, | ||
| IN PEPROCESS | TargetProcess, | ||
| OUT PULONG | ReturnedProtect, | ||
| OUT PVOID * | NextVa | ||
| ) |
Definition at line 1476 of file virtual.c.
Referenced by MiQueryMemoryBasicInformation().
| NTSTATUS NTAPI MiQueryMemoryBasicInformation | ( | IN HANDLE | ProcessHandle, |
| IN PVOID | BaseAddress, | ||
| OUT PVOID | MemoryInformation, | ||
| IN SIZE_T | MemoryInformationLength, | ||
| OUT PSIZE_T | ReturnLength | ||
| ) |
Definition at line 1667 of file virtual.c.
Referenced by NtQueryVirtualMemory().
|
static |
Definition at line 3665 of file virtual.c.
Referenced by NtUnlockVirtualMemory().
| NTSTATUS NTAPI MmCopyVirtualMemory | ( | IN PEPROCESS | SourceProcess, |
| IN PVOID | SourceAddress, | ||
| IN PEPROCESS | TargetProcess, | ||
| OUT PVOID | TargetAddress, | ||
| IN SIZE_T | BufferSize, | ||
| IN KPROCESSOR_MODE | PreviousMode, | ||
| OUT PSIZE_T | ReturnSize | ||
| ) |
Definition at line 1271 of file virtual.c.
Referenced by LpcpCopyRequestData(), NtReadVirtualMemory(), and NtWriteVirtualMemory().
| NTSTATUS NTAPI MmFlushVirtualMemory | ( | IN PEPROCESS | Process, |
| IN OUT PVOID * | BaseAddress, | ||
| IN OUT PSIZE_T | RegionSize, | ||
| OUT PIO_STATUS_BLOCK | IoStatusBlock | ||
| ) |
Definition at line 1342 of file virtual.c.
Referenced by NtFlushVirtualMemory().
| PHYSICAL_ADDRESS NTAPI MmGetPhysicalAddress | ( | PVOID | Address | ) |
Definition at line 5676 of file virtual.c.
| PVOID NTAPI MmGetVirtualForPhysical | ( | IN PHYSICAL_ADDRESS | PhysicalAddress | ) |
Definition at line 2759 of file virtual.c.
Referenced by EngSecureMem(), and EngSecureMemForRead().
Definition at line 2772 of file virtual.c.
Referenced by EngUnsecureMem().
| NTSTATUS NTAPI NtAllocateVirtualMemory | ( | IN HANDLE | ProcessHandle, |
| IN OUT PVOID * | UBaseAddress, | ||
| IN ULONG_PTR | ZeroBits, | ||
| IN OUT PSIZE_T | URegionSize, | ||
| IN ULONG | AllocationType, | ||
| IN ULONG | Protect | ||
| ) |
Definition at line 4457 of file virtual.c.
Referenced by Allocate(), AllocateGuarded(), AllocateReadOnly(), BaseCreateStack(), BaseCreateVDMEnvironment(), BasePushProcessParameters(), CheckAdjacentVADs(), CheckAlignment(), CheckSize(), CheckSomeDefaultAddresses(), CopyLoop(), CreateProcessInternalW(), DiscardVirtualMemory(), LsapAllocateClientBuffer(), LsapEnumLogonSessions(), LsapGetLogonSessionData(), MakeReadOnly(), MemInitialize(), PsaiMalloc(), RtlCreateEnvironment(), RtlCreateQueryDebugBuffer(), RtlpDebugBufferCommit(), RtlSetEnvironmentVariable(), START_TEST(), Test_ImageSection(), Test_ImageSection2(), Test_NtFreeVirtualMemory(), Test_PageFileSection(), TestFreeNoAccess(), TestReadWrite(), TH32CreateSnapshot(), VDDAllocMem(), VDDDeInstallMemoryHook(), VirtualAllocEx(), and VirtualAllocFromApp().
| NTSTATUS NTAPI NtFlushInstructionCache | ( | _In_ HANDLE | ProcessHandle, |
| _In_opt_ PVOID | BaseAddress, | ||
| _In_ SIZE_T | FlushSize | ||
| ) |
Definition at line 3009 of file virtual.c.
Referenced by FixupDll(), FlushInstructionCache(), and WriteProcessMemory().
| NTSTATUS NTAPI NtFlushVirtualMemory | ( | IN HANDLE | ProcessHandle, |
| IN OUT PVOID * | BaseAddress, | ||
| IN OUT PSIZE_T | NumberOfBytesToFlush, | ||
| OUT PIO_STATUS_BLOCK | IoStatusBlock | ||
| ) |
Definition at line 4000 of file virtual.c.
Referenced by FlushViewOfFile(), and Test_ImageSection().
| NTSTATUS NTAPI NtFreeVirtualMemory | ( | IN HANDLE | ProcessHandle, |
| IN PVOID * | UBaseAddress, | ||
| IN PSIZE_T | URegionSize, | ||
| IN ULONG | FreeType | ||
| ) |
Definition at line 5192 of file virtual.c.
Referenced by Allocate(), AllocateGuarded(), BaseCreateStack(), BaseCreateVDMEnvironment(), BaseDestroyVDMEnvironment(), BaseFreeThreadStack(), CheckAdjacentVADs(), CheckAlignment(), CheckSize(), CheckSomeDefaultAddresses(), CopyLoop(), CreateProcessInternalW(), DeleteFiber(), Free(), FreeGuarded(), FreeReadOnly(), LsapFreeClientBuffer(), MakeReadOnly(), MemCleanup(), PsaiFree(), RtlDestroyEnvironment(), RtlDestroyHandleTable(), RtlDestroyQueryDebugBuffer(), RtlFreeUserThreadStack(), RtlSetEnvironmentVariable(), START_TEST(), Test_NtFreeVirtualMemory(), Test_NtFreeVirtualMemory_Parameters(), Test_PageFileSection(), TestFreeNoAccess(), TestReadWrite(), TH32CreateSnapshot(), TH32FreeAllocatedResources(), VDDFreeMem(), VDDInstallMemoryHook(), and VirtualFreeEx().
| NTSTATUS NTAPI NtGetWriteWatch | ( | IN HANDLE | ProcessHandle, |
| IN ULONG | Flags, | ||
| IN PVOID | BaseAddress, | ||
| IN SIZE_T | RegionSize, | ||
| IN PVOID * | UserAddressArray, | ||
| OUT PULONG_PTR | EntriesInUserAddressArray, | ||
| OUT PULONG | Granularity | ||
| ) |
Definition at line 4122 of file virtual.c.
Referenced by GetWriteWatch().
| NTSTATUS NTAPI NtLockVirtualMemory | ( | IN HANDLE | ProcessHandle, |
| IN OUT PVOID * | BaseAddress, | ||
| IN OUT PSIZE_T | NumberOfBytesToLock, | ||
| IN ULONG | MapType | ||
| ) |
Definition at line 3494 of file virtual.c.
Referenced by VirtualLock().
| NTSTATUS NTAPI NtProtectVirtualMemory | ( | IN HANDLE | ProcessHandle, |
| IN OUT PVOID * | UnsafeBaseAddress, | ||
| IN OUT SIZE_T * | UnsafeNumberOfBytesToProtect, | ||
| IN ULONG | NewAccessProtection, | ||
| OUT PULONG | UnsafeOldAccessProtection | ||
| ) |
Definition at line 3076 of file virtual.c.
Referenced by AVrfpSnapDllImports(), BaseCreateStack(), BasepCheckForReadOnlyResource(), LdrpSnapIAT(), SeiPatchNewImport(), Test_PageFileSection(), TestFreeNoAccess(), TestReadWrite(), VirtualProtectEx(), Write(), and WriteProcessMemory().
| NTSTATUS NTAPI NtQueryVirtualMemory | ( | IN HANDLE | ProcessHandle, |
| IN PVOID | BaseAddress, | ||
| IN MEMORY_INFORMATION_CLASS | MemoryInformationClass, | ||
| OUT PVOID | MemoryInformation, | ||
| IN SIZE_T | MemoryInformationLength, | ||
| OUT PSIZE_T | ReturnLength | ||
| ) |
Definition at line 4374 of file virtual.c.
Referenced by BasepCheckForReadOnlyResource(), CheckAdjacentVADs(), GetMappedFileNameW(), infinite_recursive(), InitFunctionPtrs(), LdrpInit(), QueryVirtualMemoryInformation(), QueryWorkingSet(), QueryWorkingSetEx(), RtlCreateEnvironment(), RtlSetEnvironmentVariable(), START_TEST(), and VirtualQueryEx().
| NTSTATUS NTAPI NtReadVirtualMemory | ( | IN HANDLE | ProcessHandle, |
| IN PVOID | BaseAddress, | ||
| OUT PVOID | Buffer, | ||
| IN SIZE_T | NumberOfBytesToRead, | ||
| OUT PSIZE_T NumberOfBytesRead | OPTIONAL | ||
| ) |
Definition at line 2781 of file virtual.c.
Referenced by CON_API(), ConSrvConnect(), CreateProcessInternalW(), FixupDll(), InitFunctionPtrs(), LsapCallAuthenticationPackage(), LsapCopyFromClientBuffer(), LsapCopyLocalGroups(), LsapLogonUser(), PsaEnumerateProcessModules(), ReadProcessMemory(), RtlFreeUserThreadStack(), RtlpQueryRemoteProcessModules(), RtlReadOutOfProcessMemoryStream(), UserpCaptureStringParameters(), and UserpGetClientFileName().
| NTSTATUS NTAPI NtResetWriteWatch | ( | IN HANDLE | ProcessHandle, |
| IN PVOID | BaseAddress, | ||
| IN SIZE_T | RegionSize | ||
| ) |
Definition at line 4293 of file virtual.c.
Referenced by ResetWriteWatch().
| NTSTATUS NTAPI NtUnlockVirtualMemory | ( | IN HANDLE | ProcessHandle, |
| IN OUT PVOID * | BaseAddress, | ||
| IN OUT PSIZE_T | NumberOfBytesToUnlock, | ||
| IN ULONG | MapType | ||
| ) |
Definition at line 3830 of file virtual.c.
Referenced by VirtualUnlock().
| NTSTATUS NTAPI NtWriteVirtualMemory | ( | IN HANDLE | ProcessHandle, |
| IN PVOID | BaseAddress, | ||
| IN PVOID | Buffer, | ||
| IN SIZE_T | NumberOfBytesToWrite, | ||
| OUT PSIZE_T NumberOfBytesWritten | OPTIONAL | ||
| ) |
Definition at line 2895 of file virtual.c.
Referenced by BasePushProcessParameters(), LsapCopyToClientBuffer(), LsapEnumLogonSessions(), LsapGetLogonSessionData(), StuffStdHandle(), Write(), and WriteProcessMemory().