Author: tkreuzer
Date: Tue Oct 20 00:49:04 2009
New Revision: 43632
URL:
http://svn.reactos.org/svn/reactos?rev=43632&view=rev
Log:
[NTOSKRNKL]
- add Ke386SetGs, Ke386SetSs macros for amd64
- fix IMAGE_FILE_MACHINE_ARCHITECTURE for amd64, fixes WinDbg kernel version detection
- goto KiSystemStartupReal from KiSystemStartup directly, old boot method is now
deprecated
Modified:
branches/ros-amd64-bringup/reactos/ntoskrnl/include/internal/amd64/intrin_i.h
branches/ros-amd64-bringup/reactos/ntoskrnl/include/internal/amd64/ke.h
branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/kiinit.c
Modified: branches/ros-amd64-bringup/reactos/ntoskrnl/include/internal/amd64/intrin_i.h
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ntosk…
==============================================================================
--- branches/ros-amd64-bringup/reactos/ntoskrnl/include/internal/amd64/intrin_i.h
[iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/ntoskrnl/include/internal/amd64/intrin_i.h
[iso-8859-1] Tue Oct 20 00:49:04 2009
@@ -132,8 +132,10 @@
#define Ke386GetSs() _Ke386GetSeg(ss)
#define Ke386GetFs() _Ke386GetSeg(fs)
#define Ke386SetFs(X) _Ke386SetSeg(fs, X)
+#define Ke386SetGs(X) _Ke386SetSeg(gs, X)
#define Ke386SetDs(X) _Ke386SetSeg(ds, X)
#define Ke386SetEs(X) _Ke386SetSeg(es, X)
+#define Ke386SetSs(X) _Ke386SetSeg(ss, X)
#elif defined(_MSC_VER)
Modified: branches/ros-amd64-bringup/reactos/ntoskrnl/include/internal/amd64/ke.h
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ntosk…
==============================================================================
--- branches/ros-amd64-bringup/reactos/ntoskrnl/include/internal/amd64/ke.h [iso-8859-1]
(original)
+++ branches/ros-amd64-bringup/reactos/ntoskrnl/include/internal/amd64/ke.h [iso-8859-1]
Tue Oct 20 00:49:04 2009
@@ -67,7 +67,7 @@
extern ULONG Ke386CacheAlignment;
-#define IMAGE_FILE_MACHINE_ARCHITECTURE IMAGE_FILE_MACHINE_I386
+#define IMAGE_FILE_MACHINE_ARCHITECTURE IMAGE_FILE_MACHINE_AMD64
//
// INT3 is 1 byte long
Modified: branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/kiinit.c
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ntosk…
==============================================================================
--- branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/kiinit.c [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/ntoskrnl/ke/amd64/kiinit.c [iso-8859-1] Tue Oct 20
00:49:04 2009
@@ -621,7 +621,12 @@
KiSystemStartup(IN ULONG_PTR Dummy,
IN PROS_LOADER_PARAMETER_BLOCK LoaderBlock)
{
- KiRosPrepareForSystemStartup(Dummy, LoaderBlock);
+ FrLdrDbgPrint = ((PLOADER_PARAMETER_BLOCK)Dummy)->u.Amd64.DbgPrint;
+ FrLdrDbgPrint("Hello from KiSystemStartup!!!\n");
+
+ KiSystemStartupReal((PLOADER_PARAMETER_BLOCK)Dummy);
+
+// KiRosPrepareForSystemStartup(Dummy, LoaderBlock);
}
@@ -669,7 +674,7 @@
Ke386SetFs(KGDT_32_R3_TEB | RPL_MASK);
/* LDT is unused */
- __sldt(0);
+// __lldt(0);
/* Align stack to 16 bytes */
LoaderBlock->KernelStack &= ~(16 - 1);
@@ -719,6 +724,8 @@
}
// DPRINT1("Gdt = %p, Idt = %p, Pcr = %p, Tss = %p\n", Gdt, Idt, Pcr, Tss);
+
+ DbgBreakPointWithStatus(0);
/* Initialize the Processor with HAL */
HalInitializeProcessor(Cpu, KeLoaderBlock);