- Fix KiDispatchException to unmask KI_EXCEPTION_INTERNAL when setting the exception...
[reactos.git] / reactos / ntoskrnl / include / ntoskrnl.h
old mode 100755 (executable)
new mode 100644 (file)
index ef8e5ee..ba53306
@@ -1,86 +1,95 @@
-#ifndef __INCLUDE_NTOSKRNL_H
-#define __INCLUDE_NTOSKRNL_H
+/*
+ * COPYRIGHT:       See COPYING in the top level directory
+ * PROJECT:         ReactOS Kernel
+ * FILE:            ntoskrnl/include/ntoskrnl.h
+ * PURPOSE:         Main Kernel Header
+ * PROGRAMMER:      Alex Ionescu (alex@relsoft.net)
+ */
 
-#define __NO_CTYPE_INLINES
+/* INCLUDES ******************************************************************/
 
-/* include the ntoskrnl config.h file */
-#include "config.h"
+/* Version Data */
+#include <ntverp.h>
+#define _WIN32_WINNT _WIN32_WINNT_WS03
+#define NTDDI_VERSION NTDDI_WS03SP1
+#define NTKERNELAPI
+#define NOEXTAPI
 
-#include <roscfg.h>
-#include <reactos/version.h>
-#include <reactos/resource.h>
-#include <reactos/bugcodes.h>
-#include <limits.h>
-#include <stdarg.h>
-#include <stdlib.h>
-#include <string.h>
+/* DDK/IFS/NDK Headers */
+#define NTKERNELAPI
+#define NOEXTAPI
+#include <ntifs.h>
+#undef _KPROCESS
+#undef _EPROCESS
+#include <wdmguid.h>
+#include <arc/arc.h>
+#include <ntndk.h>
+#undef TEXT
+#define TEXT(s) L##s
+#include <regstr.h>
+
+/* FIXME: Temporary until CC Ros is gone */
+#include <ccros.h>
+#include <rosldr.h>
+
+/* Disk Dump Driver Header */
+#include <diskdump/diskdump.h>
+
+/* C Headers */
+#include <stdio.h>
+#include <ctype.h>
+#include <malloc.h>
 #include <wchar.h>
-#include <roskrnl.h>
-#include <ntos/minmax.h>
-#include <ntos/synch.h>
-#include <ntos/keyboard.h>
-#include <ntos/ntdef.h>
-#include <ntos/ntpnp.h>
-#include <rosrtl/minmax.h>
-#include <rosrtl/string.h>
-#include <ddk/halfuncs.h>
-#include <ddk/kefuncs.h>
-#include <ddk/pnptypes.h>
-#include <ddk/pnpfuncs.h>
-#include <ntdll/ldr.h>
-#include <internal/ctype.h>
-#include <internal/ntoskrnl.h>
-#include <internal/ke.h>
-#include <internal/i386/segment.h>
-#include <internal/i386/mm.h>
-#include <internal/i386/fpu.h>
-#include <internal/module.h>
-#include <internal/handle.h>
-#include <internal/pool.h>
-#include <internal/ps.h>
-#include <internal/mm.h>
-#include <internal/cc.h>
-#include <internal/io.h>
-#include <internal/po.h>
-#include <internal/ob.h>
-#include <internal/se.h>
-#include <internal/ldr.h>
-#include <internal/kd.h>
-#include <internal/ex.h>
-#include <internal/ob.h>
-#include "internal/xhal.h"
-#include <internal/v86m.h>
-#include <internal/ifs.h>
-#include <internal/port.h>
-#include <internal/nls.h>
-#include <internal/dbg.h>
-#include <internal/trap.h>
-#include <internal/safe.h>
-#include <internal/test.h>
-#include <napi/core.h>
-#include <napi/dbg.h>
-#include <napi/teb.h>
-#include <napi/win32.h>
 
-#include <pseh.h>
+/* SEH support with PSEH */
+#include <pseh/pseh.h>
+
+/* ReactOS Headers */
+#include <reactos/buildno.h>
+#include <reactos/bugcodes.h>
+#define ExRaiseStatus RtlRaiseStatus
+#include <reactos/probe.h>
+#include <reactos/rossym.h>
+
+/* SetupLDR Support */
+#include <arc/setupblk.h>
+
+/* KD Support */
+#include <windbgkd.h>
+#include <wdbgexts.h>
+#include <kddll.h>
 
-#ifdef DBG
-#ifndef PAGED_CODE
-#define PAGED_CODE()                                                           \
-  do {                                                                         \
-    if(KeGetCurrentIrql() > APC_LEVEL) {                                       \
-      DbgPrint("%s:%i: Pagable code called at IRQL > APC_LEVEL (%d)\n",        \
-               __FILE__, __LINE__, KeGetCurrentIrql());                        \
-      KEBUGCHECK(0);                                                           \
-    }                                                                          \
-  } while(0)
-#endif
-#define PAGED_CODE_RTL PAGED_CODE
-#else
-#ifndef PAGED_CODE
-#define PAGED_CODE()
-#endif
-#define PAGED_CODE_RTL()
-#endif
+/* PNP GUIDs */
+#include <umpnpmgr/sysguid.h>
+
+/* Helper Header */
+#include <reactos/helper.h>
+
+/* Internal Headers */
+#include "internal/ntoskrnl.h"
+#include "config.h"
 
-#endif /* INCLUDE_NTOSKRNL_H */
+//
+// Define the internal versions of external and public global data
+//
+#define IoFileObjectType                _IoFileObjectType
+#define PsThreadType                    _PsThreadType
+#define PsProcessType                   _PsProcessType
+#define ExEventObjectType               _ExEventObjectType
+#define ExSemaphoreObjectType           _ExSemaphoreObjectType
+#define KdDebuggerEnabled               _KdDebuggerEnabled
+#define KdDebuggerNotPresent            _KdDebuggerNotPresent
+#define FsRtlLegalAnsiCharacterArray    _FsRtlLegalAnsiCharacterArray
+#undef LEGAL_ANSI_CHARACTER_ARRAY
+#undef NLS_MB_CODE_PAGE_TAG
+#undef NLS_OEM_LEAD_BYTE_INFO
+#define LEGAL_ANSI_CHARACTER_ARRAY      FsRtlLegalAnsiCharacterArray
+#define NLS_MB_CODE_PAGE_TAG            NlsMbOemCodePageTag
+#define NLS_OEM_LEAD_BYTE_INFO          NlsOemLeadByteInfo
+#undef KD_DEBUGGER_ENABLED
+#undef KD_DEBUGGER_NOT_PRESENT
+#define KD_DEBUGGER_ENABLED             KdDebuggerEnabled
+#define KD_DEBUGGER_NOT_PRESENT         KdDebuggerNotPresent
+#define HalDispatchTable                _HalDispatchTable
+#undef HALDISPATCH
+#define HALDISPATCH                     (&HalDispatchTable)