diff options
| author | Ian Moffett <ian@osmora.org> | 2025-11-18 16:05:25 -0500 |
|---|---|---|
| committer | Ian Moffett <ian@osmora.org> | 2025-11-18 16:05:25 -0500 |
| commit | 0527ef090e4a5ff2dd8dc32170d505c44ee015fa (patch) | |
| tree | e061425468803e33ea9a5e14627f4d51c6ca6f5e /sys/inc/arch/amd64/lapic.h | |
| parent | 32a88e354f6936ae0e2ab9c564293a09c6d77902 (diff) | |
kern/amd64: lapic: Add Local APIC timer interface
This commit adds an interface to perform a oneshot operation with the
Local APIC timer as well as providing a stub interrupt service routine
for it.
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'sys/inc/arch/amd64/lapic.h')
| -rw-r--r-- | sys/inc/arch/amd64/lapic.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/inc/arch/amd64/lapic.h b/sys/inc/arch/amd64/lapic.h index 35ba778..d22a560 100644 --- a/sys/inc/arch/amd64/lapic.h +++ b/sys/inc/arch/amd64/lapic.h @@ -31,6 +31,7 @@ #define _MACHINE_LAPIC_H_ 1 #include <sys/types.h> +#include <lib/stdbool.h> #include <mu/cpu.h> #define LAPIC_TMR_VEC 0x81 @@ -91,6 +92,12 @@ struct lapic_ipi { }; /* + * Put the local APIC timer in one shot mode and fire it + * off + */ +void lapic_oneshot_usec(struct mcb *mcb, size_t usec); + +/* * Read the current local APIC id */ uint32_t lapic_read_id(struct mcb *mcb); |
