2 * FILE: hal/halx86/generic/timer.S
3 * COPYRIGHT: See COPYING in the top level directory
4 * PURPOSE: System Timer Interrupt and Management
5 * PROGRAMMER: Alex Ionescu (alex@relsoft.net)
8 /* INCLUDES ******************************************************************/
10 #include <reactos/asm.h>
11 #include <ndk/amd64/asm.h>
13 /* GLOBALS *******************************************************************/
17 .global MsgUnimplemented
19 .asciz "WARNING: %s at %s:%d is UNIMPLEMENTED!\n"
22 /* FUNCTIONS *****************************************************************/
27 PUBLIC HalpCalibrateStallExecution@0
28 HalpCalibrateStallExecution@0:
31 PUBLIC HalpProfileInterrupt
35 PUBLIC KeStallExecutionProcessor
36 KeStallExecutionProcessor:
38 /* Get the number of microseconds required */
41 /* Multiply by the stall factor */
42 mov eax, gs:[KPCR_STALL_SCALE_FACTOR]
45 /* Align to 16 bytes */
48 /* Jump to subtraction loop */
51 /* Align to 16 bytes */
54 /* Subtract one count */
64 PUBLIC HalpQuery8254Counter
67 /* Save EFLAGS and disable interrupts */
76 /* Read current timer */
83 /* Return it and restore interrupt state */
88 PUBLIC HalpClockInterrupt
90 UNIMPLEMENTED _HalpClockInterrupt