File tree Expand file tree Collapse file tree
tools/testing/selftests/rcutorture Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ # SPDX-License-Identifier: GPL-2.0+
3+ #
4+ # Analyze a given results directory for rcutorture progress.
5+ #
6+ # Usage: kvm-recheck-rcu.sh resdir
7+ #
8+ # Copyright (C) Facebook, 2020
9+ #
10+ # Authors: Paul E. McKenney <paulmck@kernel.org>
11+
12+ i=" $1 "
13+ if test -d " $i " -a -r " $i "
14+ then
15+ :
16+ else
17+ echo Unreadable results directory: $i
18+ exit 1
19+ fi
20+ . functions.sh
21+
22+ configfile=` echo $i | sed -e ' s/^.*\///' `
23+ nscfs=" ` grep ' scf_invoked_count ver:' $i /console.log 2> /dev/null | tail -1 | sed -e ' s/^.* scf_invoked_count ver: //' -e ' s/ .*$//' | tr -d ' \015' ` "
24+ if test -z " $nscfs "
25+ then
26+ echo " $configfile ------- "
27+ else
28+ dur=" ` sed -e ' s/^.* scftorture.shutdown_secs=//' -e ' s/ .*$//' < $i /qemu-cmd 2> /dev/null` "
29+ if test -z " $dur "
30+ then
31+ rate=" "
32+ else
33+ nscfss=` awk -v nscfs=$nscfs -v dur=$dur '
34+ BEGIN { print nscfs / dur }' < /dev/null`
35+ rate=" ($nscfss /s)"
36+ fi
37+ echo " ${configfile} ------- ${nscfs} SCF handler invocations$rate "
38+ fi
Original file line number Diff line number Diff line change 184184 shift
185185 ;;
186186 --torture)
187- checkarg --torture " (suite name)" " $# " " $2 " ' ^\(lock\|rcu\|rcuperf\|refscale\)$' ' ^--'
187+ checkarg --torture " (suite name)" " $# " " $2 " ' ^\(lock\|rcu\|rcuperf\|refscale\|scf\ )$' ' ^--'
188188 TORTURE_SUITE=$2
189189 shift
190190 if test " $TORTURE_SUITE " = rcuperf || test " $TORTURE_SUITE " = refscale
Original file line number Diff line number Diff line change 1+ NOPREEMPT
2+ PREEMPT
Original file line number Diff line number Diff line change 1+ CONFIG_SCF_TORTURE_TEST=y
2+ CONFIG_PRINTK_TIME=y
Original file line number Diff line number Diff line change 1+ CONFIG_SMP=y
2+ CONFIG_PREEMPT_NONE=y
3+ CONFIG_PREEMPT_VOLUNTARY=n
4+ CONFIG_PREEMPT=n
5+ CONFIG_HZ_PERIODIC=n
6+ CONFIG_NO_HZ_IDLE=n
7+ CONFIG_NO_HZ_FULL=y
8+ CONFIG_DEBUG_LOCK_ALLOC=n
9+ CONFIG_PROVE_LOCKING=n
Original file line number Diff line number Diff line change 1+ nohz_full=1
Original file line number Diff line number Diff line change 1+ CONFIG_SMP=y
2+ CONFIG_PREEMPT_NONE=n
3+ CONFIG_PREEMPT_VOLUNTARY=n
4+ CONFIG_PREEMPT=y
5+ CONFIG_HZ_PERIODIC=n
6+ CONFIG_NO_HZ_IDLE=y
7+ CONFIG_NO_HZ_FULL=n
8+ CONFIG_DEBUG_LOCK_ALLOC=y
9+ CONFIG_PROVE_LOCKING=y
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ # SPDX-License-Identifier: GPL-2.0+
3+ #
4+ # Torture-suite-dependent shell functions for the rest of the scripts.
5+ #
6+ # Copyright (C) Facebook, 2020
7+ #
8+ # Authors: Paul E. McKenney <paulmck@kernel.org>
9+
10+ # scftorture_param_onoff bootparam-string config-file
11+ #
12+ # Adds onoff scftorture module parameters to kernels having it.
13+ scftorture_param_onoff () {
14+ if ! bootparam_hotplug_cpu " $1 " && configfrag_hotplug_cpu " $2 "
15+ then
16+ echo CPU-hotplug kernel, adding scftorture onoff. 1>&2
17+ echo scftorture.onoff_interval=1000 scftorture.onoff_holdoff=30
18+ fi
19+ }
20+
21+ # per_version_boot_params bootparam-string config-file seconds
22+ #
23+ # Adds per-version torture-module parameters to kernels supporting them.
24+ per_version_boot_params () {
25+ echo $1 ` scftorture_param_onoff " $1 " " $2 " ` \
26+ scftorture.stat_interval=15 \
27+ scftorture.shutdown_secs=$3 \
28+ scftorture.verbose=1 \
29+ scf
30+ }
You can’t perform that action at this time.
0 commit comments