diff options
author | H. Peter Anvin <hpa@zytor.com> | 2009-09-02 17:44:32 -0700 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2009-09-02 17:44:32 -0700 |
commit | 75d4dec2f651c9f25fa95d6b6960db7c4dcfd7a0 (patch) | |
tree | 1fc477d5f43577a31eaaff7c5a17f719c4e69e1d /core/common.inc | |
parent | 94a6e382a7a253fdab67a3bff981844dd5f6d4cb (diff) | |
download | syslinux-75d4dec2f651c9f25fa95d6b6960db7c4dcfd7a0.tar.gz |
core: hook INT 1Ch for a simple monotonic timer
The BIOS_timer variable at 4C6h is somewhat unreliable... it is
documented to wrap at "midnight", norminally after 1627419 ticks
(0x18d51b), which is a rather awkward number to deal with modulo.
Instead, hook the INT 1Ch secondary timer interrupt and just count a
simple incrementing variable.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'core/common.inc')
-rw-r--r-- | core/common.inc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/core/common.inc b/core/common.inc index 80dbb4f9..7078011e 100644 --- a/core/common.inc +++ b/core/common.inc @@ -18,6 +18,7 @@ %include "strcpy.inc" ; strcpy() %include "idle.inc" ; Idle handling %include "adv.inc" ; Auxillary Data Vector +%include "timer.inc" ; Timer handling ; Note: the prefix section is included late, to avoid problems with some ; versions of NASM that had issues with forward references to EQU symbols. |