[PATCH 3/7] virt: steal_governor: remove the minimum elapsed-time check
From: Yury Norov
Date: Fri Nov 13 2026 - 15:03:35 EST
The governor queues its worker with a sampling interval of at least
100ms, so its one-millisecond elapsed-time check is redundant. The
existing denominator clamp already prevents division by zero when
calculating the steal ratio.
This series adds a hook on hotplug events. It may trigger this error
path pointlessly. Just drop it.
Signed-off-by: Yury Norov <ynorov@xxxxxxxxxx>
---
drivers/virt/steal_governor.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/drivers/virt/steal_governor.c b/drivers/virt/steal_governor.c
index 99bebd3dee8c..26b6bcca27ed 100644
--- a/drivers/virt/steal_governor.c
+++ b/drivers/virt/steal_governor.c
@@ -216,11 +216,6 @@ static void steal_governor_loop(struct work_struct *work)
now = ktime_get();
delta_ns = ktime_to_ns(ktime_sub(now, sg_ctx.time));
- if (unlikely(delta_ns < NSEC_PER_MSEC)) {
- pr_err_ratelimited("work scheduled too soon delta_ns: %llu\n", delta_ns);
- goto requeue_work;
- }
-
curr_steal = get_system_steal_time();
delta_steal = curr_steal > sg_ctx.steal ? curr_steal - sg_ctx.steal : 0;
sg_ctx.steal = curr_steal;
@@ -249,7 +244,6 @@ static void steal_governor_loop(struct work_struct *work)
return;
}
-requeue_work:
schedule_delayed_work(&sg_ctx.work, sg_ctx.delay);
}
--
2.53.0