refactor(ke): read_time_nano -> read_time

This commit is contained in:
Loïc Grégoire
2026-04-19 08:41:26 -04:00
parent a7e319c922
commit b646115dfc
5 changed files with 13 additions and 13 deletions
+2 -2
View File
@@ -246,7 +246,7 @@ pub fn block() void {
td.lock.acquire_no_ipl();
td.state = .Blocked;
td.sleep_start = ke.time.read_time_nano();
td.sleep_start = ke.time.read_time();
td.runq = null;
yield(ke.cpu.current());
@@ -259,7 +259,7 @@ pub fn block() void {
pub fn unblock(td: *ke.Thread) void {
const ipl = td.lock.acquire();
td.sleep_time = (ke.time.read_time_nano() - td.sleep_start) / std.time.ns_per_ms;
td.sleep_time = (ke.time.read_time() - td.sleep_start) / std.time.ns_per_ms;
if (td.sleep_time >= config.CONFIG_SCHED_TIMESLICE and td.priority_class == .Batch) {
// If we have slept for more than a tick, update interactivity.