Author: tkreuzer
Date: Fri Jul 25 19:02:34 2008
New Revision: 34796
URL:
http://svn.reactos.org/svn/reactos?rev=34796&view=rev
Log:
- add a hack to basetsd.h to undefine _X86_ on amd64 builds (gcc defines it)
- include _M_AMD64 for defintitions in ioaccess.h
- remove KeGetCurrentThread from winddk.h (doesn't work that way)
- hack amd64/ketypes.h to make it compile
Modified:
branches/ros-amd64-bringup/reactos/include/ddk/ioaccess.h
branches/ros-amd64-bringup/reactos/include/ddk/winddk.h
branches/ros-amd64-bringup/reactos/include/ndk/amd64/ketypes.h
branches/ros-amd64-bringup/reactos/include/psdk/basetsd.h
Modified: branches/ros-amd64-bringup/reactos/include/ddk/ioaccess.h
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/inclu…
==============================================================================
--- branches/ros-amd64-bringup/reactos/include/ddk/ioaccess.h [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/include/ddk/ioaccess.h [iso-8859-1] Fri Jul 25
19:02:34 2008
@@ -31,7 +31,7 @@
#ifndef NO_PORT_MACROS
-#if defined(_X86_)
+#if defined(_X86_) || defined(_M_AMD64)
#define READ_REGISTER_UCHAR(r) (*(volatile UCHAR *)(r))
#define READ_REGISTER_USHORT(r) (*(volatile USHORT *)(r))
#define READ_REGISTER_ULONG(r) (*(volatile ULONG *)(r))
Modified: branches/ros-amd64-bringup/reactos/include/ddk/winddk.h
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/inclu…
==============================================================================
--- branches/ros-amd64-bringup/reactos/include/ddk/winddk.h [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/include/ddk/winddk.h [iso-8859-1] Fri Jul 25
19:02:34 2008
@@ -5496,15 +5496,19 @@
#elif defined(__x86_64__)
+#define PASSIVE_LEVEL 0
+#define LOW_LEVEL 0
+#define APC_LEVEL 1
+#define DISPATCH_LEVEL 2
+#define CLOCK_LEVEL 13
+#define IPI_LEVEL 14
+#define POWER_LEVEL 14
+#define PROFILE_LEVEL 15
+#define HIGH_LEVEL 15
+
typedef struct _KFLOATING_SAVE {
ULONG Dummy;
} KFLOATING_SAVE, *PKFLOATING_SAVE;
-
-NTKERNELAPI
-PRKTHREAD
-NTAPI
-KeGetCurrentThread(
- VOID);
#elif defined(__PowerPC__)
Modified: branches/ros-amd64-bringup/reactos/include/ndk/amd64/ketypes.h
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/inclu…
==============================================================================
--- branches/ros-amd64-bringup/reactos/include/ndk/amd64/ketypes.h [iso-8859-1]
(original)
+++ branches/ros-amd64-bringup/reactos/include/ndk/amd64/ketypes.h [iso-8859-1] Fri Jul 25
19:02:34 2008
@@ -8,7 +8,7 @@
Abstract:
- i386 Type definitions for the Kernel services.
+ amd64 Type definitions for the Kernel services.
Author:
@@ -16,8 +16,8 @@
--*/
-#ifndef _IAMD64_KETYPES_H
-#define _IAMD64_KETYPES_H
+#ifndef _AMD64_KETYPES_H
+#define _AMD64_KETYPES_H
//
// Dependencies
@@ -26,12 +26,12 @@
//
// KPCR Access for non-IA64 builds
//
-#define K0IPCR ((ULONG_PTR)(KIP0PCRADDRESS))
-#define PCR ((volatile KPCR * const)K0IPCR)
-#if defined(CONFIG_SMP) || defined(NT_BUILD)
-#undef KeGetPcr
-#define KeGetPcr() ((volatile KPCR * const)__readfsdword(0x1C))
-#endif
+//#define K0IPCR ((ULONG_PTR)(KIP0PCRADDRESS))
+//#define PCR ((volatile KPCR * const)K0IPCR)
+//#if defined(CONFIG_SMP) || defined(NT_BUILD)
+//#undef KeGetPcr
+//#define KeGetPcr() ((volatile KPCR * const)__readfsdword(0x1C))
+//#endif
//
// Machine Types
@@ -296,7 +296,8 @@
struct _KPRCB *
KeGetCurrentPrcb(VOID)
{
- return (struct _KPRCB *)(ULONG_PTR)__readgsqword(FIELD_OFFSET(KPCR, Prcb));
+// return (struct _KPRCB *)(ULONG_PTR)__readgsqword(FIELD_OFFSET(KPCR, Prcb));
+ return 0;
}
//
Modified: branches/ros-amd64-bringup/reactos/include/psdk/basetsd.h
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/inclu…
==============================================================================
--- branches/ros-amd64-bringup/reactos/include/psdk/basetsd.h [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/include/psdk/basetsd.h [iso-8859-1] Fri Jul 25
19:02:34 2008
@@ -7,6 +7,11 @@
#ifdef __GNUC__
#ifndef __int64
#define __int64 long long
+#endif
+#if defined(_M_AMD64) || defined(__x86_64__)
+#if defined(_X86_)
+#undef _X86_
+#endif
#endif
#endif