#include <ddk/ntddk.h>
#include "memtest.h"
#include <debug.h>
Go to the source code of this file.
◆ DriverEntry()
Definition at line 100 of file memtest.c.
102{
103 DbgPrint(
"\n===============================================\n Memory Manager Information and Test driver\n");
104 DbgPrint(
"Time;Memory pages allocated;Memory pages free\n");
105
106
108
110}
VOID StartMemoryMonitor()
◆ MonitorThread()
Definition at line 35 of file memtest.c.
36{
40
41
43 {
45
46
48 (
PVOID) &PerformanceInfo,
51 {
52 break;
53 }
54
55
57
58
60 PerformanceInfo.CommittedPages, PerformanceInfo.AvailablePages);
61
62
64 }
65
66 DPRINT(
"Finishing monitoring thread.\n");
67
69}
#define KeQuerySystemTime(t)
#define KeDelayExecutionThread(mode, foo, t)
NTSYSAPI NTSTATUS NTAPI ZwQuerySystemInformation(IN SYSTEM_INFORMATION_CLASS SystemInfoClass, OUT PVOID SystemInfoBuffer, IN ULONG SystemInfoBufferSize, OUT PULONG BytesReturned OPTIONAL)
#define SystemPerformanceInformation
_In_ ULONG _In_ ULONG _In_ ULONG Length
NTSTATUS NTAPI PsTerminateSystemThread(IN NTSTATUS ExitStatus)
Referenced by StartMemoryMonitor().
◆ StartMemoryMonitor()
VOID StartMemoryMonitor |
( |
| ) |
|
Definition at line 73 of file memtest.c.
74{
76
85
87 {
88 DPRINT1(
"Failed to start a monitoring thread\n");
89 return;
90 }
91}
#define NT_SUCCESS(StatCode)
static VOID NTAPI MonitorThread(PVOID Ignored)
HANDLE MonitorThreadHandle
#define THREAD_ALL_ACCESS
NTSTATUS NTAPI PsCreateSystemThread(OUT PHANDLE ThreadHandle, IN ACCESS_MASK DesiredAccess, IN POBJECT_ATTRIBUTES ObjectAttributes, IN HANDLE ProcessHandle, IN PCLIENT_ID ClientId, IN PKSTART_ROUTINE StartRoutine, IN PVOID StartContext)
Referenced by DriverEntry().
◆ MonitorThreadHandle