From nobody@FreeBSD.org  Mon Apr  4 19:57:58 2005
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 833D516A4CE
	for <freebsd-gnats-submit@FreeBSD.org>; Mon,  4 Apr 2005 19:57:58 +0000 (GMT)
Received: from www.freebsd.org (www.freebsd.org [216.136.204.117])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 667C043D46
	for <freebsd-gnats-submit@FreeBSD.org>; Mon,  4 Apr 2005 19:57:58 +0000 (GMT)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.13.1/8.13.1) with ESMTP id j34Jvw5l023836
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 4 Apr 2005 19:57:58 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.13.1/8.13.1/Submit) id j34JvwVH023835;
	Mon, 4 Apr 2005 19:57:58 GMT
	(envelope-from nobody)
Message-Id: <200504041957.j34JvwVH023835@www.freebsd.org>
Date: Mon, 4 Apr 2005 19:57:58 GMT
From: regis <regisr@pobox.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: sysutils/wmcpuload feature
X-Send-Pr-Version: www-2.3

>Number:         79540
>Category:       ports
>Synopsis:       sysutils/wmcpuload feature
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pat
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Mon Apr 04 20:00:14 GMT 2005
>Closed-Date:    Wed Nov 30 12:47:18 GMT 2005
>Last-Modified:  Wed Nov 30 12:47:18 GMT 2005
>Originator:     regis
>Release:        FreeBSD 5.4-PRERELEASE
>Organization:
>Environment:
FreeBSD crocoite.home.regix.com 5.4-PRERELEASE FreeBSD 5.4-PRERELEASE #5: Sun Apr  3 20:03:29 CEST 2005     regisr@crocoite.home.regix.com:/usr/obj/usr/src/sys/CROCOITE  i386

>Description:
      Option --ignore-nice
It should be interesting that "nice" is available cpu ressource.
When running backgroup process the cpu time is really available for more important jobs. (for sample if you run seti@home or other distribued computing this can be interrupted at any time).  
>How-To-Repeat:
      run a nice program and the cpu load is 100%
>Fix:
      
*** src/cpu_freebsd.c.orig      Mon Apr  4 21:46:18 2005
--- src/cpu_freebsd.c   Mon Apr  4 21:47:01 2005
***************
*** 73,81 ****
        return 0;
  
      used = cpu_time[CP_USER] + cpu_time[CP_SYS];
      if (!opts->ignore_nice)
        used += cpu_time[CP_NICE];
-     total = used + cpu_time[CP_IDLE];
  
      if (pre_total == 0) {
        result = 0;
--- 73,81 ----
        return 0;
  
      used = cpu_time[CP_USER] + cpu_time[CP_SYS];
+     total = used + cpu_time[CP_IDLE] + cpu_time[CP_NICE];
      if (!opts->ignore_nice)
        used += cpu_time[CP_NICE];
  
      if (pre_total == 0) {
        result = 0;

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->pat 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Tue Apr 5 22:21:04 GMT 2005 
Responsible-Changed-Why:  
Over to maintainer. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=79540 
State-Changed-From-To: open->closed 
State-Changed-By: flz 
State-Changed-When: Wed Nov 30 12:47:16 GMT 2005 
State-Changed-Why:  
Committed. Thanks! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=79540 
>Unformatted:
