Remove the code that renices +4 a process that has had 10 minutes of

CPU time. I find it slightly annoying on one of our servers here.

Also disliked by: David Greenman
This commit is contained in:
Gary Palmer 1996-09-22 06:35:24 +00:00
parent 8ea3178507
commit 9986e07e1f

View file

@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_synch.c 8.9 (Berkeley) 5/19/95
* $Id: kern_synch.c,v 1.23 1996/08/28 18:36:30 bde Exp $
* $Id: kern_synch.c,v 1.24 1996/09/01 10:30:33 davidg Exp $
*/
#include "opt_ktrace.h"
@ -550,8 +550,7 @@ mi_switch()
/*
* Check if the process exceeds its cpu resource allocation.
* If over max, kill it. In any case, if it has run for more
* than 10 minutes, reduce priority to give others a chance.
* If over max, kill it.
*/
if (p->p_stat != SZOMB) {
rlim = &p->p_rlimit[RLIMIT_CPU];
@ -564,10 +563,6 @@ mi_switch()
rlim->rlim_cur += 5;
}
}
if (s > 10 * 60 && p->p_ucred->cr_uid && p->p_nice == NZERO) {
p->p_nice = NZERO + 4;
resetpriority(p);
}
}
/*