[ros-diffs] [ion] 24344: - Use __readfsdword instead of de-referencing the Boot PCR, which is not queried for Application CPUs. (And put the Goto back where it was). Thanks to Thomas Weidenmueller for noticing.

ion at svn.reactos.org ion at svn.reactos.org
Sun Oct 1 17:22:42 CEST 2006


Author: ion
Date: Sun Oct  1 19:22:42 2006
New Revision: 24344

URL: http://svn.reactos.org/svn/reactos?rev=24344&view=rev
Log:
- Use __readfsdword instead of de-referencing the Boot PCR, which is not queried for Application CPUs. (And put the Goto back where it was). Thanks to Thomas Weidenmueller for noticing.

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?rev=24344&r1=24343&r2=24344&view=diff
==============================================================================
--- trunk/reactos/ntoskrnl/ke/i386/kiinit.c (original)
+++ trunk/reactos/ntoskrnl/ke/i386/kiinit.c Sun Oct  1 19:22:42 2006
@@ -311,12 +311,11 @@
     /* Initialize the machine type */
     KiInitializeMachineType();
 
+    /* Skip initial setup if this isn't the Boot CPU */
+    if (Cpu) goto AppCpuInit;
+
     /* Get GDT, IDT, PCR and TSS pointers */
     KiGetMachineBootPointers(&Gdt, &Idt, &Pcr, &Tss);
-
-    /* Skip initial setup if this isn't the Boot CPU */
-    if (Cpu)
-        goto AppCpuInit;
 
     /* Setup the TSS descriptors and entries */
     Ki386InitializeTss(Tss, Idt, Gdt);
@@ -361,7 +360,7 @@
     HalInitializeProcessor(Cpu, KeLoaderBlock);
 
     /* Set active processors */
-    KeActiveProcessors |= Pcr->SetMember;
+    KeActiveProcessors |= __readfsdword(KPCR_SET_MEMBER);
     KeNumberProcessors++;
 
     /* Check if this is the boot CPU */




More information about the Ros-diffs mailing list