Add kernel argument to turn on/off time sharing

Add "-T 0" to mcreboot.sh if you want to turn off time sharing.  When
it's turned off, McKernel doesn't activate interval timer when the
length of per-CPU run-queue is larger than one.

Change-Id: I2cedc1b30a9cd9a0f4608a32ecec0a0d58c6225e
This commit is contained in:
Masamichi Takagi
2018-10-31 20:57:12 +09:00
committed by Dominique Martinet
parent 7a3f4d7501
commit 38e68f358a
4 changed files with 23 additions and 2 deletions

View File

@@ -49,8 +49,9 @@ safe_kernel_map=""
umask_old=`umask`
idle_halt=""
allow_oversubscribe=""
time_sharing="time_sharing"
while getopts stk:c:m:o:f:r:q:i:d:e:hO OPT
while getopts stk:c:m:o:f:r:q:i:d:e:hOT: OPT
do
case ${OPT} in
f) facility=${OPTARG}
@@ -81,6 +82,14 @@ do
;;
O) allow_oversubscribe="allow_oversubscribe"
;;
T)
case ${OPTARG} in
1) time_sharing="time_sharing"
;;
0) time_sharing=""
;;
esac
;;
\?) exit 1
;;
esac
@@ -449,7 +458,7 @@ if ! ${SBINDIR}/ihkosctl 0 load ${KERNDIR}/mckernel.img; then
fi
# Set kernel arguments
if ! ${SBINDIR}/ihkosctl 0 kargs "hidos $turbo $safe_kernel_map $idle_halt dump_level=${DUMP_LEVEL} $extra_kopts $allow_oversubscribe"; then
if ! ${SBINDIR}/ihkosctl 0 kargs "hidos $turbo $safe_kernel_map $idle_halt dump_level=${DUMP_LEVEL} $extra_kopts $allow_oversubscribe $time_sharing"; then
echo "error: setting kernel arguments" >&2
error_exit "os_created"
fi