diff options
author | dzwdz | 2023-09-18 16:20:52 +0200 |
---|---|---|
committer | dzwdz | 2023-09-18 16:20:52 +0200 |
commit | 14fd2aecd074fb93bb509df0c1cedd1f1055a4a6 (patch) | |
tree | 10ecb45967748a6b65558074f22c8cdf52ee74ae /src/kernel/proc.h | |
parent | 730a929fffbaaaeb20529962654049fe26dd5dde (diff) |
kernel: implement _sys_time()
After some consideration this seems like the most fitting way to handle
timekeeping. Directly, the syscall is only useful for keeping time within a
single process, but it is meant to be used for e.g. NTP clients, which will
provide the real time through the VFS.
Diffstat (limited to 'src/kernel/proc.h')
-rw-r--r-- | src/kernel/proc.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/kernel/proc.h b/src/kernel/proc.h index bfe5cfc..5d95b52 100644 --- a/src/kernel/proc.h +++ b/src/kernel/proc.h @@ -98,6 +98,9 @@ struct Proc { size_t len; size_t pos; } execbuf; + + /* Time of the first _sys_time() call. 0 if not called yet. */ + uint64_t basetime; }; extern Proc *proc_cur; |