Author: dgorbachev
Date: Sun Aug 2 23:27:26 2009
New Revision: 42352
URL:
http://svn.reactos.org/svn/reactos?rev=42352&view=rev
Log:
Remove r42305 hack, preserve racial purity of KiSystemStartupReal.
Modified:
trunk/reactos/ntoskrnl/ke/i386/kiinit.c
Modified: trunk/reactos/ntoskrnl/ke/i386/kiinit.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ke/i386/kiinit.c?…
==============================================================================
--- trunk/reactos/ntoskrnl/ke/i386/kiinit.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/ke/i386/kiinit.c [iso-8859-1] Sun Aug 2 23:27:26 2009
@@ -712,34 +712,18 @@
Ke386SetDs(KGDT_R3_DATA | RPL_MASK);
Ke386SetEs(KGDT_R3_DATA | RPL_MASK);
- /* HACK compensates for KiRosPrepareForSystemStartup hack */
- if ((ULONG)Idt == KiIdtDescriptor.Base)
- {
- USHORT FlippedSelector;
-
- FlippedSelector = KiIdt[2].Selector;
- KiIdt[2].Selector = KiIdt[2].ExtendedOffset;
- KiIdt[2].ExtendedOffset = FlippedSelector;
-
- FlippedSelector = KiIdt[8].Selector;
- KiIdt[8].Selector = KiIdt[8].ExtendedOffset;
- KiIdt[8].ExtendedOffset = FlippedSelector;
- }
- else
- {
- /* Save NMI and double fault traps */
- RtlCopyMemory(&NmiEntry, &Idt[2], sizeof(KIDTENTRY));
- RtlCopyMemory(&DoubleFaultEntry, &Idt[8], sizeof(KIDTENTRY));
-
- /* Copy kernel's trap handlers */
- RtlCopyMemory(Idt,
- (PVOID)KiIdtDescriptor.Base,
- KiIdtDescriptor.Limit + 1);
-
- /* Restore NMI and double fault */
- RtlCopyMemory(&Idt[2], &NmiEntry, sizeof(KIDTENTRY));
- RtlCopyMemory(&Idt[8], &DoubleFaultEntry, sizeof(KIDTENTRY));
- }
+ /* Save NMI and double fault traps */
+ RtlCopyMemory(&NmiEntry, &Idt[2], sizeof(KIDTENTRY));
+ RtlCopyMemory(&DoubleFaultEntry, &Idt[8], sizeof(KIDTENTRY));
+
+ /* Copy kernel's trap handlers */
+ RtlCopyMemory(Idt,
+ (PVOID)KiIdtDescriptor.Base,
+ KiIdtDescriptor.Limit + 1);
+
+ /* Restore NMI and double fault */
+ RtlCopyMemory(&Idt[2], &NmiEntry, sizeof(KIDTENTRY));
+ RtlCopyMemory(&Idt[8], &DoubleFaultEntry, sizeof(KIDTENTRY));
AppCpuInit:
/* Loop until we can release the freeze lock */