Author: tkreuzer
Date: Wed Aug 20 17:38:23 2008
New Revision: 35492
URL:
http://svn.reactos.org/svn/reactos?rev=35492&view=rev
Log:
revert my last commit to avoid polluting other files with hack code. I am also not going
to need that piece of code for amd64.
Modified:
branches/ros-amd64-bringup/reactos/ntoskrnl/ke/freeldr.c
branches/ros-amd64-bringup/reactos/ntoskrnl/ke/i386/cpu.c
branches/ros-amd64-bringup/reactos/ntoskrnl/ke/powerpc/cpu.c
Modified: branches/ros-amd64-bringup/reactos/ntoskrnl/ke/freeldr.c
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ntosk…
==============================================================================
--- branches/ros-amd64-bringup/reactos/ntoskrnl/ke/freeldr.c [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/ntoskrnl/ke/freeldr.c [iso-8859-1] Wed Aug 20
17:38:23 2008
@@ -1266,15 +1266,42 @@
{
PLOADER_PARAMETER_BLOCK NtLoaderBlock;
ULONG size, i = 0, *ent;
+#if defined(_M_IX86)
+ PKTSS Tss;
+ PKGDTENTRY TssEntry;
+
+ /* Load the GDT and IDT */
+ Ke386SetGlobalDescriptorTable(*(PKDESCRIPTOR)&KiGdtDescriptor.Limit);
+ Ke386SetInterruptDescriptorTable(*(PKDESCRIPTOR)&KiIdtDescriptor.Limit);
+
+ /* Initialize the boot TSS */
+ Tss = &KiBootTss;
+ TssEntry = &KiBootGdt[KGDT_TSS / sizeof(KGDTENTRY)];
+ TssEntry->HighWord.Bits.Type = I386_TSS;
+ TssEntry->HighWord.Bits.Pres = 1;
+ TssEntry->HighWord.Bits.Dpl = 0;
+ TssEntry->BaseLow = (USHORT)((ULONG_PTR)Tss & 0xFFFF);
+ TssEntry->HighWord.Bytes.BaseMid = (UCHAR)((ULONG_PTR)Tss >> 16);
+ TssEntry->HighWord.Bytes.BaseHi = (UCHAR)((ULONG_PTR)Tss >> 24);
+#endif
+
+#if defined(_M_PPC)
+ // Zero bats. We might have residual bats set that will interfere with
+ // our mapping of ofwldr.
+ for (i = 0; i < 4; i++)
+ {
+ SetBat(i, 0, 0, 0); SetBat(i, 1, 0, 0);
+ }
+ KiSetupSyscallHandler();
+ DbgPrint("Kernel Power (%08x)\n", LoaderBlock);
+ DbgPrint("ArchExtra (%08x)!\n", LoaderBlock->ArchExtra);
+#endif
/* Save pointer to ROS Block */
KeRosLoaderBlock = LoaderBlock;
/* Get debugging function */
FrLdrDbgPrint = LoaderBlock->FrLdrDbgPrint;
-
- /* Per architecture initialisazion code */
- KiArchInitSystem();
/* Save memory manager data */
KeMemoryMapRangeCount = 0;
Modified: branches/ros-amd64-bringup/reactos/ntoskrnl/ke/i386/cpu.c
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ntosk…
==============================================================================
--- branches/ros-amd64-bringup/reactos/ntoskrnl/ke/i386/cpu.c [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/ntoskrnl/ke/i386/cpu.c [iso-8859-1] Wed Aug 20
17:38:23 2008
@@ -1036,24 +1036,3 @@
/* Capture the control state */
KiSaveProcessorControlState(State);
}
-
-VOID
-KiArchInitSystem()
-{
- PKTSS Tss;
- PKGDTENTRY TssEntry;
-
- /* Load the GDT and IDT */
- Ke386SetGlobalDescriptorTable(*(PKDESCRIPTOR)&KiGdtDescriptor.Limit);
- Ke386SetInterruptDescriptorTable(*(PKDESCRIPTOR)&KiIdtDescriptor.Limit);
-
- /* Initialize the boot TSS */
- Tss = &KiBootTss;
- TssEntry = &KiBootGdt[KGDT_TSS / sizeof(KGDTENTRY)];
- TssEntry->HighWord.Bits.Type = I386_TSS;
- TssEntry->HighWord.Bits.Pres = 1;
- TssEntry->HighWord.Bits.Dpl = 0;
- TssEntry->BaseLow = (USHORT)((ULONG_PTR)Tss & 0xFFFF);
- TssEntry->HighWord.Bytes.BaseMid = (UCHAR)((ULONG_PTR)Tss >> 16);
- TssEntry->HighWord.Bytes.BaseHi = (UCHAR)((ULONG_PTR)Tss >> 24);
-}
Modified: branches/ros-amd64-bringup/reactos/ntoskrnl/ke/powerpc/cpu.c
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/ntosk…
==============================================================================
--- branches/ros-amd64-bringup/reactos/ntoskrnl/ke/powerpc/cpu.c [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/ntoskrnl/ke/powerpc/cpu.c [iso-8859-1] Wed Aug 20
17:38:23 2008
@@ -275,19 +275,3 @@
/* Capture the control state */
KiSaveProcessorControlState(State);
}
-
-VOID
-KiArchInitSystem()
-{
- ULONG i;
-
- // Zero bats. We might have residual bats set that will interfere with
- // our mapping of ofwldr.
- for (i = 0; i < 4; i++)
- {
- SetBat(i, 0, 0, 0); SetBat(i, 1, 0, 0);
- }
- KiSetupSyscallHandler();
- DbgPrint("Kernel Power (%08x)\n", KeRosLoaderBlock);
- DbgPrint("ArchExtra (%08x)!\n", KeRosLoaderBlock->ArchExtra);
-}