PatchworkOS  da8a090
A non-POSIX operating system.
Loading...
Searching...
No Matches
timer_source_t Struct Reference

Timer source structure. More...

#include <timer.h>

Collaboration diagram for timer_source_t:

Data Fields

const char * name
 
clock_t precision
 
void(* set )(irq_virt_t virt, clock_t uptime, clock_t timeout)
 Should set the one-shot timer to fire after the specified timeout.
 
void(* ack )(cpu_t *cpu)
 
void(* eoi )(cpu_t *cpu)
 

Detailed Description

Timer source structure.

Definition at line 66 of file timer.h.

Field Documentation

◆ name

const char* timer_source_t::name

Definition at line 68 of file timer.h.

◆ precision

clock_t timer_source_t::precision

Definition at line 69 of file timer.h.

◆ set

void(* timer_source_t::set) (irq_virt_t virt, clock_t uptime, clock_t timeout)

Should set the one-shot timer to fire after the specified timeout.

Should panic on failure, as failing to set a timer will almost certainly result in the system hanging.

Parameters
virtThe virtual IRQ to use for the timer interrupt, usually VECTOR_TIMER.
uptimeThe current uptime in nanoseconds.
timeoutThe desired timeout in nanoseconds, if CLOCKS_NEVER, the timer should be disabled.

Definition at line 79 of file timer.h.

◆ ack

void(* timer_source_t::ack) (cpu_t *cpu)

Definition at line 80 of file timer.h.

◆ eoi

void(* timer_source_t::eoi) (cpu_t *cpu)

Definition at line 81 of file timer.h.


The documentation for this struct was generated from the following file: