Torture-test updates for 4.6
Subsystems (3)
cover Torture-test updates for 4.6
Hello!
This series provides torture-test updates:
1. Add checks for rcutorture writer starvation.
2. Don't keep empty console.log.diags files.
3. Make rcutorture scripts check for self-detected stalls.
4. Export rcu_gp_is_normal() so that it can be used in torture tests
when run as modules.
Thanx, Paul
------------------------------------------------------------------------
kernel/rcu/update.c | 1 + tools/testing/selftests/rcutorture/bin/parse-console.sh | 10 ++++++---- 2 files changed, 7 insertions(+), 4 deletions(-)
PATCH 1/4 rcutorture: Add checks for rcutorture writer starvation
This commit adds checks for rcutorture writer starvation, so that instances will be added to the test summary.
--- tools/testing/selftests/rcutorture/bin/parse-console.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
tools/testing/selftests/rcutorture/bin/parse-console.sh +2 -2
@@ -33,7 +33,7 @@ if grep -Pq '\x00' < $file then print_warning Console output contains nul bytes, old qemu still running? fi -egrep 'Badness|WARNING:|Warn|BUG|===========|Call Trace:|Oops:|detected stalls on CPUs/tasks:|Stall ended before state dump start' < $file | grep -v 'ODEBUG: ' | grep -v 'Warning: unable to open an initial console' > $1.diags +egrep 'Badness|WARNING:|Warn|BUG|===========|Call Trace:|Oops:|detected stalls on CPUs/tasks:|Stall ended before state dump start|\?\?\? Writer stall state' < $file | grep -v 'ODEBUG: ' | grep -v 'Warning: unable to open an initial console' > $1.diags if test -s $1.diags then print_warning Assertion failure in $file $title
@@ -64,7 +64,7 @@ then then summary="$summary lockdep: $n_badness" fi - n_stalls=`egrep -c 'detected stalls on CPUs/tasks:|Stall ended before state dump start' $1` + n_stalls=`egrep -c 'detected stalls on CPUs/tasks:|Stall ended before state dump start|\?\?\? Writer stall state' $1` if test "$n_stalls" -ne 0 then summary="$summary Stalls: $n_stalls"
Signature · 1 line
2.5.2
PATCH 2/4 rcutorture: Don't keep empty console.log.diags files
In reply to Paul E. McKenneyCurrently, an error-free run produces an empty console.log.diags file. This can be annoying when using "vi */console.log.diags" to see a full summary of the errors. This commit therefore removes any empty files during the analysis process.
--- tools/testing/selftests/rcutorture/bin/parse-console.sh | 2 ++ 1 file changed, 2 insertions(+)
tools/testing/selftests/rcutorture/bin/parse-console.sh +2 -0
@@ -70,4 +70,6 @@ then summary="$summary Stalls: $n_stalls" fi print_warning Summary: $summary +else + rm $1.diags fi
Signature · 1 line
2.5.2
PATCH 3/4 rcutorture: Check for self-detected stalls
In reply to Paul E. McKenneyThe current scripts parse console output only for cases where one CPU detect a stall on some other CPU or task. This commit therefore adds checks for self-detected stalls.
--- tools/testing/selftests/rcutorture/bin/parse-console.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
tools/testing/selftests/rcutorture/bin/parse-console.sh +2 -2
@@ -33,7 +33,7 @@ if grep -Pq '\x00' < $file then print_warning Console output contains nul bytes, old qemu still running? fi -egrep 'Badness|WARNING:|Warn|BUG|===========|Call Trace:|Oops:|detected stalls on CPUs/tasks:|Stall ended before state dump start|\?\?\? Writer stall state' < $file | grep -v 'ODEBUG: ' | grep -v 'Warning: unable to open an initial console' > $1.diags +egrep 'Badness|WARNING:|Warn|BUG|===========|Call Trace:|Oops:|detected stalls on CPUs/tasks:|self-detected stall on CPU|Stall ended before state dump start|\?\?\? Writer stall state' < $file | grep -v 'ODEBUG: ' | grep -v 'Warning: unable to open an initial console' > $1.diags if test -s $1.diags then print_warning Assertion failure in $file $title
@@ -64,7 +64,7 @@ then then summary="$summary lockdep: $n_badness" fi - n_stalls=`egrep -c 'detected stalls on CPUs/tasks:|Stall ended before state dump start|\?\?\? Writer stall state' $1` + n_stalls=`egrep -c 'detected stalls on CPUs/tasks:|self-detected stall on CPU|Stall ended before state dump start|\?\?\? Writer stall state' $1` if test "$n_stalls" -ne 0 then summary="$summary Stalls: $n_stalls"
Signature · 1 line
2.5.2
PATCH 4/4 rcu: Export rcu_gp_is_normal()
In reply to Paul E. McKenneyThis commit exports rcu_gp_is_normal() in order to allow it to be used by rcutorture and rcuperf.
--- kernel/rcu/update.c | 1 + 1 file changed, 1 insertion(+)
kernel/rcu/update.c +1 -0
@@ -128,6 +128,7 @@ bool rcu_gp_is_normal(void) {return READ_ONCE (rcu_normal); } +EXPORT_SYMBOL_GPL (rcu_gp_is_normal);static atomic_t rcu_expedited_nesting =ATOMIC_INIT (IS_ENABLED (CONFIG_RCU_EXPEDITE_BOOT ) ?1 :0 );
Signature · 1 line
2.5.2