diff --git a/sys/kern/kern_resource.c b/sys/kern/kern_resource.c index 535756c8e72b..7eb948002f30 100644 --- a/sys/kern/kern_resource.c +++ b/sys/kern/kern_resource.c @@ -568,8 +568,7 @@ dosetrlimit(td, which, limp) if (limp->rlim_cur > RLIM_INFINITY / (rlim_t)1000000) p->p_limit->p_cpulimit = RLIM_INFINITY; else - p->p_limit->p_cpulimit = - (rlim_t)1000000 * limp->rlim_cur; + p->p_limit->p_cpulimit = limp->rlim_cur; break; case RLIMIT_DATA: if (limp->rlim_cur > maxdsiz) diff --git a/sys/sys/resourcevar.h b/sys/sys/resourcevar.h index e9dff022d9bb..845924668423 100644 --- a/sys/sys/resourcevar.h +++ b/sys/sys/resourcevar.h @@ -82,7 +82,7 @@ struct plimit { #define PL_SHAREMOD 0x01 /* modifications are shared */ int p_lflags; int p_refcnt; /* number of references */ - rlim_t p_cpulimit; /* current cpu limit in usec */ + rlim_t p_cpulimit; /* current cpu limit in sec */ }; #ifdef _KERNEL