summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_umtx.c
diff options
context:
space:
mode:
authorjb <jb@FreeBSD.org>2006-10-26 21:42:22 +0000
committerjb <jb@FreeBSD.org>2006-10-26 21:42:22 +0000
commitf82c7997354f95e680341bb8e10136ded5fd15eb (patch)
tree2136d90e7e60f4ef25fe147499787d0e6a155b82 /sys/kern/kern_umtx.c
parentb3e38fbc69f126c6cc49a0a6e45096d6c01b7c43 (diff)
downloadFreeBSD-src-f82c7997354f95e680341bb8e10136ded5fd15eb.zip
FreeBSD-src-f82c7997354f95e680341bb8e10136ded5fd15eb.tar.gz
Make KSE a kernel option, turned on by default in all GENERIC
kernel configs except sun4v (which doesn't process signals properly with KSE). Reviewed by: davidxu@
Diffstat (limited to 'sys/kern/kern_umtx.c')
-rw-r--r--sys/kern/kern_umtx.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/sys/kern/kern_umtx.c b/sys/kern/kern_umtx.c
index 83a10e4..d6c8c2d 100644
--- a/sys/kern/kern_umtx.c
+++ b/sys/kern/kern_umtx.c
@@ -166,9 +166,15 @@ struct umtxq_chain {
* if it is using 100%CPU, this is unfair to other processes.
*/
+#ifdef KSE
#define UPRI(td) (((td)->td_ksegrp->kg_user_pri >= PRI_MIN_TIMESHARE &&\
(td)->td_ksegrp->kg_user_pri <= PRI_MAX_TIMESHARE) ?\
PRI_MAX_TIMESHARE : (td)->td_ksegrp->kg_user_pri)
+#else
+#define UPRI(td) (((td)->td_user_pri >= PRI_MIN_TIMESHARE &&\
+ (td)->td_user_pri <= PRI_MAX_TIMESHARE) ?\
+ PRI_MAX_TIMESHARE : (td)->td_user_pri)
+#endif
#define GOLDEN_RATIO_PRIME 2654404609U
#define UMTX_CHAINS 128
OpenPOWER on IntegriCloud