Date: Thu, 11 Nov 2010 08:15:12 +0000 (UTC) From: Edward Tomasz Napierala <trasz@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r215111 - head/sys/kern Message-ID: <201011110815.oAB8FCtQ053881@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: trasz Date: Thu Nov 11 08:15:12 2010 New Revision: 215111 URL: http://svn.freebsd.org/changeset/base/215111 Log: Remove unneeded conditional. Discussed with: kib Modified: head/sys/kern/kern_proc.c Modified: head/sys/kern/kern_proc.c ============================================================================== --- head/sys/kern/kern_proc.c Thu Nov 11 05:40:39 2010 (r215110) +++ head/sys/kern/kern_proc.c Thu Nov 11 08:15:12 2010 (r215111) @@ -778,18 +778,16 @@ fill_kinfo_proc_only(struct proc *p, str rufetch(p, &kp->ki_rusage); kp->ki_runtime = cputick2usec(p->p_rux.rux_runtime); PROC_SUNLOCK(p); - if ((p->p_flag & P_INMEM) && p->p_stats != NULL) { - kp->ki_start = p->p_stats->p_start; - timevaladd(&kp->ki_start, &boottime); - PROC_SLOCK(p); - calcru(p, &kp->ki_rusage.ru_utime, &kp->ki_rusage.ru_stime); - PROC_SUNLOCK(p); - calccru(p, &kp->ki_childutime, &kp->ki_childstime); - - /* Some callers want child-times in a single value */ - kp->ki_childtime = kp->ki_childstime; - timevaladd(&kp->ki_childtime, &kp->ki_childutime); - } + kp->ki_start = p->p_stats->p_start; + timevaladd(&kp->ki_start, &boottime); + PROC_SLOCK(p); + calcru(p, &kp->ki_rusage.ru_utime, &kp->ki_rusage.ru_stime); + PROC_SUNLOCK(p); + calccru(p, &kp->ki_childutime, &kp->ki_childstime); + + /* Some callers want child-times in a single value */ + kp->ki_childtime = kp->ki_childstime; + timevaladd(&kp->ki_childtime, &kp->ki_childutime); tp = NULL; if (p->p_pgrp) { kp->ki_pgid = p->p_pgrp->pg_id;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201011110815.oAB8FCtQ053881>