ref: e865218b13562bdd181e97dee3b38b7dabef54cd
parent: d6aaacb5be76620455fec5eefb9cf017b1eae37c
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Tue Jul 23 17:03:08 EDT 2024
kernel: remove global balancetime variable -> make function static
--- a/sys/src/9/port/proc.c
+++ b/sys/src/9/port/proc.c
@@ -555,11 +555,10 @@
* since priorities will otherwise only be recalculated when
* the running process blocks.
*/
-ulong balancetime;
-
static void
rebalance(void)
{
+ static ulong lasttime;
int pri, npri;
Schedq *rq;
Proc *p;
@@ -566,9 +565,9 @@
ulong t;
t = m->ticks;
- if(t - balancetime < HZ)
+ if(t - lasttime < HZ)
return;
- balancetime = t;
+ lasttime = t;
assert(!islo());
--
⑨