mirror of
https://github.com/reactos/reactos.git
synced 2025-04-20 12:29:56 +00:00
- Don't use EXPORTED
- Define MM_HIGHEST_VAD_ADDRESS; this seems to be the actual value of the PEB and represents the highest address that a VAD can be on Windows (and the PEB is the highest vad). This define shoudl probably go in mm.h since I believe the checks and code in NtXxxVirtualMemory should use -it- instead of MM_HIGHEST_USER_ADDRESS. svn path=/trunk/; revision=19445
This commit is contained in:
parent
2f4ea4daeb
commit
75ae595a8d
16 changed files with 46 additions and 49 deletions
|
@ -29,9 +29,9 @@ void* _alloca(size_t size);
|
|||
#error Unknown compiler for alloca intrinsic stack allocation "function"
|
||||
#endif
|
||||
|
||||
ULONG EXPORTED CcFastMdlReadWait;
|
||||
ULONG EXPORTED CcFastReadNotPossible;
|
||||
ULONG EXPORTED CcFastReadWait;
|
||||
ULONG CcFastMdlReadWait;
|
||||
ULONG CcFastReadNotPossible;
|
||||
ULONG CcFastReadWait;
|
||||
ULONG CcFastReadNoWait;
|
||||
ULONG CcFastReadResourceMiss;
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
|
||||
/* GLOBALS *******************************************************************/
|
||||
|
||||
POBJECT_TYPE EXPORTED ExEventObjectType = NULL;
|
||||
POBJECT_TYPE ExEventObjectType = NULL;
|
||||
|
||||
static GENERIC_MAPPING ExpEventMapping = {
|
||||
STANDARD_RIGHTS_READ | SYNCHRONIZE | EVENT_QUERY_STATE,
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
#include <ntoskrnl.h>
|
||||
#include <internal/debug.h>
|
||||
|
||||
/* This structure is a *GUESS* -- Alex */
|
||||
/* FIXME: NDK This structure is a *GUESS* -- Alex */
|
||||
typedef struct _EPROFILE {
|
||||
PEPROCESS Process;
|
||||
PVOID ImageBase;
|
||||
|
@ -30,7 +30,7 @@ typedef struct _EPROFILE {
|
|||
|
||||
/* GLOBALS *******************************************************************/
|
||||
|
||||
POBJECT_TYPE EXPORTED ExProfileObjectType = NULL;
|
||||
POBJECT_TYPE ExProfileObjectType = NULL;
|
||||
|
||||
static KMUTEX ExpProfileMutex;
|
||||
|
||||
|
|
|
@ -15,8 +15,8 @@
|
|||
|
||||
/* DATA **********************************************************************/
|
||||
|
||||
POBJECT_TYPE EXPORTED ExWindowStationObjectType = NULL;
|
||||
POBJECT_TYPE EXPORTED ExDesktopObjectType = NULL;
|
||||
POBJECT_TYPE ExWindowStationObjectType = NULL;
|
||||
POBJECT_TYPE ExDesktopObjectType = NULL;
|
||||
|
||||
static GENERIC_MAPPING ExpWindowStationMapping =
|
||||
{
|
||||
|
|
|
@ -15,9 +15,9 @@
|
|||
|
||||
/* DATA **********************************************************************/
|
||||
|
||||
POBJECT_TYPE EXPORTED IoAdapterObjectType = NULL; /* FIXME */
|
||||
POBJECT_TYPE EXPORTED IoDeviceHandlerObjectType = NULL; /* FIXME */
|
||||
ULONG EXPORTED IoDeviceHandlerObjectSize = 0; /* FIXME */
|
||||
POBJECT_TYPE IoAdapterObjectType = NULL; /* FIXME */
|
||||
POBJECT_TYPE IoDeviceHandlerObjectType = NULL; /* FIXME */
|
||||
ULONG IoDeviceHandlerObjectSize = 0; /* FIXME */
|
||||
|
||||
/* FUNCTIONS *****************************************************************/
|
||||
|
||||
|
|
|
@ -64,7 +64,7 @@ typedef enum _DISK_MANAGER
|
|||
EZ_Drive
|
||||
} DISK_MANAGER;
|
||||
|
||||
HAL_DISPATCH EXPORTED HalDispatchTable =
|
||||
HAL_DISPATCH HalDispatchTable =
|
||||
{
|
||||
HAL_DISPATCH_VERSION,
|
||||
(pHalQuerySystemInformation) NULL, // HalQuerySystemInformation
|
||||
|
@ -90,7 +90,7 @@ HAL_DISPATCH EXPORTED HalDispatchTable =
|
|||
(pHalMirrorVerify) NULL //HalMirrorVerify;
|
||||
};
|
||||
|
||||
HAL_PRIVATE_DISPATCH EXPORTED HalPrivateDispatchTable =
|
||||
HAL_PRIVATE_DISPATCH HalPrivateDispatchTable =
|
||||
{
|
||||
HAL_PRIVATE_DISPATCH_VERSION
|
||||
};
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
#include <internal/debug.h>
|
||||
|
||||
/* ke/main.c */
|
||||
extern LOADER_PARAMETER_BLOCK EXPORTED KeLoaderBlock;
|
||||
extern LOADER_PARAMETER_BLOCK KeLoaderBlock;
|
||||
extern ULONG KeTickCount;
|
||||
extern BOOLEAN SetupMode;
|
||||
|
||||
|
@ -73,7 +73,7 @@ static LIST_ENTRY ServiceListHead = {NULL, NULL};
|
|||
static UNICODE_STRING IopHardwareDatabaseKey =
|
||||
RTL_CONSTANT_STRING(L"\\REGISTRY\\MACHINE\\HARDWARE\\DESCRIPTION\\SYSTEM");
|
||||
|
||||
POBJECT_TYPE EXPORTED IoDriverObjectType = NULL;
|
||||
POBJECT_TYPE IoDriverObjectType = NULL;
|
||||
|
||||
/* DECLARATIONS ***************************************************************/
|
||||
|
||||
|
|
|
@ -13,11 +13,11 @@
|
|||
|
||||
/* VARIABLES ***************************************************************/
|
||||
|
||||
BOOLEAN EXPORTED KdDebuggerEnabled = FALSE;
|
||||
BOOLEAN EXPORTED KdEnteredDebugger = FALSE;
|
||||
BOOLEAN EXPORTED KdDebuggerNotPresent = TRUE;
|
||||
BOOLEAN EXPORTED KiEnableTimerWatchdog = FALSE;
|
||||
ULONG EXPORTED KiBugCheckData;
|
||||
BOOLEAN KdDebuggerEnabled = FALSE;
|
||||
BOOLEAN KdEnteredDebugger = FALSE;
|
||||
BOOLEAN KdDebuggerNotPresent = TRUE;
|
||||
BOOLEAN KiEnableTimerWatchdog = FALSE;
|
||||
ULONG KiBugCheckData;
|
||||
BOOLEAN KdpBreakPending;
|
||||
VOID STDCALL PspDumpThreads(BOOLEAN SystemThreads);
|
||||
|
||||
|
|
|
@ -52,14 +52,8 @@ extern LIST_ENTRY KiTimerListHead;
|
|||
*/
|
||||
#define CLOCK_INCREMENT (100000)
|
||||
|
||||
#ifdef __GNUC__
|
||||
ULONG EXPORTED KeMaximumIncrement = 100000;
|
||||
ULONG EXPORTED KeMinimumIncrement = 100000;
|
||||
#else
|
||||
/* Microsoft-style declarations */
|
||||
EXPORTED ULONG KeMaximumIncrement = 100000;
|
||||
EXPORTED ULONG KeMinimumIncrement = 100000;
|
||||
#endif
|
||||
ULONG KeMaximumIncrement = 100000;
|
||||
ULONG KeMinimumIncrement = 100000;
|
||||
|
||||
#define MICROSECONDS_PER_TICK (10000)
|
||||
#define TICKS_TO_CALIBRATE (1)
|
||||
|
|
|
@ -22,15 +22,15 @@
|
|||
ULONG NtMajorVersion = 5;
|
||||
ULONG NtMinorVersion = 0;
|
||||
ULONG NtOSCSDVersion = BUILD_OSCSDVERSION(6, 0);
|
||||
EXPORTED ULONG NtBuildNumber = KERNEL_VERSION_BUILD;
|
||||
EXPORTED ULONG NtGlobalFlag = 0;
|
||||
EXPORTED CHAR KeNumberProcessors;
|
||||
EXPORTED KAFFINITY KeActiveProcessors = 1;
|
||||
EXPORTED LOADER_PARAMETER_BLOCK KeLoaderBlock;
|
||||
EXPORTED ULONG KeDcacheFlushCount = 0;
|
||||
EXPORTED ULONG KeIcacheFlushCount = 0;
|
||||
EXPORTED ULONG KiDmaIoCoherency = 0; /* RISC Architectures only */
|
||||
EXPORTED ULONG InitSafeBootMode = 0; /* KB83764 */
|
||||
ULONG NtBuildNumber = KERNEL_VERSION_BUILD;
|
||||
ULONG NtGlobalFlag = 0;
|
||||
CHAR KeNumberProcessors;
|
||||
KAFFINITY KeActiveProcessors = 1;
|
||||
LOADER_PARAMETER_BLOCK KeLoaderBlock;
|
||||
ULONG KeDcacheFlushCount = 0;
|
||||
ULONG KeIcacheFlushCount = 0;
|
||||
ULONG KiDmaIoCoherency = 0; /* RISC Architectures only */
|
||||
ULONG InitSafeBootMode = 0; /* KB83764 */
|
||||
|
||||
LOADER_MODULE KeLoaderModules[64];
|
||||
static CHAR KeLoaderModuleStrings[64][256];
|
||||
|
|
|
@ -18,10 +18,10 @@
|
|||
extern LDR_DATA_TABLE_ENTRY NtoskrnlModuleObject;
|
||||
extern LDR_DATA_TABLE_ENTRY HalModuleObject;
|
||||
|
||||
ULONG EXPORTED MmUserProbeAddress = 0;
|
||||
PVOID EXPORTED MmHighestUserAddress = NULL;
|
||||
PBOOLEAN EXPORTED Mm64BitPhysicalAddress = FALSE;
|
||||
PVOID EXPORTED MmSystemRangeStart = NULL;
|
||||
ULONG MmUserProbeAddress = 0;
|
||||
PVOID MmHighestUserAddress = NULL;
|
||||
PBOOLEAN Mm64BitPhysicalAddress = FALSE;
|
||||
PVOID MmSystemRangeStart = NULL;
|
||||
|
||||
MM_STATS MmStats;
|
||||
|
||||
|
|
|
@ -18,6 +18,9 @@ extern ULONG NtMinorVersion;
|
|||
extern ULONG NtOSCSDVersion;
|
||||
extern ULONG NtGlobalFlag;
|
||||
|
||||
#define MM_HIGHEST_VAD_ADDRESS \
|
||||
(PVOID)((ULONG_PTR)MM_HIGHEST_USER_ADDRESS - (16 * PAGE_SIZE))
|
||||
|
||||
/* FUNCTIONS *****************************************************************/
|
||||
|
||||
PVOID
|
||||
|
@ -202,8 +205,8 @@ MmCreatePeb(PEPROCESS Process)
|
|||
DPRINT("MmCreatePeb\n");
|
||||
|
||||
/* Allocate the PEB */
|
||||
Peb = MiCreatePebOrTeb(Process, (PVOID)PEB_BASE);
|
||||
if (Peb != (PVOID)PEB_BASE)
|
||||
Peb = MiCreatePebOrTeb(Process, MM_HIGHEST_VAD_ADDRESS);
|
||||
if (Peb != MM_HIGHEST_VAD_ADDRESS)
|
||||
{
|
||||
DPRINT1("MiCreatePebOrTeb() returned %x\n", Peb);
|
||||
return STATUS_UNSUCCESSFUL;
|
||||
|
@ -345,7 +348,7 @@ MmCreateTeb(PEPROCESS Process,
|
|||
}
|
||||
|
||||
/* Allocate the TEB */
|
||||
Teb = MiCreatePebOrTeb(Process, (PVOID)TEB_BASE);
|
||||
Teb = MiCreatePebOrTeb(Process, MM_HIGHEST_VAD_ADDRESS);
|
||||
|
||||
/* Initialize the PEB */
|
||||
RtlZeroMemory(Teb, sizeof(TEB));
|
||||
|
|
|
@ -66,7 +66,7 @@ MM_SECTION_PAGEOUT_CONTEXT;
|
|||
|
||||
/* GLOBALS *******************************************************************/
|
||||
|
||||
POBJECT_TYPE EXPORTED MmSectionObjectType = NULL;
|
||||
POBJECT_TYPE MmSectionObjectType = NULL;
|
||||
|
||||
static GENERIC_MAPPING MmpSectionMapping = {
|
||||
STANDARD_RIGHTS_READ | SECTION_MAP_READ | SECTION_QUERY,
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
|
||||
/* GLOBALS *******************************************************************/
|
||||
|
||||
POBJECT_TYPE EXPORTED PsJobType = NULL;
|
||||
POBJECT_TYPE PsJobType = NULL;
|
||||
|
||||
LIST_ENTRY PsJobListHead;
|
||||
static FAST_MUTEX PsJobListLock;
|
||||
|
|
|
@ -16,9 +16,9 @@
|
|||
|
||||
/* GLOBALS ******************************************************************/
|
||||
|
||||
PEPROCESS EXPORTED PsInitialSystemProcess = NULL;
|
||||
PEPROCESS PsInitialSystemProcess = NULL;
|
||||
PEPROCESS PsIdleProcess = NULL;
|
||||
POBJECT_TYPE EXPORTED PsProcessType = NULL;
|
||||
POBJECT_TYPE PsProcessType = NULL;
|
||||
extern PHANDLE_TABLE PspCidTable;
|
||||
|
||||
EPROCESS_QUOTA_BLOCK PspDefaultQuotaBlock;
|
||||
|
|
|
@ -21,7 +21,7 @@ extern PEPROCESS PsIdleProcess;
|
|||
extern PVOID PspSystemDllEntryPoint;
|
||||
extern PHANDLE_TABLE PspCidTable;
|
||||
|
||||
POBJECT_TYPE EXPORTED PsThreadType = NULL;
|
||||
POBJECT_TYPE PsThreadType = NULL;
|
||||
|
||||
/* FUNCTIONS ***************************************************************/
|
||||
|
||||
|
|
Loading…
Reference in a new issue