svn commit: r308661 - in head/sys: conf kern
Adrian Chadd
adrian at FreeBSD.org
Tue Nov 15 01:34:39 UTC 2016
Author: adrian
Date: Tue Nov 15 01:34:38 2016
New Revision: 308661
URL: https://svnweb.freebsd.org/changeset/base/308661
Log:
[mips] make UMTX_CHAINS configurable at compile time.
The default (512) wastes quite a bit of space which doesn't really buy
us much on highly embedded systems which don't take a lot of locks in
parallel.
This makes it at least build time configurable so people can experiment.
Modified:
head/sys/conf/options
head/sys/kern/kern_umtx.c
Modified: head/sys/conf/options
==============================================================================
--- head/sys/conf/options Tue Nov 15 01:20:36 2016 (r308660)
+++ head/sys/conf/options Tue Nov 15 01:34:38 2016 (r308661)
@@ -220,6 +220,7 @@ SYSVSHM opt_sysvipc.h
SW_WATCHDOG opt_watchdog.h
TURNSTILE_PROFILING
UMTX_PROFILING
+UMTX_CHAINS opt_global.h
VERBOSE_SYSINIT
# POSIX kernel options
@@ -996,3 +997,4 @@ GPIO_SPI_DEBUG opt_gpio.h
EVDEV_SUPPORT opt_evdev.h
EVDEV_DEBUG opt_evdev.h
UINPUT_DEBUG opt_evdev.h
+
Modified: head/sys/kern/kern_umtx.c
==============================================================================
--- head/sys/kern/kern_umtx.c Tue Nov 15 01:20:36 2016 (r308660)
+++ head/sys/kern/kern_umtx.c Tue Nov 15 01:34:38 2016 (r308661)
@@ -198,7 +198,9 @@ struct umtxq_chain {
PRI_MAX_TIMESHARE : (td)->td_user_pri)
#define GOLDEN_RATIO_PRIME 2654404609U
+#ifndef UMTX_CHAINS
#define UMTX_CHAINS 512
+#endif
#define UMTX_SHIFTS (__WORD_BIT - 9)
#define GET_SHARE(flags) \
More information about the svn-src-head
mailing list