3 * LICENSE: GPL - See COPYING in the top level directory
4 * FILE: hal/halx86/up/processor.c
5 * PURPOSE: HAL Processor Routines
6 * PROGRAMMERS: Alex Ionescu (alex.ionescu@reactos.org)
9 /* INCLUDES ******************************************************************/
15 LONG HalpActiveProcessors
;
16 KAFFINITY HalpDefaultInterruptAffinity
;
18 /* PRIVATE FUNCTIONS *********************************************************/
24 /* Disable interrupts and halt the CPU */
29 /* FUNCTIONS *****************************************************************/
36 HalInitializeProcessor(IN ULONG ProcessorNumber
,
37 IN PLOADER_PARAMETER_BLOCK LoaderBlock
)
39 /* Set default IDR and stall count */
40 KeGetPcr()->IDR
= 0xFFFFFFFB;
41 KeGetPcr()->StallScaleFactor
= INITIAL_STALL_COUNT
;
43 /* Update the interrupt affinity and processor mask */
44 InterlockedBitTestAndSet(&HalpActiveProcessors
, ProcessorNumber
);
45 InterlockedBitTestAndSet((PLONG
)&HalpDefaultInterruptAffinity
,
48 /* Register routines for KDCOM */
49 HalpRegisterKdSupportFunctions();
57 HalAllProcessorsStarted(VOID
)
68 HalStartNextProcessor(IN PLOADER_PARAMETER_BLOCK LoaderBlock
,
69 IN PKPROCESSOR_STATE ProcessorState
)
80 HalProcessorIdle(VOID
)
82 /* Enable interrupts and halt the processor */
92 HalRequestIpi(KAFFINITY TargetProcessors
)
94 /* Not implemented on UP */