From 97ccc71cfd0b15b8cc7b54405c1231e0e63c7f9c Mon Sep 17 00:00:00 2001 From: Ian Moffett Date: Sun, 26 May 2024 23:35:16 -0400 Subject: kernel/amd64: Support fetching time since startup Signed-off-by: Ian Moffett --- sys/include/sys/timer.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'sys/include') diff --git a/sys/include/sys/timer.h b/sys/include/sys/timer.h index a255bab..e33b2d3 100644 --- a/sys/include/sys/timer.h +++ b/sys/include/sys/timer.h @@ -72,6 +72,8 @@ typedef int tmrr_status_t; struct timer { const char *name; /* e.g "HPET" */ size_t(*calibrate)(void); /* Returns frequency, 0 for unspecified */ + size_t(*get_time_usec)(void); /* Time since init (microseconds) */ + size_t(*get_time_sec)(void); /* Time since init (seconds) */ int(*msleep)(size_t ms); int(*usleep)(size_t us); int(*nsleep)(size_t ns); -- cgit v1.2.3