diff options
author | cheloha <cheloha@cvs.openbsd.org> | 2018-10-05 18:56:58 +0000 |
---|---|---|
committer | cheloha <cheloha@cvs.openbsd.org> | 2018-10-05 18:56:58 +0000 |
commit | fd76a714b23ea388683735c19b0132e96e39c3db (patch) | |
tree | ac052fcbfab87d84a530f5d602f266b8ddbcea5c /sys | |
parent | 3f27463693ec790748080c9b2f43aef7318e224e (diff) |
Revert KERN_CPTIME2 ENODEV changes in kernel and userspace.
ok kettenis deraadt
Diffstat (limited to 'sys')
-rw-r--r-- | sys/kern/kern_sched.c | 8 | ||||
-rw-r--r-- | sys/kern/kern_sysctl.c | 4 | ||||
-rw-r--r-- | sys/sys/sched.h | 4 |
3 files changed, 3 insertions, 13 deletions
diff --git a/sys/kern/kern_sched.c b/sys/kern/kern_sched.c index 20ae05d0001..e11744184c3 100644 --- a/sys/kern/kern_sched.c +++ b/sys/kern/kern_sched.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_sched.c,v 1.52 2018/09/26 17:23:13 cheloha Exp $ */ +/* $OpenBSD: kern_sched.c,v 1.53 2018/10/05 18:56:57 cheloha Exp $ */ /* * Copyright (c) 2007, 2008 Artur Grabowski <art@openbsd.org> * @@ -832,12 +832,6 @@ sysctl_hwncpuonline(void) return cpuset_cardinality(&sched_all_cpus); } -int -cpu_is_online(struct cpu_info *ci) -{ - return cpuset_isset(&sched_all_cpus, ci); -} - #ifdef __HAVE_CPU_TOPOLOGY #include <sys/sysctl.h> diff --git a/sys/kern/kern_sysctl.c b/sys/kern/kern_sysctl.c index a36b3b3864a..3d6fc62f7e7 100644 --- a/sys/kern/kern_sysctl.c +++ b/sys/kern/kern_sysctl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_sysctl.c,v 1.349 2018/10/04 17:33:40 bluhm Exp $ */ +/* $OpenBSD: kern_sysctl.c,v 1.350 2018/10/05 18:56:57 cheloha Exp $ */ /* $NetBSD: kern_sysctl.c,v 1.17 1996/05/20 17:49:05 mrg Exp $ */ /*- @@ -2382,8 +2382,6 @@ sysctl_cptime2(int *name, u_int namelen, void *oldp, size_t *oldlenp, } if (!found) return (ENOENT); - if (!cpu_is_online(ci)) - return (ENODEV); return (sysctl_rdstruct(oldp, oldlenp, newp, &ci->ci_schedstate.spc_cp_time, diff --git a/sys/sys/sched.h b/sys/sys/sched.h index f8f6d7b7af4..103f1feaad0 100644 --- a/sys/sys/sched.h +++ b/sys/sys/sched.h @@ -1,4 +1,4 @@ -/* $OpenBSD: sched.h,v 1.48 2018/09/26 17:23:13 cheloha Exp $ */ +/* $OpenBSD: sched.h,v 1.49 2018/10/05 18:56:57 cheloha Exp $ */ /* $NetBSD: sched.h,v 1.2 1999/02/28 18:14:58 ross Exp $ */ /*- @@ -155,8 +155,6 @@ int sysctl_hwperfpolicy(void *, size_t *, void *, size_t); int sysctl_hwsmt(void *, size_t *, void *, size_t); int sysctl_hwncpuonline(void); -int cpu_is_online(struct cpu_info *); - #ifdef MULTIPROCESSOR void sched_start_secondary_cpus(void); void sched_stop_secondary_cpus(void); |