summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_resource.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2000-02-15 09:02:07 +0000
committerphk <phk@FreeBSD.org>2000-02-15 09:02:07 +0000
commitb12cbb5f48d0d6f9fb396c6a8fa4c884c6507ca9 (patch)
treeee36aa860d583403803b887ecb928eb09d2e7fb3 /sys/kern/kern_resource.c
parent241a2df74b5fc35db9427f0979a3a4a4ba69ac18 (diff)
downloadFreeBSD-src-b12cbb5f48d0d6f9fb396c6a8fa4c884c6507ca9.zip
FreeBSD-src-b12cbb5f48d0d6f9fb396c6a8fa4c884c6507ca9.tar.gz
Don't try to account for the partial quantum unless the process is
curproc. This only makes any difference on SMP, where we used a (potentially very bogus) switchtime from our own CPU to calculate resource usage on another CPU. This should remove some if not all calcru() related warnings on SMP. Approved by: jkh
Diffstat (limited to 'sys/kern/kern_resource.c')
-rw-r--r--sys/kern/kern_resource.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/sys/kern/kern_resource.c b/sys/kern/kern_resource.c
index 0307369..2c6478d 100644
--- a/sys/kern/kern_resource.c
+++ b/sys/kern/kern_resource.c
@@ -509,11 +509,7 @@ calcru(p, up, sp, ip)
}
tu = p->p_runtime;
-#ifdef SMP
- if (p->p_oncpu != 0xff) {
-#else
if (p == curproc) {
-#endif
/*
* Adjust for the current time slice. This is actually fairly
* important since the error here is on the order of a time
OpenPOWER on IntegriCloud